|
Search:
Advanced search
|
Browse by category:
|
Port forwarding using netcat. |
|||||
This example shows how to create a custom xinetd service, in this case to forward radmin (port 4899) to another server using netcat.
Create a file in /etc/sysconfig/xinetd.d/ (call it what you want - but for this example radmin would be a good choice) You also need to ensure that your /etc/services file contains a mapping for the port you wish to forward, e.g. in this case I inserted "radmin 4899/TCP # Remote admin" into my services file - omit the quotes though. service radmin {   flags = REUSE   protocol = tcp   socket_type = stream   port = 4899   wait = no   user = nobody   server = /usr/sbin/nc   server_args = -w 10 192.168.20.250 4899   disable = no } This will redirect any requests to the local machine on port 4899 to the remote server 192.168.20.250:4899 A poor mans proxy really! |
|||||
Powered by
KBPublisher (Knowledge base software)