Encrypting network communication using SSH tunneling
In these days ssh
is the de facto method for establishing a remote connection to a host. It can also be used to tunnel and encrypt network communication between two hosts. SSH tunneling can be implemented for encrypting network communication between a computer used by a DBA for remote database administration, but is also suitable to be used with Data Guard for encrypting log shipping. In this recipe we will encrypt the network communication between nodeorcl1
and nodeorcl5
using ssh
.
Getting ready
All steps will be performed on nodeorcl1
and nodeorcl5
.
How to do it...
To use tunneling you must enable ssh
port forwarding on the server. Open the /etc/ssh/sshd_conf
configuration file and uncomment the following line:
AllowTcpForwarding yes
Save and close the file and restart sshd
service as follows:
service sshd restart
To forward the listening port to the
ssh
port execute the following command:[oracle@nodeorcl1 ~]# ssh -N -L1530:nodeorcl1:1521...