Fedora Learning Linux

ssh reverse tunning..

If you want to access some local resources like the release website from the remote server when you are connecting to the remoter server using ssh over VPN, then possibly reverse ssh tunnelling is the best option. So, basically when you are connecting to the remote server, you tell the server your intent to do so and which local resource you want to connect to and on which port.So, here I want to connnet to and tunnel the data to tthough the tunnel, then the command to use will be  ::

ssh -R 8010:

Now, on the remote server whenever you want to connect to, you can do wget http://localhost:8010….

Enhanced by Zemanta
bash Fedora Linux

[Solved] ssh works but scp does not

Structure of an SSH binary packet
Image via Wikipedia

For quite sometime now, I was having this issue, that for the home system, I was able to connect to is using ssh but it never worked. Fnally after quite some debugging finally I found that the issue was with thebashrc. So, everytime I had to do a scp I would have to move/rename bashrc and do the reverse action after the scp was done.

Finally today I fixed it and the solution was very simple. I put the offending code or rather complete bashrc in the loop as mentioned below:


if [[ $SSH_CLIENT = "" ]


<bashrc code here>


By doing this the <dot>bashrc is never executed when a ssh session is initiated (which is what happens for scp also). 🙂

Enhanced by Zemanta