MaxSessions
The sshd_config setting that limits how many shell, login or subsystem sessions may share one SSH network connection.
In more detail
The OpenSSH default is ten. Setting it to one stops a single connection being reused for extra sessions, and zero blocks shell, login and subsystem sessions entirely while still allowing forwarding. If the file never mentions it, sshd -T still reports the default, which is why an audit should read the effective configuration.
Examples
MaxSessions 5sshd -T -f test_config -h hostkey | grep maxsessionsRelated terms
- MaxAuthTries — The sshd_config setting that limits how many authentication attempts a client may make on one connection before it is disconnected.
- sshd_config — The main configuration file of the OpenSSH server, normally at /etc/ssh/sshd_config, which controls who can log in and how.
- effective configuration — The settings a program actually uses once it has read every file, include and built-in default, which can differ from what any single file says.
Taught in
- Security Baselines, Policies & Hardening Standards — Cybersecurity Fundamentals, GRC & Cryptography