| Comments
| Tag:
syslife
Tips: Hardening SSH
Sécurisons SSH (oui oui !)
Je poste ici une configuration SSH optimisée et très sécurisée:
/etc/ssh/sshd_configView on Github## Hardening ssh conf Leseb # Port Port 22 # Protocol to use Protocol 2 #ListenAddress votre_ip # Automatically disconnect session due to inactivity (5min) ClientAliveInterval 300 ClientAliveCountMax 0 # Restrict SSH access to user groups AllowGroups ssh-users # KeyBit Lenght ServerKeyBits 1024 # Enable a warning banner Banner /etc/issue # Disable empty passwords PermitEmptyPasswords no # Disable root ssh login PermitRootLogin no # No not allow users to set environment PermitUserEnvironment # Disable PubkeyAuthentication # Ignore IgnoreRhosts # Enable PasswordAuthentication # Disable HostbasedAuthentication # Pam UsePAM # Enable Compression # Hardening AllowTcpForwarding X11Forwarding # Check StrictModes # Use Ciphers
|
Bien entendu ce script est disponible sur mon Github
Enjoy!
Comments