summaryrefslogtreecommitdiff
path: root/debian/README.Debian
diff options
context:
space:
mode:
Diffstat (limited to 'debian/README.Debian')
-rw-r--r--debian/README.Debian261
1 files changed, 261 insertions, 0 deletions
diff --git a/debian/README.Debian b/debian/README.Debian
new file mode 100644
index 000000000..6b7ce8691
--- /dev/null
+++ b/debian/README.Debian
@@ -0,0 +1,261 @@
1OpenSSH for Debian
2------------------
3
4Although this package is widely referred to as OpenSSH, it is actually
5a branch of an early version of ssh which has been tidied up by the
6OpenBSD folks.
7
8It has been decided that this version should have the privilege of
9carrying the ``ssh'' name in Debian, since it is the only version of
10ssh that is going to make it into Debian proper, being the only one
11that complies with the Debian Free Software Guidelines.
12
13If you were expecting to get the non-free version of ssh (1.2.27 or
14whatever) when you installed this package, then you're out of luck, as
15Debian don't ship it.
16
17=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
18
19BUILD ISSUES
20============
21
22To build the openssh package for woody, set DEB_BUILD_SSH_WOODY=1 in
23your environment. This is necessary due to non-backward-compatible
24changes in PAM support.
25
26=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
27
28UPGRADE ISSUES
29==============
30
31Privilege Separation
32--------------------
33
34As of 3.3, openssh has employed privilege separation to reduce the
35quantity of code that runs as root, thereby reducing the impact of
36some security holes in sshd. This now also works properly with PAM.
37
38Privilege separation is turned on by default, so, if you decide you
39want it turned off, you need to add "UsePrivilegeSeparation no" to
40/etc/ssh/sshd_config.
41
42PermitRootLogin set to yes
43--------------------------
44
45This is now the default setting (in line with upstream), and people
46who asked for an automatically-generated configuration file when
47upgrading from potato (or on a new install) will have this setting in
48their /etc/ssh/sshd_config file.
49
50Should you wish to change this setting, edit /etc/ssh/sshd_config, and
51change:
52PermitRootLogin yes
53to:
54PermitRootLogin no
55
56Having PermitRootLogin set to yes means that an attacker that knows
57the root password can ssh in directly (without having to go via a user
58account). If you set it to no, then they must compromise a normal user
59account. In the vast majority of cases, this does not give added
60security; remember that any account you su to root from is equivalent
61to root - compromising this account gives an attacker access to root
62easily. If you only ever log in as root from the physical console,
63then you probably want to set this value to no.
64
65As an aside, PermitRootLogin can also be set to "without-password" or
66"forced-commands-only" - see sshd(8) for more details.
67
68DO NOT FILE BUG REPORTS SAYING YOU THINK THIS DEFAULT IS INCORRECT!
69
70The argument above is somewhat condensed; I have had this discussion
71at great length with many people. If you think the default is
72incorrect, and feel strongly enough to want to argue with me about it,
73then send me email to matthew@debian.org. I will close bug reports
74claiming the default is incorrect.
75
76SSH now uses protocol 2 by default
77----------------------------------
78
79This means all your keyfiles you used for protocol version 1 need to
80be re-generated. The server keys are done automatically, but for RSA
81authentication, please read the ssh-keygen manpage.
82
83If you have an automatically generated configuration file, and decide
84at a later stage that you do want to support protocol version 1 (not
85recommended, but note that the ssh client shipped with Debian potato
86only supported protocol version 1), then you need to do the following:
87
88Change /etc/ssh/sshd_config such that:
89Protocol 2
90becomes:
91Protocol 2,1
92Also add the line:
93HostKey /etc/ssh/ssh_host_key
94
95If you do not already have an RSA1 host key in /etc/ssh/ssh_host_key,
96you will need to generate one. To do so, run this command as root:
97
98 ssh-keygen -f /etc/ssh/ssh_host_key -N '' -t rsa1
99
100As of openssh-server 1:4.1p1-2, the option to support protocol version 1
101is no longer available via debconf. You must edit the configuration file
102instead.
103
104X11 Forwarding
105--------------
106
107ssh's default for ForwardX11 has been changed to ``no'' because it has
108been pointed out that logging into remote systems administered by
109untrusted people is likely to open you up to X11 attacks, so you
110should have to actively decide that you trust the remote machine's
111root, before enabling X11. I strongly recommend that you do this on a
112machine-by-machine basis, rather than just enabling it in the default
113host settings.
114
115In order for X11 forwarding to work, you need to install xauth on the
116server. In Debian this is in the xbase-clients package.
117
118As of OpenSSH 3.1, the remote $DISPLAY uses localhost by default to reduce
119the security risks of X11 forwarding. Look up X11UseLocalhost in
120sshd_config(8) if this is a problem.
121
122OpenSSH 3.8 invented ForwardX11Trusted, which when set to no causes the
123ssh client to create an untrusted X cookie so that attacks on the
124forwarded X11 connection can't become attacks on X clients on the remote
125machine. However, this has some problems in implementation - notably a
126very short timeout of the untrusted cookie - breaks large numbers of
127existing setups, and generally seems immature. The Debian package
128therefore sets the default for this option to "yes" (in ssh itself,
129rather than in ssh_config).
130
131Fallback to RSH
132---------------
133
134The default for this setting has been changed from Yes to No, for
135security reasons, and to stop the delay attempting to rsh to machines
136that don't offer the service. Simply switch it back on in either
137/etc/ssh/ssh_config or ~/.ssh/config for those machines that you need
138it for.
139
140Setgid ssh-agent and environment variables
141------------------------------------------
142
143As of version 1:3.5p1-1, ssh-agent is installed setgid to prevent ptrace()
144attacks retrieving private key material. This has the side-effect of causing
145glibc to remove certain environment variables which might have security
146implications for set-id programs, including LD_PRELOAD, LD_LIBRARY_PATH, and
147TMPDIR.
148
149If you need to set any of these environment variables, you will need to do
150so in the program exec()ed by ssh-agent. This may involve creating a small
151wrapper script.
152
153Symlink Hostname invocation
154---------------------------
155
156This version of ssh no longer includes support for invoking ssh with the
157hostname as the name of the file run. People wanting this support should
158use the ssh-argv0 script.
159
160=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
161
162OTHER ISSUES
163============
164
165/usr/bin/ssh not SUID
166---------------------
167
168Due to Debian bug #164325, RhostsRSAAuthentication can only be used if ssh
169is SUID. Until this is fixed, if that is a problem, use:
170
171 dpkg-statoverride
172
173or if that's also missing, use this:
174
175 chown root.root /usr/bin/ssh
176 chmod 04755 /usr/bin/ssh
177
178Authorization Forwarding
179------------------------
180
181Similarly, root on a remote server could make use of your ssh-agent
182(while you're logged into their machine) to obtain access to machines
183which trust your keys. This feature is therefore disabled by default.
184You should only re-enable it for those hosts (in your ~/.ssh/config or
185/etc/ssh/ssh_config) where you are confident that the remote machine
186is not a threat.
187
188Problems logging in with RSA authentication
189-------------------------------------------
190
191If you have trouble logging in with RSA authentication then the
192problem is probably caused by the fact that you have your home
193directory writable by group, as well as user (this is the default on
194Debian systems).
195
196Depending upon other settings on your system (i.e. other users being
197in your group) this could open a security hole, so you will need to
198make your home directory writable only by yourself. Run this command,
199as yourself:
200
201 chmod g-w ~/
202
203to remove group write permissions. If you use ssh-copy-id to install your
204keys, it does this for you.
205
206-L option of ssh nonfree
207------------------------
208
209non-free ssh supported the usage of the option -L to use a non privileged
210port for scp. This option will not be supported by scp from openssh.
211
212Please use instead scp -o "UsePrivilegedPort=no" as documented in the
213manpage to scp itself.
214
215Problem logging in because of TCP-Wrappers
216------------------------------------------
217
218ssh is compiled with support for tcp-wrappers. So if you can no longer
219log into your system, please check that /etc/hosts.allow and /etc/hosts.deny
220are configured so that ssh is not blocked.
221
222Kerberos support
223----------------
224
225ssh is now compiled with Kerberos support. Unfortunately, privilege
226separation is incompatible with Kerberos support for SSH protocol 1 and
227parts of the support for protocol 2; you may need to run kinit after logging
228in.
229
230Interoperability between scp and the ssh.com SSH server
231-------------------------------------------------------
232
233In version 2 and greater of the commercial SSH server produced by SSH
234Communications Security, scp was changed to use SFTP (SSH2's file transfer
235protocol) instead of the traditional rcp-over-ssh, thereby breaking
236compatibility. The OpenSSH developers regard this as a bug in the ssh.com
237server, and do not currently intend to change OpenSSH's scp to match.
238
239Workarounds for this problem are to install scp1 on the server (scp2 will
240fall back to it), to use sftp, or to use some other transfer mechanism such
241as rsync-over-ssh or tar-over-ssh.
242
243Running sshd from inittab
244-------------------------
245
246Some people find it useful to run the sshd server from inittab, to make sure
247that it always stays running. To do this, stop sshd ('/etc/init.d/ssh
248stop'), add the following line to /etc/inittab, and run 'telinit q':
249
250 ss:2345:respawn:/usr/sbin/sshd -D
251
252If you do this, note that you will need to stop sshd being started in the
253normal way ('rm -f /etc/rc[2345].d/S20ssh') and that you will need to
254restart this sshd manually on upgrades.
255
256--
257Matthew Vernon
258<matthew@debian.org>
259and
260Colin Watson
261<cjwatson@debian.org>