summaryrefslogtreecommitdiff
path: root/contrib/cygwin/README
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/cygwin/README')
-rw-r--r--contrib/cygwin/README134
1 files changed, 75 insertions, 59 deletions
diff --git a/contrib/cygwin/README b/contrib/cygwin/README
index ec58964c9..fc0a2f69b 100644
--- a/contrib/cygwin/README
+++ b/contrib/cygwin/README
@@ -1,4 +1,49 @@
1This package is the actual port of OpenSSH to Cygwin 1.5. 1This package describes important Cygwin specific stuff concerning OpenSSH.
2
3The binary package is usually built for recent Cygwin versions and might
4not run on older versions. Please check http://cygwin.com/ for information
5about current Cygwin releases.
6
7Build instructions are at the end of the file.
8
9===========================================================================
10Important change since 3.7.1p2-2:
11
12The ssh-host-config file doesn't create the /etc/ssh_config and
13/etc/sshd_config files from builtin here-scripts anymore, but it uses
14skeleton files installed in /etc/defaults/etc.
15
16Also it now tries hard to create appropriate permissions on files.
17Same applies for ssh-user-config.
18
19After creating the sshd service with ssh-host-config, it's advisable to
20call ssh-user-config for all affected users, also already exising user
21configurations. In the latter case, file and directory permissions are
22checked and changed, if requireed to match the host configuration.
23
24Important note for Windows 2003 Server users:
25---------------------------------------------
26
272003 Server has a funny new feature. When starting services under SYSTEM
28account, these services have nearly all user rights which SYSTEM holds...
29except for the "Create a token object" right, which is needed to allow
30public key authentication :-(
31
32There's no way around this, except for creating a substitute account which
33has the appropriate privileges. Basically, this account should be member
34of the administrators group, plus it should have the following user rights:
35
36 Create a token object
37 Logon as a service
38 Replace a process level token
39 Increase Quota
40
41The ssh-host-config script asks you, if it should create such an account,
42called "sshd_server". If you say "no" here, you're on your own. Please
43follow the instruction in ssh-host-config exactly if possible. Note that
44ssh-user-config sets the permissions on 2003 Server machines dependent of
45whether a sshd_server account exists or not.
46===========================================================================
2 47
3=========================================================================== 48===========================================================================
4Important change since 3.4p1-2: 49Important change since 3.4p1-2:
@@ -58,7 +103,7 @@ features of the FAT/FAT32 filesystems.
58 103
59If you are installing OpenSSH the first time, you can generate global config 104If you are installing OpenSSH the first time, you can generate global config
60files and server keys by running 105files and server keys by running
61 106
62 /usr/bin/ssh-host-config 107 /usr/bin/ssh-host-config
63 108
64Note that this binary archive doesn't contain default config files in /etc. 109Note that this binary archive doesn't contain default config files in /etc.
@@ -73,10 +118,12 @@ some options:
73 118
74usage: ssh-host-config [OPTION]... 119usage: ssh-host-config [OPTION]...
75Options: 120Options:
76 --debug -d Enable shell's debug output. 121 --debug -d Enable shell's debug output.
77 --yes -y Answer all questions with "yes" automatically. 122 --yes -y Answer all questions with "yes" automatically.
78 --no -n Answer all questions with "no" automatically. 123 --no -n Answer all questions with "no" automatically.
79 --port -p <n> sshd listens on port n. 124 --cygwin -c <options> Use "options" as value for CYGWIN environment var.
125 --port -p <n> sshd listens on port n.
126 --pwd -w <passwd> Use "pwd" as password for user 'sshd_server'.
80 127
81Additionally ssh-host-config now asks if it should install sshd as a 128Additionally ssh-host-config now asks if it should install sshd as a
82service when running under NT/W2K. This requires cygrunsrv installed. 129service when running under NT/W2K. This requires cygrunsrv installed.
@@ -114,54 +161,6 @@ ${SYSTEMROOT}/system32/drivers/etc/services file:
114 161
115 ssh 22/tcp #SSH daemon 162 ssh 22/tcp #SSH daemon
116 163
117===========================================================================
118The following restrictions only apply to Cygwin versions up to 1.3.1
119===========================================================================
120
121Authentication to sshd is possible in one of two ways.
122You'll have to decide before starting sshd!
123
124- If you want to authenticate via RSA and you want to login to that
125 machine to exactly one user account you can do so by running sshd
126 under that user account. You must change /etc/sshd_config
127 to contain the following:
128
129 RSAAuthentication yes
130
131 Moreover it's possible to use rhosts and/or rhosts with
132 RSA authentication by setting the following in sshd_config:
133
134 RhostsAuthentication yes
135 RhostsRSAAuthentication yes
136
137- If you want to be able to login to different user accounts you'll
138 have to start sshd under system account or any other account that
139 is able to switch user context. Note that administrators are _not_
140 able to do that by default! You'll have to give the following
141 special user rights to the user:
142 "Act as part of the operating system"
143 "Replace process level token"
144 "Increase quotas"
145 and if used via service manager
146 "Logon as a service".
147
148 The system account does of course own that user rights by default.
149
150 Unfortunately, if you choose that way, you can only logon with
151 NT password authentification and you should change
152 /etc/sshd_config to contain the following:
153
154 PasswordAuthentication yes
155 RhostsAuthentication no
156 RhostsRSAAuthentication no
157 RSAAuthentication no
158
159 However you can login to the user which has started sshd with
160 RSA authentication anyway. If you want that, change the RSA
161 authentication setting back to "yes":
162
163 RSAAuthentication yes
164
165Please note that OpenSSH does never use the value of $HOME to 164Please note that OpenSSH does never use the value of $HOME to
166search for the users configuration files! It always uses the 165search for the users configuration files! It always uses the
167value of the pw_dir field in /etc/passwd as the home directory. 166value of the pw_dir field in /etc/passwd as the home directory.
@@ -169,7 +168,7 @@ If no home diretory is set in /etc/passwd, the root directory
169is used instead! 168is used instead!
170 169
171You may use all features of the CYGWIN=ntsec setting the same 170You may use all features of the CYGWIN=ntsec setting the same
172way as they are used by the `login' port on sources.redhat.com: 171way as they are used by Cygwin's login(1) port:
173 172
174 The pw_gecos field may contain an additional field, that begins 173 The pw_gecos field may contain an additional field, that begins
175 with (upper case!) "U-", followed by the domain and the username 174 with (upper case!) "U-", followed by the domain and the username
@@ -186,6 +185,8 @@ way as they are used by the `login' port on sources.redhat.com:
186 185
187 locuser::1104:513:John Doe,U-user,S-1-5-21-... 186 locuser::1104:513:John Doe,U-user,S-1-5-21-...
188 187
188Note that the CYGWIN=ntsec setting is required for public key authentication.
189
189SSH2 server and user keys are generated by the `ssh-*-config' scripts 190SSH2 server and user keys are generated by the `ssh-*-config' scripts
190as well. 191as well.
191 192
@@ -194,15 +195,30 @@ configure are used for the Cygwin binary distribution:
194 195
195 --prefix=/usr \ 196 --prefix=/usr \
196 --sysconfdir=/etc \ 197 --sysconfdir=/etc \
197 --libexecdir='${exec_prefix}/sbin' 198 --libexecdir='$(sbindir)' \
198 199 --localstatedir=/var \
199You must have installed the zlib and openssl packages to be able to 200 --datadir='$(prefix)/share' \
201 --mandir='$(datadir)/man' \
202 --with-tcp-wrappers
203
204If you want to create a Cygwin package, equivalent to the one
205in the Cygwin binary distribution, install like this:
206
207 mkdir /tmp/cygwin-ssh
208 cd $(builddir)
209 make install DESTDIR=/tmp/cygwin-ssh
210 cd $(srcdir)/contrib/cygwin
211 make cygwin-postinstall DESTDIR=/tmp/cygwin-ssh
212 cd /tmp/cygwin-ssh
213 find * \! -type d | tar cvjfT my-openssh.tar.bz2 -
214
215You must have installed the zlib and openssl-devel packages to be able to
200build OpenSSH! 216build OpenSSH!
201 217
202Please send requests, error reports etc. to cygwin@cygwin.com. 218Please send requests, error reports etc. to cygwin@cygwin.com.
203 219
204Have fun, 220Have fun,
205 221
206Corinna Vinschen <vinschen@redhat.com> 222Corinna Vinschen
207Cygwin Developer 223Cygwin Developer
208Red Hat Inc. 224Red Hat Inc.