Next: 11 Postfix
Up: Redhat FAQ
Previous: 9 OpenSSL
Contents
Subsections
- By:
- Stephen Carville
- Rev:
- 08/23/02
Port Forwarding is also possible using OpenSSH (Sec 17.2).
The simpliest and, in my opinion, the preferred way to handle redirecting
unencrypted connections is to use the redirect capability built into
xinetd.
If necessary, add services names to /etc/services. For example:
geofwd 50005/tcp # GeoTrac forwarded port
- Add service file to /etc/xinetd.d. Example file:
# default: on
# description: forward connections to indian:1005
service geofwd
{
flags = REUSE
socket_type = stream
wait = no
user = root
redirect = 192.168.124.4 1005
log_on_failure += USERID
}
- Restart xinetd
# /etc/rc.d/init.d/xinetd restart
The netcat utility is sometimes described as the 'Swiss Army
Knife'' of the network. Here we are using it for very basic port
forwarding from an externally accessible server to an internal server.
If it is not necessary to run the forwarding service continiously,
on Redhat it is prefereable to use xinetd forwarding.
- Install netcat from CDROM or from ftp
# rpm -Uvh ftp://volga/pub/RPMS/nc-*.rpm
- Add services names to /etc/services. For example:
geofwd 50005/tcp # GeoTrac forwarded port(netcat)
- Add service file to /etc/xinetd.d. Example file:
- # default: on
# description: forward connections to panama:1005
service geofwd
{
flags = REUSE
socket_type = stream
wait = no
user = root
server = /usr/bin/nc
server_args = 192.168.124.38 1005
log_on_failure += USERID
}
- Restart xinetd
# /etc/rc.d/init.d/xinetd restart
Next: 11 Postfix
Up: Redhat FAQ
Previous: 9 OpenSSL
Contents
2005-03-20