Socat

From Attie's Wiki
Jump to: navigation, search

Route a Unix socket over TCP

Server (next to the listening Unix socket)

socat TCP-LISTEN:27015,reuseaddr,fork UNIX-CLIENT:/tmp/ns
socat TCP-LISTEN:27015,bind=127.0.0.1,reuseaddr,fork,su=nobody,range=127.0.0.0/8 UNIX-CLIENT:/tmp/ns

Client (to create a listening Unix socket)

socat UNIX-LISTEN:/tmp/ns,fork,unlink-early TCP-CONNECT:myserver:27015
Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox