SSH concurrent session limit and idle session time out
Hi All,
How do we limit the number of concurrent remote ssh session to 5 and session idle time out is 5 Minute Thanks in advacne |
Assuming you're using OpenSSH, you can limit unauthenticated connections with the MaxStartups directive in sshd_config.
If your situation permits, also use "PermitRootLogin no" and specify the users able to use SSH with "AllowUsers user1 user2 usern..." For Idle Timeout, use the ClientAliveInterval and ClientAliveCountMax directives. For more details: Code:
man sshd_config |
Quote:
Thanks for your replay.I know all this settings but i want to limit the session for authenticated users. That means in my server i want to allow concurrent remote login only from 5 users if 6th user try he should get access denied |
I know it's been a while, but I was looking for the same thing today.
Quote:
MaxSessions 5 See man 5 sshd_config. |
All times are GMT -5. The time now is 12:22 PM. |