home · contact · privacy
Add first steps to Bookworm server setup.
[config] / bookworm / etc_files / server / etc / ssh / sshd_config
1
2 # This is the sshd server system-wide configuration file.  See
3 # sshd_config(5) for more information.
4
5 # This sshd was compiled with PATH=/usr/local/bin:/usr/bin:/bin:/usr/games
6
7 # The strategy used for options in the default sshd_config shipped with
8 # OpenSSH is to specify options with their default value where
9 # possible, but leave them commented.  Uncommented options override the
10 # default value.
11
12 Include /etc/ssh/sshd_config.d/*.conf
13
14 #Port 22
15 #AddressFamily any
16 #ListenAddress 0.0.0.0
17 #ListenAddress ::
18
19 #HostKey /etc/ssh/ssh_host_rsa_key
20 #HostKey /etc/ssh/ssh_host_ecdsa_key
21 #HostKey /etc/ssh/ssh_host_ed25519_key
22
23 # Ciphers and keying
24 #RekeyLimit default none
25
26 # Logging
27 #SyslogFacility AUTH
28 #LogLevel INFO
29
30 # Authentication:
31
32 #LoginGraceTime 2m
33 PermitRootLogin no
34 #StrictModes yes
35 #MaxAuthTries 6
36 #MaxSessions 10
37
38 #PubkeyAuthentication yes
39
40 # Expect .ssh/authorized_keys2 to be disregarded by default in future.
41 #AuthorizedKeysFile     .ssh/authorized_keys .ssh/authorized_keys2
42
43 #AuthorizedPrincipalsFile none
44
45 #AuthorizedKeysCommand none
46 #AuthorizedKeysCommandUser nobody
47
48 # For this to work you will also need host keys in /etc/ssh/ssh_known_hosts
49 #HostbasedAuthentication no
50 # Change to yes if you don't trust ~/.ssh/known_hosts for
51 # HostbasedAuthentication
52 #IgnoreUserKnownHosts no
53 # Don't read the user's ~/.rhosts and ~/.shosts files
54 #IgnoreRhosts yes
55
56 # To disable tunneled clear text passwords, change to no here!
57 PasswordAuthentication no 
58 #PermitEmptyPasswords no
59
60 # Change to yes to enable challenge-response passwords (beware issues with
61 # some PAM modules and threads)
62 KbdInteractiveAuthentication no
63
64 # Kerberos options
65 #KerberosAuthentication no
66 #KerberosOrLocalPasswd yes
67 #KerberosTicketCleanup yes
68 #KerberosGetAFSToken no
69
70 # GSSAPI options
71 #GSSAPIAuthentication no
72 #GSSAPICleanupCredentials yes
73 #GSSAPIStrictAcceptorCheck yes
74 #GSSAPIKeyExchange no
75
76 # Set this to 'yes' to enable PAM authentication, account processing,
77 # and session processing. If this is enabled, PAM authentication will
78 # be allowed through the KbdInteractiveAuthentication and
79 # PasswordAuthentication.  Depending on your PAM configuration,
80 # PAM authentication via KbdInteractiveAuthentication may bypass
81 # the setting of "PermitRootLogin prohibit-password".
82 # If you just want the PAM account and session checks to run without
83 # PAM authentication, then enable this but set PasswordAuthentication
84 # and KbdInteractiveAuthentication to 'no'.
85 UsePAM yes
86
87 #AllowAgentForwarding yes
88 #AllowTcpForwarding yes
89 #GatewayPorts no
90 X11Forwarding yes
91 #X11DisplayOffset 10
92 #X11UseLocalhost yes
93 #PermitTTY yes
94 PrintMotd no
95 #PrintLastLog yes
96 #TCPKeepAlive yes
97 #PermitUserEnvironment no
98 #Compression delayed
99 ClientAliveInterval 15
100 #ClientAliveCountMax 3
101 #UseDNS no
102 #PidFile /run/sshd.pid
103 #MaxStartups 10:30:100
104 #PermitTunnel no
105 #ChrootDirectory none
106 #VersionAddendum none
107
108 # no default banner path
109 #Banner none
110
111 # Allow client to pass locale environment variables
112 AcceptEnv LANG LC_*
113
114 # override default of no subsystems
115 Subsystem       sftp    /usr/lib/openssh/sftp-server
116
117 # Example of overriding settings on a per-user basis
118 #Match User anoncvs
119 #       X11Forwarding no
120 #       AllowTcpForwarding no
121 #       PermitTTY no
122 #       ForceCommand cvs server