|
| 1 | +# {{ ansible_managed }} |
| 2 | +# Package generated configuration file |
| 3 | +# See the sshd_config(5) manpage for details |
| 4 | + |
| 5 | +# What ports, IPs and protocols we listen for |
| 6 | +Port 22 |
| 7 | +# Use these options to restrict which interfaces/protocols sshd will bind to |
| 8 | +#ListenAddress :: |
| 9 | +#ListenAddress 0.0.0.0 |
| 10 | +Protocol 2 |
| 11 | +# HostKeys for protocol version 2 |
| 12 | +HostKey /etc/ssh/ssh_host_rsa_key |
| 13 | +HostKey /etc/ssh/ssh_host_dsa_key |
| 14 | +HostKey /etc/ssh/ssh_host_ecdsa_key |
| 15 | +HostKey /etc/ssh/ssh_host_ed25519_key |
| 16 | + |
| 17 | +# Logging |
| 18 | +SyslogFacility AUTH |
| 19 | +LogLevel INFO |
| 20 | + |
| 21 | +# Authentication: |
| 22 | +LoginGraceTime 120 |
| 23 | +PermitRootLogin without-password |
| 24 | +StrictModes yes |
| 25 | + |
| 26 | +PubkeyAuthentication yes |
| 27 | +#AuthorizedKeysFile %h/.ssh/authorized_keys |
| 28 | + |
| 29 | +# Don't read the user's ~/.rhosts and ~/.shosts files |
| 30 | +IgnoreRhosts yes |
| 31 | +# similar for protocol version 2 |
| 32 | +HostbasedAuthentication no |
| 33 | +# Uncomment if you don't trust ~/.ssh/known_hosts for RhostsRSAAuthentication |
| 34 | +#IgnoreUserKnownHosts yes |
| 35 | + |
| 36 | +# To enable empty passwords, change to yes (NOT RECOMMENDED) |
| 37 | +PermitEmptyPasswords no |
| 38 | + |
| 39 | +# Change to yes to enable challenge-response passwords (beware issues with |
| 40 | +# some PAM modules and threads) |
| 41 | +ChallengeResponseAuthentication no |
| 42 | + |
| 43 | +# Change to no to disable tunnelled clear text passwords |
| 44 | +#PasswordAuthentication yes |
| 45 | + |
| 46 | +# Kerberos options |
| 47 | +#KerberosAuthentication no |
| 48 | +#KerberosGetAFSToken no |
| 49 | +#KerberosOrLocalPasswd yes |
| 50 | +#KerberosTicketCleanup yes |
| 51 | + |
| 52 | +# GSSAPI options |
| 53 | +#GSSAPIAuthentication no |
| 54 | +#GSSAPICleanupCredentials yes |
| 55 | + |
| 56 | +X11Forwarding yes |
| 57 | +X11DisplayOffset 10 |
| 58 | +PrintMotd no |
| 59 | +PrintLastLog yes |
| 60 | +TCPKeepAlive yes |
| 61 | +#UseLogin no |
| 62 | + |
| 63 | +#MaxStartups 10:30:60 |
| 64 | +#Banner /etc/issue.net |
| 65 | + |
| 66 | +# Allow client to pass locale environment variables |
| 67 | +AcceptEnv LANG LC_* |
| 68 | + |
| 69 | +Subsystem sftp /usr/lib/openssh/sftp-server |
| 70 | + |
| 71 | +# Set this to 'yes' to enable PAM authentication, account processing, |
| 72 | +# and session processing. If this is enabled, PAM authentication will |
| 73 | +# be allowed through the ChallengeResponseAuthentication and |
| 74 | +# PasswordAuthentication. Depending on your PAM configuration, |
| 75 | +# PAM authentication via ChallengeResponseAuthentication may bypass |
| 76 | +# the setting of "PermitRootLogin without-password". |
| 77 | +# If you just want the PAM account and session checks to run without |
| 78 | +# PAM authentication, then enable this but set PasswordAuthentication |
| 79 | +# and ChallengeResponseAuthentication to 'no'. |
| 80 | +UsePAM yes |
| 81 | + |
| 82 | +MaxSessions 1000 |
0 commit comments