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


Click here to return to the 'changing the port number' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
changing the port number
Authored by: xcgr on Aug 19, '05 08:33:46PM

I changed my SSH service to a non-standard port for several months ago. It cut the unwanted login attempts down to zero, since most malware scripts only probe port 22. Obviously this is security by obscurity, and it shouldn't be your primary means of defense. But it does reduce the attack surface, as well as the noise level in the log files.

How to change the sshd port depends on your Mac OS X version. These earlier hints have the details:

10.3: Changing the default SSH server port
10.4: Change the default sshd port

I didn't see a hint for 10.2, but I believe you do it simply by uncommenting and changing the "Port" directive in /private/etc/sshd_config. Then restart the service. For more info, type "man sshd_config" in Terminal.



[ Reply to This | # ]
changing the port number
Authored by: dtungsten on Oct 21, '05 07:31:07PM

I didn't see a hint for 10.2, but I believe you do it simply by uncommenting and changing the "Port" directive in /private/etc/sshd_config. Then restart the service.

Yes, that works (you have to have admin privileges to edit that file, of course).



[ Reply to This | # ]