Port Forwarding

后端 未结 3 1698
旧巷少年郎
旧巷少年郎 2021-02-15 13:01

I have a simple requirement of a software level port forwarding/tunnelling of socket based communication.

  • I have a source server and port using Sockets. This is a
相关标签:
3条回答
  • 2021-02-15 13:15

    You can try netcat or socat (it's more powerful than netcat)

    An example for socat to forward port 80 using tcp4:

    socat tcp4-listen:80,fork tcp4:{another server}:{another port}
    

    and refer to http://en.wikipedia.org/wiki/Netcat#Port_Forwarding_or_Port_Mapping for netcat

    Both are not java-related.

    0 讨论(0)
  • 2021-02-15 13:33

    If you're running xinetd on your system already, it provides a simple port forwarding mechanism that might be useful if you're not running IPTables already.

    If you are running IPTables, Server Fault has an excellent, short question with a very similar goal. Though I find it a bit terse more detailed documentation is available.

    0 讨论(0)
  • 2021-02-15 13:36

    There is a TCP/IP port forwarding utility named portforward available in code.google.com. It is entirely written in Java.

    0 讨论(0)
提交回复
热议问题