]> git.donarmstrong.com Git - dsa-puppet.git/blob - modules/ssh/templates/sshd_config.erb
probably break a couple of release dependent templates
[dsa-puppet.git] / modules / ssh / templates / sshd_config.erb
1 # Package generated configuration file
2 # See the sshd(8) manpage for details
3
4 # What ports, IPs and protocols we listen for
5 Port 22
6 <%= extraports = case fqdn
7                         when "ravel.debian.org" then "Port 443"
8                         when "agnesi.debian.org" then "Port 2260"
9                  end
10 extraports
11 %>
12 # Use these options to restrict which interfaces/protocols sshd will bind to
13 #ListenAddress ::
14 #ListenAddress 0.0.0.0
15 Protocol 2
16 # HostKeys for protocol version 2
17 HostKey /etc/ssh/ssh_host_rsa_key
18 #Privilege Separation is turned on for security
19 UsePrivilegeSeparation yes
20
21 # Lifetime and size of ephemeral version 1 server key
22 KeyRegenerationInterval 3600
23 ServerKeyBits 768
24
25 # Logging
26 SyslogFacility AUTH
27 LogLevel INFO
28
29 # Authentication:
30 LoginGraceTime 120
31 PermitRootLogin without-password
32 StrictModes yes
33
34 RSAAuthentication yes
35 PubkeyAuthentication yes
36
37 # Don't read the user's ~/.rhosts and ~/.shosts files
38 IgnoreRhosts yes
39 # For this to work you will also need host keys in /etc/ssh_known_hosts
40 RhostsRSAAuthentication no
41 # similar for protocol version 2
42 HostbasedAuthentication no
43 # Uncomment if you don't trust ~/.ssh/known_hosts for RhostsRSAAuthentication
44 #IgnoreUserKnownHosts yes
45
46 # To enable empty passwords, change to yes (NOT RECOMMENDED)
47 PermitEmptyPasswords no
48
49 # Change to yes to enable challenge-response passwords (beware issues with
50 # some PAM modules and threads)
51 ChallengeResponseAuthentication no
52
53 # Kerberos options
54 #KerberosAuthentication no
55 #KerberosGetAFSToken no
56 #KerberosOrLocalPasswd yes
57 #KerberosTicketCleanup yes
58
59 # GSSAPI options
60 #GSSAPIAuthentication no
61 #GSSAPICleanupCredentials yes
62
63 X11Forwarding no
64 X11DisplayOffset 10
65 PrintMotd no
66 PrintLastLog yes
67 TCPKeepAlive yes
68 #UseLogin no
69
70 #MaxStartups 10:30:60
71 #Banner /etc/issue.net
72
73 # Allow client to pass locale environment variables
74 AcceptEnv LANG LC_*
75
76 Subsystem sftp /usr/lib/openssh/sftp-server
77
78 UsePAM yes
79 <% if %w{lenny squeeze}.include?(lsbdistcodename) %>
80 AuthorizedKeysFile /etc/ssh/userkeys/%u
81 AuthorizedKeysFile2 /var/lib/misc/userkeys/%u
82 <% else %>
83 AuthorizedKeysFile /etc/ssh/userkeys/%u /var/lib/misc/userkeys/%u
84 <% end %>
85 PasswordAuthentication no