Welcome to Server Circle. It's a friendly site and all levels of experience are welcome. Be aware that we use cookies for your login.
Server Circle - Ask questions about Servers and get answers from experts.
Beta (0.11 sec)
SSH config for only some users

I can set up AllowUsers in sshd_config to only allow certain people to log in but is there a an equivalent AllowGroup ?

If so how does it work ?

It would be easier to admin I think.
Asked by:
Trinity
2782 points
 Report Abuse
 Share Page - Category: Linux Servers - Tags: SSH config for only some users
 Enter your response
Please use Pastie.org to paste lengthy code or to fix formatting issues with code
  • Responses in reverse (4)

In /etc/ssh

you can create ssh.access and ssh.deny and set user can ssh in server

Response by:
mohamad_kian
1548 points
Note that you should also be able to use PAM. You can also specify what users/group are allowed to do with but writing some "Match group" "Match user" sections. See your man page for sshd_config.

Response by:
s
3383 points
It looks like you can set it in 4 ways in the /etc/ssh/sshd_config file with AllowGroups, AllowUsers, DenyGroups and DenyUsers.

You just seem to use it in that file such as:

AllowGroups sshusers

This link gives a comprehensive overview that even I can understand, so you should have no probs.

http://knowledgelayer.sof ...

I guess an "AllowUser root" or similar would be a good move at the top, just incase it all conflicts. :-)

Response by:
trevHCS
640 points
Yes, I'm pretty sure that it's just AllowGroup isn't it ?

Response by:
BonoEstente
1464 points


  • Related Questions
About Us : Contact Us : Etiquette : Terms : CDN Failover : ShorterURL : CDN Fallback : © 2013 Server Circle