Giter Site home page Giter Site logo

ps3netsrv-go's Introduction

ps3netsrv-go

It's a minimal alternative implementation of original ps3netsrv which needed to install games using WebMAN/IrisMAN over network (without copying files to console).

I made it because original code is way hard to read and hard to build for some platforms. And for fun and education (understanding and implementation custom network protocols, generating/serving iso image on-the-fly) of course.

This project written in Go because it's (cross-)compilation is much easier than C/C++ and resulting binaries will run without any external library on target system.

Currently multipart files are not supported. But I've added tcp data exchange timeouts to reduce amount of "hang" connections.

Receiving files from console is supported now! Use flag --allow-write to enable this.

Decryption of 3k3y/redump images on-the-fly is supported now! Keys search behaviour completely matches with original ps3netsrv: at first we try to find .dkey file for .iso in PS3ISO directory. Then we try to find .dkey in REDKEY directory. You can also use

$ ps3netsrv-go decrypt

tool to decrypt images.

Running

Just run

$ ps3netsrv-go server

from your working directory to serve it.

Or specify custom root directory in --root flag of server subcommand:

$ ps3netsrv-go server --root=/home/user/games

To get help run:

$ ps3netsrv-go --help

To run "debug" server (for pprof, etc.) specify --debug-server-listen-addr flag.

Configuration

Server supports configuration via environment variables and command line flags. Environment variables names can be found in output of ps3netsrv-go server --help command. I.e. in line:

--root="."                             Root directory with games ($PS3NETSRV_ROOT).

PS3NETSRV_ROOT is environment variable name.

Also server supports configuration via config file. Example:

[server]
root = /home/user/games
client-whitelist = 192.168.1.0/24
max-clients = 10
allow-write = true

Configuration keys names are the same as command line flags names without -- prefix.

Config file discovered in following order:

  • --config flag or PS3NETSRV_CONFIG_FILE environment variable
  • config.ini file in current directory
  • <user config directory>/ps3netsrv-go/config.ini, where <user config directory> is OS-specific directory for user configuration files:
    • %APPDATA% on Windows
    • $XDG_CONFIG_HOME or ~/.config on Linux
    • ~/Library/Application Support on macOS

Exposing tips

  • Use limits:
    • by IP address(es) using --client-whitelist flag: $ ps3netsrv-go server --root=/home/games --client-whitelist=192.168.0.123
    • by number of clients using --max-clients flag
    • idle connection time: --read-timeout flag
  • To expose over NAT (non-public or "grey" IP) you can use:
  • To secure connection using TLS you may use two TLS-terminators (like HAProxy) configured with mutual TLS authentication. Note that desired terminator must support "wrapping" plain TCP connection to TLS with client certificate.

Requirements to build

Go 1.21+

Building

$ go mod download
$ go build -o ps3netsrv-go ./cmd/ps3netsrv-go/...

ps3netsrv-go's People

Contributors

anderstrier avatar xakep666 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

ps3netsrv-go's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.