Skip to main content

Restricting SSH access to 2 or 3 specific IPs

Comments

3 comments

  • cPanelMichael
    Hello, The "AllowUsers" option allows multiple entries on the same line, separate by spaces. EX:
    AllowUsers root@1.2.3.4 root@2.3.4.5
    You may also find this thread helpful: [Tutorial] Interested in increasing the security of your server? Read this. (sshd hardening) Thank you.
    0
  • keat63
    You can do this easiliy is Host Acess Control. In the first box type SSHD in the second input your IP and in the third ALLOW. Add subsequent entries for your IP's then the final entry should be SSHD, ALL, DENY
    0
  • cPanelMichael
    You can do this easiliy is Host Acess Control. In the first box type SSHD in the second input your IP and in the third ALLOW. Add subsequent entries for your IP's then the final entry should be SSHD, ALL, DENY

    Hello @keat63, This will only restrict SSH access to specific IP addresses. The request on this thread relates to restricting SSH access to both usernames and IP addresses. Thank you.
    0

Please sign in to leave a comment.