1833523 Members
2957 Online
110061 Solutions
New Discussion

SSH Source Port issue

 
Mohamed Saleem_1
Occasional Advisor

SSH Source Port issue

When i am trying to do as ssh from server A to another server B , A uses 1023 as source port and 22 as destination port.

Here the ssh is failing and it is because the port 1023 is blocked at firewall device. ( ssh within same subnet works )

Is there is any way to change the source port
( > 1023 ) during ssh. As the ssh being used as several place in the server, manual port change is not preferred

Please help !!
2 REPLIES 2
Kenan Erdey
Honored Contributor

Re: SSH Source Port issue

Hi,

this is a good guide using ssh behind firewall:

http://souptonuts.sourceforge.net/sshtips.htm

Computers have lots of memory but no imagination
Olivier Masse
Honored Contributor

Re: SSH Source Port issue

This is documented in the OpenSSH FAQ.

Use:
# ssh -o "UsePrivilegedPort no" host.com

Good luck