Search This Blog


Restrict SSH Access to Specific Users

An easy way to restrict access of SSH to selected users on a specific subnet:

sudo nano /etc/ssh/sshd_config

Add the lines:
AllowUsers andy@192.168.1.*,, billy@192.168.1.* charlie@192.168.1.*

Alternatively you can use the DenyUsers command to restrict users from accessing ssh.

No comments:

Post a Comment