Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Click here to return to the '10.4: Change the default sshd port' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
10.4: Change the default sshd port
Authored by: n9az on Nov 24, '05 12:42:49PM
Man, I hate it when I post a question and then quickly manage to find the answers myself.... :-)

The trick is to create a secondary plist file as described above, add the extra lines in /etc/services and then remember to do the following:

1) in run

launchctl load /System/Library/LaunchDaemons/ssh2.plist
2) if you have OSX's built-in firewall on like I do, make sure to add an entry in System Preferences -> Sharing -> Firewall (tab) for the secondary ssh port
3) if you're using a router with firewall, obviously you must route that port as well

I managed to forget to do #1 and then #2. Oops!

This is useful for me because I have my router send traffic on port 22 to one machine and traffic on the seconday port to my Mac, so when I'm not home I can ssh directly into either machine just by specifying which port I want to use.

Sorry about the extra post, everyone...

[ Reply to This | # ]