From dwd at bell-labs.com Tue Feb 1 01:29:41 2000 From: dwd at bell-labs.com (Dave Dykstra) Date: Mon, 31 Jan 2000 08:29:41 -0600 Subject: EGD requirement a show stopper for me In-Reply-To: <38956F93.CD1D028@dial.pipex.com>; from Andre Lucas on Mon, Jan 31, 2000 at 11:18:43AM +0000 References: <20000131090134.L27654@itspc142.dur.ac.uk> <38955A20.CC3376EB@dial.pipex.com> <20000131100808.M27654@itspc142.dur.ac.uk> <38956F93.CD1D028@dial.pipex.com> Message-ID: <20000131082941.B24164@lucent.com> On Mon, Jan 31, 2000 at 11:18:43AM +0000, Andre Lucas wrote: > Andrew Stribblehill wrote: > 8< > > If we assume that sshd is around all the time, there is no way for > > local users to login to other machines whilst disallowing ssh > > logins to localhost. (A sort of runlevel-2 state.) If it's > > considered that this is of minority interest, perhaps PRNG stuff > > /should/ be compiled in. > > > Good point. The prng code would need to be linked into ssh as well as > sshd - as it is in ssh-1.2.27 - and the state would be picked up from a > file. The biggest problem I see with that would be that the ssh > executable would have to be setuid to access the seed and key > files if there was no other program running to manage this. > > IMHO the best way is indeed to have a standalone daemon. Reading output > from a pipe, it's as close to a portable random device as we're likely > to get. EGD is good, but because it's written in Perl it's slow and big. > With a C prng as a separate program it should be easier to maintain, and > it would be easier to protect the statefiles that Yarrow wants. I can't > think of a reason why it would have to run as root, either. In my case, I have many users who run a non-setuid ssh (1.2.27) client on machines that do not have sshd running. I do not understand why people seem to dislike the idea of generating the initial random number from an entropy source and from then on saving a seed in a file. That's what ssh 1.2.27 and PGP do; have they been criticized for that? Sure it's a problem if somebody is able to break into your machine and read the seed file, but if somebody can do that then all bets are off anyway. GnuPG also does not save anything in a seed file, so there must be something to it. Perhaps people are worried about physical seizing of hardware; I'm not worried about that, and besides I don't see how that would be an issue for OpenSSH because it has nothing to protect once the power has been turned off on a machine thus tearing down all SSH sessions. GnuPG is different in that respect because if somebody seized the seed file they may be able to guess what random key was used to encrypt data in a file. - Dave Dykstra From andre.lucas at dial.pipex.com Tue Feb 1 02:03:39 2000 From: andre.lucas at dial.pipex.com (Andre Lucas) Date: Mon, 31 Jan 2000 15:03:39 +0000 Subject: EGD requirement a show stopper for me References: <20000131090134.L27654@itspc142.dur.ac.uk> <38955A20.CC3376EB@dial.pipex.com> <20000131100808.M27654@itspc142.dur.ac.uk> <38956F93.CD1D028@dial.pipex.com> <20000131082941.B24164@lucent.com> Message-ID: <3895A44B.7FB4B62D@dial.pipex.com> Dave Dykstra wrote: 8< > I do not understand why people seem to dislike the idea of generating the > initial random number from an entropy source and from then on saving a seed > in a file. That's what ssh 1.2.27 and PGP do; have they been criticized > for that? Sure it's a problem if somebody is able to break into your I don't have the slightest concern about saving the PRNG state. Sorry if it came across that way. I do think that there's no need for the randseed to be exposed if you don't have to, as it's part of the PRNG's state and so Its Disclosure Is Probably A Bad Thing. Even though it is immediately stirred into the real-time entropy pool, if it wasn't an important component of the PRNG state there would be no point in saving it. All the Counterpane PRNG lit suggests that state compromise attacks are truly bad, and even if Yarrow is resistant to them I don't see the need to risk it. 8< > has been turned off on a machine thus tearing down all SSH sessions. GnuPG > is different in that respect because if somebody seized the seed file they > may be able to guess what random key was used to encrypt data in a file. I'm no authority of any kind on PRNG implementations or the software you've listed. So this is just a barely educated opinion. I think it's a good thing to save the random seed, as if you have confidence in your PRNG it's a good random value with which to initialise the generator. Since my understanding is that good entropy is hard to find(tm), why waste it? Ta, -Andre > > - Dave Dykstra From O.Stahl at lsw.uni-heidelberg.de Tue Feb 1 02:16:52 2000 From: O.Stahl at lsw.uni-heidelberg.de (Otmar Stahl) Date: Mon, 31 Jan 2000 16:16:52 +0100 Subject: Problem building OpenSSH-1.2.2 on HP-UX Message-ID: <20000131161652.A21653@fors.lsw.uni-heidelberg.de> Hi, Just wanted to let you know, that I had a small problem when compiling OpenSSH-1.2.2 on a HP-UX 10.20 trusted system. I used gcc-2.95.2 as compiler. I finally could compile it, but I had to comment two lines in login.c. (I am using openssl-0.9.4 and egd-0.6, if this matters.) line 236: login(&u, &utx); and the closing brace in line 272. Commenting these two lines it compiled ok and also seems to run fine. Kind regards, Otmar Stahl From andre.lucas at dial.pipex.com Tue Feb 1 02:37:30 2000 From: andre.lucas at dial.pipex.com (Andre Lucas) Date: Mon, 31 Jan 2000 15:37:30 +0000 Subject: Problem building OpenSSH-1.2.2 on HP-UX References: <20000131161652.A21653@fors.lsw.uni-heidelberg.de> Message-ID: <3895AC3A.26788B1E@dial.pipex.com> Is it possible you could send the compiler errors for the unedited OpenSSH 1.2.2, and the contents of config.h after running configure? Ta, -Andre Otmar Stahl wrote: > > Hi, > > Just wanted to let you know, that I had a small problem when compiling > OpenSSH-1.2.2 on a HP-UX 10.20 trusted system. I used gcc-2.95.2 as > compiler. I finally could compile it, but I had to comment two lines in > login.c. (I am using openssl-0.9.4 and egd-0.6, if this matters.) > > line 236: > > login(&u, &utx); > > and the closing brace in line 272. > > Commenting these two lines it compiled ok and also seems to run fine. > > Kind regards, > Otmar Stahl From O.Stahl at lsw.uni-heidelberg.de Tue Feb 1 02:45:41 2000 From: O.Stahl at lsw.uni-heidelberg.de (Otmar Stahl) Date: Mon, 31 Jan 2000 16:45:41 +0100 Subject: Problem building OpenSSH-1.2.2 on HP-UX In-Reply-To: <3895AC3A.26788B1E@dial.pipex.com> References: <20000131161652.A21653@fors.lsw.uni-heidelberg.de> <3895AC3A.26788B1E@dial.pipex.com> Message-ID: <20000131164541.A21826@fors.lsw.uni-heidelberg.de> On Mon, Jan 31, 2000 at 03:37:30PM +0000, Andre Lucas wrote: > Is it possible you could send the compiler errors for the unedited > OpenSSH 1.2.2, and the contents of config.h after running configure? Thank you for the fast reply! I attach config.h The first compiler error is: gcc -g -O2 -Wall -I/usr/local/ssl/include -D_HPUX_SOURCE -DETCDIR=\"/usr/local/etc\" -DSSH_PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ssh/ssh-askpass\" -DHAVE_CONFIG_H -c login.c login.c:236: parse error before &' login.c:236: warning: type defaults to int' in declaration of login' login.c:236: conflicting types for login' bsd-login.h:12: previous declaration of login' login.c:236: warning: data definition has no type or storage class *** Error exit code 1 Stop. After commenting line 236, I get: gcc -g -O2 -Wall -I/usr/local/ssl/include -D_HPUX_SOURCE -DETCDIR=\"/usr/local/etc\" -DSSH_PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ssh/ssh-askpass\" -DHAVE_CONFIG_H -c login.c login.c:272: parse error before }' *** Error exit code 1 Stop. Kind regards, Otmar > Ta, > -Andre > > Otmar Stahl wrote: > > > > Hi, > > > > Just wanted to let you know, that I had a small problem when compiling > > OpenSSH-1.2.2 on a HP-UX 10.20 trusted system. I used gcc-2.95.2 as > > compiler. I finally could compile it, but I had to comment two lines in > > login.c. (I am using openssl-0.9.4 and egd-0.6, if this matters.) > > > > line 236: > > > > login(&u, &utx); > > > > and the closing brace in line 272. > > > > Commenting these two lines it compiled ok and also seems to run fine. > > > > Kind regards, > > Otmar Stahl -------------- next part -------------- An embedded and charset-unspecified text was scrubbed... Name: config.h Url: http://lists.mindrot.org/pipermail/openssh-unix-dev/attachments/20000131/68c8e065/attachment.h From O.Stahl at lsw.uni-heidelberg.de Tue Feb 1 02:48:35 2000 From: O.Stahl at lsw.uni-heidelberg.de (Otmar Stahl) Date: Mon, 31 Jan 2000 16:48:35 +0100 Subject: Problem building OpenSSH-1.2.2 on HP-UX In-Reply-To: <3895AC3A.26788B1E@dial.pipex.com> References: <20000131161652.A21653@fors.lsw.uni-heidelberg.de> <3895AC3A.26788B1E@dial.pipex.com> Message-ID: <20000131164835.A21868@fors.lsw.uni-heidelberg.de> Hello again, I forgot to mention that I see error messages in the syslog of the form: Jan 31 16:34:13 hp3 sshd[5320]: error: ioctl I_PUSH ttcompat: Invalid argument Nevertheless, everything seems to work ok. Kind regards, Otmar On Mon, Jan 31, 2000 at 03:37:30PM +0000, Andre Lucas wrote: > Is it possible you could send the compiler errors for the unedited > OpenSSH 1.2.2, and the contents of config.h after running configure? > > Ta, > -Andre > > Otmar Stahl wrote: > > > > Hi, > > > > Just wanted to let you know, that I had a small problem when compiling > > OpenSSH-1.2.2 on a HP-UX 10.20 trusted system. I used gcc-2.95.2 as > > compiler. I finally could compile it, but I had to comment two lines in > > login.c. (I am using openssl-0.9.4 and egd-0.6, if this matters.) > > > > line 236: > > > > login(&u, &utx); > > > > and the closing brace in line 272. > > > > Commenting these two lines it compiled ok and also seems to run fine. > > > > Kind regards, > > Otmar Stahl From ishikawa at yk.rim.or.jp Tue Feb 1 04:39:57 2000 From: ishikawa at yk.rim.or.jp (Ishikawa) Date: Tue, 01 Feb 2000 02:39:57 +0900 Subject: 1.2.2 : transport endpoint is not connected. Message-ID: <3895C8ED.E63CBB16@yk.rim.or.jp> Hi, Thank you for the great OpenSSH package. I obtained 1.2.2 and tried it on linux 2.2.14. I had reported earlier that I saw "Transport endpoint is not connected" warning messages were observed on the linux 2.2.14 kernel with earlier release of openssh. The same happens when I used the port-forwarded HTTP connection. But this time, after accessing such http connections, I noticed that there are now cases of "[i1 o16] " as opposed to [i1 o128]" in the warning messages. Following is a copy of real warning message I collected a few minutes ago. [o128 meant the connection was closed. But o16 seems to suggest that output was open. from nchan.h: #define CHAN_OUTPUT_OPEN 0x10 #define CHAN_OUTPUT_WAIT_DRAIN 0x20 #define CHAN_OUTPUT_WAIT_IEOF 0x40 #define CHAN_OUTPUT_CLOSED 0x80 So something seems to be wrong.] chan_shutdown_read failed for #12/fd16 [i1 o16]: Transport endpoint is not connected chan_shutdown_read failed for #9/fd13 [i1 o128]: Transport endpoint is not connected chan_shutdown_read failed for #13/fd17 [i1 o128]: Transport endpoint is not connected chan_shutdown_read failed for #8/fd12 [i1 o128]: Transport endpoint is not connected chan_shutdown_read failed for #12/fd16 [i1 o128]: Transport endpoint is not connected chan_shutdown_read failed for #13/fd17 [i1 o128]: Transport endpoint is not connected chan_shutdown_read failed for #15/fd19 [i1 o128]: Transport endpoint is not connected chan_shutdown_read failed for #14/fd18 [i1 o128]: Transport endpoint is not connected chan_shutdown_read failed for #8/fd12 [i1 o128]: Transport endpoint is not connected chan_shutdown_read failed for #8/fd12 [i1 o128]: Transport endpoint is not connected chan_shutdown_read failed for #10/fd14 [i1 o128]: Transport endpoint is not connected chan_shutdown_read failed for #12/fd16 [i1 o16]: Transport endpoint is not connected chan_shutdown_read failed for #9/fd13 [i1 o128]: Transport endpoint is not connected chan_shutdown_read failed for #8/fd12 [i1 o16]: Transport endpoint is not connected chan_shutdown_read failed for #13/fd17 [i1 o128]: Transport endpoint is not connected The gateway that runs sshd is Solaris 2.5.1. But the port-forwarded http server beyond that sshd host is sunos 4.1.4 if memory serves. Thak you again for the package. Happy Hacking From andre.lucas at dial.pipex.com Tue Feb 1 09:06:36 2000 From: andre.lucas at dial.pipex.com (Andre Lucas) Date: Mon, 31 Jan 2000 22:06:36 +0000 Subject: New liblogin 0.3alpha Message-ID: <20000131220636.A689@internal.domain> FYI a new version of liblogin, 0.3alpha, is up on my website at http://dspace.dial.pipex.com/andre.lucas/liblogin.html This version fixes a few bugs and has implementations for the full API, including 'get last login time' support, even for systems without lastlog. New OpenSSH patches against 1.2.2 are also available, to enable the last login time features. Again, the function (in this case get_last_login_time() ) reduces to four lines as the busy-work is shipped out of openssh-main and into the library. It's tested and running well on Linux, OpenBSD, HPUX10.20 and Solaris. Please check it out, and let me know how you get on. I'm particularly keen to see how it does on other platforms. The main todo right now is to add support for systems that don't define _PATH_UTMP etc. This will probably require file checks, which is a shame because I then lose the ability to cross-compile easily. Oh, well. Ta, -Andre -- Andre Lucas http://dspace.dial.pipex.com/andre.lucas/ From rlm at pricegrabber.com Tue Feb 1 16:17:59 2000 From: rlm at pricegrabber.com (Rob McMillin) Date: Mon, 31 Jan 2000 21:17:59 -0800 Subject: Making root equivalence work Message-ID: <38966C87.670FC194@pricegrabber.com> I have several machines that must have trusted root accounts, that is, I need to be able to run "ssh targethost command" on each by each, for the root user. I have had no success thus far doing so. Normally for the non-root users, all I have to do is set the /etc/ssh/known_hosts, build up the users' ~/.ssh/known_hosts, and the users will work without requiring passwords. (I'm using method 2 authentication.) All run openssh-1.2.1. What files do I need to configure? I already have PermitRootLogin yes RhostsRSAAuthentication yes in /etc/ssh/sshd_config. What am I missing? I still get prompted for a password every time I try to log in as root. -- http://www.pricegrabber.com | The best deals, all the time. From djm at mindrot.org Tue Feb 1 23:14:21 2000 From: djm at mindrot.org (Damien Miller) Date: Tue, 1 Feb 2000 23:14:21 +1100 (EST) Subject: rsync over ssh - lockups with pipe() In-Reply-To: <20000129123333Z13356428-11511+45588@samba.anu.edu.au> Message-ID: On Sat, 29 Jan 2000 tridge at linuxcare.com wrote: > For a couple of years people have been reporting intermittent problems > with rsync over ssh freezing during a large transfer (typically > several GB). I have now gotten to the bottom of these problems, and > have written a small test program which demonstrates a deadlock in > sshd when doing large bi-directional transfers. Luckily the problem is > easily solved by modifying sshd to use socketpair() instead of > pipe(). Just remove "#define USE_PIPES 1" from near the bottom of > includes.h does the trick. Behaviour (and fix) verified under Linux 2.2.12. OpenBSD 2.6 + errata seems not be affected. Can anyone detect any problems when using socket pairs? If not, I shall make it the default. Regards, Damien -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From djm at mindrot.org Tue Feb 1 23:15:39 2000 From: djm at mindrot.org (Damien Miller) Date: Tue, 1 Feb 2000 23:15:39 +1100 (EST) Subject: problems logging in from 1.2.2 client to 1.2.1pre24 server In-Reply-To: Message-ID: On Sat, 29 Jan 2000, Marc Haber wrote: > Hi! > > On my personal workstation, I have installed openssh 1.2.2. I > have two server machines, one (A) running a self-compiled openssh > 1.2.1pre24, and a different one (B) running an openssh1.2.1pre24 > compiled by someone else. What Platform & OS? what options was OpenSSH complied with? Damien -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From djm at mindrot.org Tue Feb 1 23:17:23 2000 From: djm at mindrot.org (Damien Miller) Date: Tue, 1 Feb 2000 23:17:23 +1100 (EST) Subject: ssh-1.2.2 freeze under Linux In-Reply-To: <200001292300.SAA11461@styx.net.copi> Message-ID: On Sat, 29 Jan 2000, Craig J Copi wrote: > After compiling and installing ssh-1.2.2 at home whenever I try to ssh > to a host ssh freezes and never actually tries to establish a > connection. Actually it depends on whether I'm dialed in or not > (it has to do with dns lookups, I'm not sure exactly what it is > doing). The problem seems to be caused by getaddrinfo in ssh.c, > line 511. If I strace the process it keeps trying to connect to my > dns server to resolve the name. If I use the full host name (or > if I'm dialed in) it claims > Secure connection to full.host.name refused. > However, no connection attempt is logged on the remote machine. Try the --with-ipv4-default option. Damien -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From cjc5 at po.cwru.edu Wed Feb 2 02:10:06 2000 From: cjc5 at po.cwru.edu (Craig J Copi) Date: Tue, 01 Feb 2000 10:10:06 -0500 Subject: ssh-1.2.2 freeze under Linux In-Reply-To: Your message of "Tue, 01 Feb 2000 23:17:23 +1100." Message-ID: <200002011510.KAA30997@boss.phys.cwru.edu> Damien Miller writes: >On Sat, 29 Jan 2000, Craig J Copi wrote: > >> After compiling and installing ssh-1.2.2 at home whenever I try to ssh >> to a host ssh freezes and never actually tries to establish a >> connection. Actually it depends on whether I'm dialed in or not >> (it has to do with dns lookups, I'm not sure exactly what it is >> doing). The problem seems to be caused by getaddrinfo in ssh.c, >> line 511. If I strace the process it keeps trying to connect to my >> dns server to resolve the name. If I use the full host name (or >> if I'm dialed in) it claims >> Secure connection to full.host.name refused. >> However, no connection attempt is logged on the remote machine. > >Try the --with-ipv4-default option. > >Damien I did. I used the RH spec file that comes with with the distribution. Craig From dwd at bell-labs.com Wed Feb 2 05:11:41 2000 From: dwd at bell-labs.com (Dave Dykstra) Date: Tue, 1 Feb 2000 12:11:41 -0600 Subject: looking for commercial supporters of openssh Message-ID: <20000201121141.A4405@lucent.com> The organization that sets standards for Unix software in my company is in the process of seeking a replacement for an internally-written remote command execution tool (essentially an rsh with extra features such as pseudo-tty support), and I'm trying to pursuade them to use ssh and ultimately openssh. Since we're Bell Labs, we have a lot of Unix machines. One of the things that organization requires is somebody to supply them with binaries for several different unix platforms and to promise them 7x24 hotline support. Of course they are willing to pay for that support. I could provide them binaries (I already provide ssh 1.2.27 to a non-privileged area on the bulk of the unix machines) but they're not comfortable with relying on one of their own employees for the round-the-clock support. I know that the license on ssh 1.2.27 prevents any company but f-secure from supporting that tool, but I'm looking forward to the time when openssh will be ready for them. If any of you have good suggestions for companies that will do a good job of this for openssh, please let me know right away. - Dave Dykstra From jmd at aoe.vt.edu Wed Feb 2 07:20:39 2000 From: jmd at aoe.vt.edu (Josh Durham) Date: Tue, 1 Feb 2000 15:20:39 -0500 Subject: login.c error Message-ID: I had a compile-time error in login.c .. It looks like someone was copying and pasting code and didn't check the variable names. Here's the diff: diff login.c.orig login.c 258c258 < snprintf(buf, sizeof(buf), "%s/%s", lastlog, logname); --- > snprintf(buf, sizeof(buf), "%s/%s", lastlog, user); - Josh * Josh Durham | AOE at Virginia Tech | (540) 231-9061 jdurham at vt.edu * From gem at rellim.com Wed Feb 2 08:08:06 2000 From: gem at rellim.com (Gary E. Miller) Date: Tue, 1 Feb 2000 13:08:06 -0800 (PST) Subject: EGD requirement a show stopper for me In-Reply-To: <3895A44B.7FB4B62D@dial.pipex.com> Message-ID: Yo All! A archive of the discussions on /dev/random from the linux-ipsec and coderpunks mailing lists is at: http://www.openpgp.net/random/index.html They have already covered this territory at length. There is also the source to a linux kernel /dev/random on that website and in it's doc the recommendation is made to save the entropy. I think the end result was that it was best to save what entropy that you had between sessions. Since this saved entropy should just be stirred in with whatever new entropy you can find, then you should never be worse off even if the old entropy is compromised. RGDS GARY On Mon, 31 Jan 2000, Andre Lucas wrote: > I'm no authority of any kind on PRNG implementations or the software > you've listed. So this is just a barely educated opinion. I think it's a > good thing to save the random seed, as if you have confidence in your > PRNG it's a good random value with which to initialise the generator. > Since my understanding is that good entropy is hard to find(tm), why > waste it? --------------------------------------------------------------------------- Gary E. Miller Rellim 20340 Empire Ave, Suite E-3, Bend, OR 97701 gem at rellim.com Tel:+1(541)382-8588 Fax: +1(541)382-8676 From karn at ka9q.ampr.org Wed Feb 2 08:48:33 2000 From: karn at ka9q.ampr.org (Phil Karn) Date: Tue, 1 Feb 2000 13:48:33 -0800 Subject: rsync over ssh - lockups with pipe() In-Reply-To: (message from Damien Miller on Tue, 1 Feb 2000 23:14:21 +1100 (EST)) References: Message-ID: <200002012148.NAA29502@homer.ka9q.ampr.org> >Can anyone detect any problems when using socket pairs? If not, I >shall make it the default. I'd still been noticing some occasional hangups in 1.2.2 while websurfing over a forwarded TCP connection. Both ends run Linux 2.2.14. I just commented out USE_PIPES in my builds and I'll see how this goes over the next couple of days. Phil From dwd at bell-labs.com Wed Feb 2 08:55:40 2000 From: dwd at bell-labs.com (Dave Dykstra) Date: Tue, 1 Feb 2000 15:55:40 -0600 Subject: EGD requirement a show stopper for me In-Reply-To: ; from Gary E. Miller on Tue, Feb 01, 2000 at 01:08:06PM -0800 References: <3895A44B.7FB4B62D@dial.pipex.com> Message-ID: <20000201155539.A13302@lucent.com> On Tue, Feb 01, 2000 at 01:08:06PM -0800, Gary E. Miller wrote: > Yo All! > > A archive of the discussions on /dev/random from the linux-ipsec > and coderpunks mailing lists is at: > http://www.openpgp.net/random/index.html > > They have already covered this territory at length. The access to the archive is kind of slow so I haven't seen it all, but I haven't spotted where they're talking about avoiding the use of /dev/random. Ipsec is a different situation because by its nature it will not be portable and, unlike ssh, they can make operating system changes. > There is also the source to a linux kernel /dev/random on that > website and in it's doc the recommendation is made to save the entropy. > > I think the end result was that it was best to save what entropy > that you had between sessions. Since this saved entropy should > just be stirred in with whatever new entropy you can find, then > you should never be worse off even if the old entropy is compromised. > > RGDS > GARY > > On Mon, 31 Jan 2000, Andre Lucas wrote: > > > I'm no authority of any kind on PRNG implementations or the software > > you've listed. So this is just a barely educated opinion. I think it's a > > good thing to save the random seed, as if you have confidence in your > > PRNG it's a good random value with which to initialise the generator. > > Since my understanding is that good entropy is hard to find(tm), why > > waste it? Ok, maybe I'm missing something. If you have a good initial seed to your PRNG and you save it in a protected file the way ssh 1.2.27 does, is there any problem with not using the EGD (or /dev/random because it's not available)? We could take some of the code from the EGD (ported to C) or from some other open source package to get the initial seed, when we don't mind spending a little extra time, and from then on do things more quickly without the aid of an external program or driver. Right? - Dave Dykstra From karn at ka9q.ampr.org Wed Feb 2 08:57:05 2000 From: karn at ka9q.ampr.org (Phil Karn) Date: Tue, 1 Feb 2000 13:57:05 -0800 Subject: logging RSA key IDs Message-ID: <200002012157.NAA29530@homer.ka9q.ampr.org> Hi. To compartmentalize things a bit (e.g., to help limit the damage should one of my machines be hacked and my private RSA keys stolen) I use different RSA key pairs on my different client machines. So it occurs to me that it would be nice if ssh could log which key was used when logging in to a particular account that has more than one entry in .ssh/authorized_keys. Right now it simply says "Accepted rsa for karn from " without saying which key was used. You obviously don't want to log the whole public key, just the comment field from the appropriate line in .ssh/authorized_keys would do. Phil From Marc.Haber-lists at gmx.de Wed Feb 2 09:32:57 2000 From: Marc.Haber-lists at gmx.de (Marc Haber) Date: Tue, 01 Feb 2000 22:32:57 GMT Subject: problems logging in from 1.2.2 client to 1.2.1pre24 server In-Reply-To: References: Message-ID: On Tue, 1 Feb 2000 23:15:39 +1100 (EST), you wrote: >On Sat, 29 Jan 2000, Marc Haber wrote: >> On my personal workstation, I have installed openssh 1.2.2. I >> have two server machines, one (A) running a self-compiled openssh >> 1.2.1pre24, and a different one (B) running an openssh1.2.1pre24 >> compiled by someone else. > >What Platform & OS? All three boxes are running Debian Linux on i386 type machines, fairly standard PC hardware. My personal machine is running the frozen beta version of Debian, potato, and the two servers run the stable released version of debian, slink. >what options was OpenSSH complied with? Can't say about the server boxes, on my client box I did a plain configure. I found out today that I can log in to both boxes using RSA authentication, but login to one of the servers still fails when I try to do plain password authentication. The error message is somewhat strange. Greetings Marc -- -------------------------------------- !! No courtesy copies, please !! ----- Marc Haber | " Questions are the | Mailadresse im Header Karlsruhe, Germany | Beginning of Wisdom " | Fon: *49 721 966 32 15 Nordisch by Nature | Lt. Worf, TNG "Rightful Heir" | Fax: *49 721 966 31 29 From karn at ka9q.ampr.org Wed Feb 2 09:44:27 2000 From: karn at ka9q.ampr.org (Phil Karn) Date: Tue, 1 Feb 2000 14:44:27 -0800 Subject: problems logging in from 1.2.2 client to 1.2.1pre24 server In-Reply-To: (Marc.Haber-lists@gmx.de) References: Message-ID: <200002012244.OAA29609@homer.ka9q.ampr.org> >I found out today that I can log in to both boxes using RSA >authentication, but login to one of the servers still fails when I try >to do plain password authentication. The error message is somewhat >strange. Try enabling shadow passwords. I had the same problem on my debian linux systems a while back, and enabling shadow passwords made the problem go away. Phil From gem at rellim.com Wed Feb 2 10:00:20 2000 From: gem at rellim.com (Gary E. Miller) Date: Tue, 1 Feb 2000 15:00:20 -0800 (PST) Subject: EGD requirement a show stopper for me In-Reply-To: <20000201155539.A13302@lucent.com> Message-ID: Yo Dave! The whole point of /dev/random is to add entropy to PNRG. The problem with a PNRG is that once you figure out the internal state of the PNRG you can recover past states and predict future states. Once you can predict states, even if the prediction is slightly off, then you have seriously reduced the strength of the encryption. This is the basis of the cracks for S/Key and some other crypto. The solution to this problem is to add entropy to your PNRG to make it more truly random. That is why openssh wants to use /dev/random or EGD at regular intervals. EGD is to much of a pig and /dev/random requires kernel patching. So I agree with you that porting something like EGD to C is the way to go. FreeS/WAN struggled with this issue for a while and then decided to just go with /dev/random. open-ssh does not have that option. RGDS GARY On Tue, 1 Feb 2000, Dave Dykstra wrote: > Date: Tue, 1 Feb 2000 15:55:40 -0600 > From: Dave Dykstra > To: Gary E. Miller > Cc: openssh-unix-dev at mindrot.org > Subject: Re: EGD requirement a show stopper for me > > On Tue, Feb 01, 2000 at 01:08:06PM -0800, Gary E. Miller wrote: > > Yo All! > > > > A archive of the discussions on /dev/random from the linux-ipsec > > and coderpunks mailing lists is at: > > http://www.openpgp.net/random/index.html > > > > They have already covered this territory at length. > > The access to the archive is kind of slow so I haven't seen it all, but I > haven't spotted where they're talking about avoiding the use of > /dev/random. Ipsec is a different situation because by its nature it will > not be portable and, unlike ssh, they can make operating system changes. > > > There is also the source to a linux kernel /dev/random on that > > website and in it's doc the recommendation is made to save the entropy. > > > > I think the end result was that it was best to save what entropy > > that you had between sessions. Since this saved entropy should > > just be stirred in with whatever new entropy you can find, then > > you should never be worse off even if the old entropy is compromised. > > > > RGDS > > GARY > > > > On Mon, 31 Jan 2000, Andre Lucas wrote: > > > > > I'm no authority of any kind on PRNG implementations or the software > > > you've listed. So this is just a barely educated opinion. I think it's a > > > good thing to save the random seed, as if you have confidence in your > > > PRNG it's a good random value with which to initialise the generator. > > > Since my understanding is that good entropy is hard to find(tm), why > > > waste it? > > > Ok, maybe I'm missing something. If you have a good initial seed to your > PRNG and you save it in a protected file the way ssh 1.2.27 does, is there > any problem with not using the EGD (or /dev/random because it's not > available)? We could take some of the code from the EGD (ported to C) or > from some other open source package to get the initial seed, when we don't > mind spending a little extra time, and from then on do things more quickly > without the aid of an external program or driver. Right? > > - Dave Dykstra > --------------------------------------------------------------------------- Gary E. Miller Rellim 20340 Empire Ave, Suite E-3, Bend, OR 97701 gem at rellim.com Tel:+1(541)382-8588 Fax: +1(541)382-8676 From djm at mindrot.org Wed Feb 2 19:17:37 2000 From: djm at mindrot.org (Damien Miller) Date: Wed, 2 Feb 2000 19:17:37 +1100 (EST) Subject: login.c error In-Reply-To: Message-ID: On Tue, 1 Feb 2000, Josh Durham wrote: > I had a compile-time error in login.c .. It looks like someone > was copying and pasting code and didn't check the variable names. > Here's the diff: Thanks, applied. -d -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From Marc.Haber-lists at gmx.de Wed Feb 2 19:21:48 2000 From: Marc.Haber-lists at gmx.de (Marc Haber) Date: Wed, 02 Feb 2000 08:21:48 GMT Subject: problems logging in from 1.2.2 client to 1.2.1pre24 server In-Reply-To: <200002012244.OAA29609@homer.ka9q.ampr.org> References: <200002012244.OAA29609@homer.ka9q.ampr.org> Message-ID: On Tue, 1 Feb 2000 14:44:27 -0800, you wrote: >>I found out today that I can log in to both boxes using RSA >>authentication, but login to one of the servers still fails when I try >>to do plain password authentication. The error message is somewhat >>strange. > >Try enabling shadow passwords. Enabled on all three systems. Can this have something to do with crypt(3)/MD5 password encryption? I don't know whether this is being used on the server that doesn't allow me to log in using passwords. However, PAM should handle that transparently, right? Greetings Marc -- -------------------------------------- !! No courtesy copies, please !! ----- Marc Haber | " Questions are the | Mailadresse im Header Karlsruhe, Germany | Beginning of Wisdom " | Fon: *49 721 966 32 15 Nordisch by Nature | Lt. Worf, TNG "Rightful Heir" | Fax: *49 721 966 31 29 From djm at mindrot.org Wed Feb 2 19:23:49 2000 From: djm at mindrot.org (Damien Miller) Date: Wed, 2 Feb 2000 19:23:49 +1100 (EST) Subject: EGD requirement a show stopper for me In-Reply-To: <20000201155539.A13302@lucent.com> Message-ID: On Tue, 1 Feb 2000, Dave Dykstra wrote: > Ok, maybe I'm missing something. If you have a good initial seed > to your PRNG and you save it in a protected file the way ssh 1.2.27 > does, is there any problem with not using the EGD (or /dev/random > because it's not available)? We could take some of the code from > the EGD (ported to C) or from some other open source package to > get the initial seed, when we don't mind spending a little extra > time, and from then on do things more quickly without the aid of an > external program or driver. Right? A seed alone is not enough. You need to occassionally add new entropy to the pool, otherwise your RNG is just a PRNG. OpenSSH already has a PRNG, which it seeds from /dev/urandom or from EGD - it trusts these to be high quality sources of random data. It would be great if someone could resurrect some of the entropy gathering hooks from ssh-1.2.16 and combine them with the pool functions of a Yarrow modified to use OpenSSL's crypto routines. -d -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From djm at mindrot.org Wed Feb 2 20:29:16 2000 From: djm at mindrot.org (Damien Miller) Date: Wed, 2 Feb 2000 20:29:16 +1100 (EST) Subject: logging RSA key IDs In-Reply-To: <200002012157.NAA29530@homer.ka9q.ampr.org> Message-ID: On Tue, 1 Feb 2000, Phil Karn wrote: > Hi. To compartmentalize things a bit (e.g., to help limit the damage > should one of my machines be hacked and my private RSA keys stolen) I > use different RSA key pairs on my different client machines. > > So it occurs to me that it would be nice if ssh could log which key > was used when logging in to a particular account that has more than > one entry in .ssh/authorized_keys. Right now it simply says "Accepted > rsa for karn from " without saying which key was used. > > You obviously don't want to log the whole public key, just the comment > field from the appropriate line in .ssh/authorized_keys would do. I don't think the comment is sent as part of the RSA authentication dialog, though it may be possible to log the fingerprint of the client user or host key. Attached is a quick and very dirty patch which does just that. Regards, Damien -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) -------------- next part -------------- ? ssh ? sshd ? configure ? config.h.in ? config.log ? config.h ? config.cache ? Makefile ? random.h ? random.c ? config.status ? ssh-add ? ssh-keygen ? scp ? ssh-agent ? scp.1.out ? ssh-add.1.out ? ssh-agent.1.out ? ssh-keygen.1.out ? ssh.1.out ? sshd.8.out ? sshd_config.out ? ssh_config.out Index: auth-rh-rsa.c =================================================================== RCS file: /var/cvs/openssh/auth-rh-rsa.c,v retrieving revision 1.7 diff -u -r1.7 auth-rh-rsa.c --- auth-rh-rsa.c 1999/11/25 00:54:57 1.7 +++ auth-rh-rsa.c 2000/02/02 09:28:51 @@ -22,7 +22,11 @@ #include "xmalloc.h" #include "uidswap.h" #include "servconf.h" +#include "fingerprint.h" +/* Client host fingerprint from rhosts RSA authentication. */ +extern char *rhost_fingerprint; + /* * Tries to authenticate the user using the .rhosts file and the host using * its host key. Returns true if authentication succeeds. @@ -103,5 +107,10 @@ verbose("Rhosts with RSA host authentication accepted for %.100s, %.100s on %.700s.", pw->pw_name, client_user, canonical_hostname); packet_send_debug("Rhosts with RSA host authentication accepted."); + + /* Take a copy of the rhost's key's fingerprint */ + rhost_fingerprint = xstrdup(fingerprint(client_host_key_e, + client_host_key_n)); + return 1; } Index: auth-rsa.c =================================================================== RCS file: /var/cvs/openssh/auth-rsa.c,v retrieving revision 1.12 diff -u -r1.12 auth-rsa.c --- auth-rsa.c 2000/01/20 11:44:09 1.12 +++ auth-rsa.c 2000/02/02 09:28:53 @@ -25,6 +25,7 @@ #include "mpaux.h" #include "uidswap.h" #include "servconf.h" +#include "fingerprint.h" #ifdef HAVE_OPENSSL #include @@ -43,6 +44,9 @@ extern char *forced_command; extern struct envstring *custom_environment; +/* Client fingerprint from RSA authentication. */ +extern char *client_fingerprint; + /* * Session identifier that is used to bind key exchange and authentication * responses to a particular session. @@ -286,6 +290,9 @@ */ authenticated = 1; + /* Take a copy of the client key's fingerprint */ + client_fingerprint = xstrdup(fingerprint(e, n)); + /* RSA part of authentication was accepted. Now process the options. */ if (options) { while (*options && *options != ' ' && *options != '\t') { Index: sshd.c =================================================================== RCS file: /var/cvs/openssh/sshd.c,v retrieving revision 1.55 diff -u -r1.55 sshd.c --- sshd.c 2000/01/26 00:07:22 1.55 +++ sshd.c 2000/02/02 09:29:04 @@ -101,6 +101,12 @@ /* RSA authentication "environment=" options. */ struct envstring *custom_environment = NULL; +/* Client fingerprint from RSA authentication. */ +char *client_fingerprint = NULL; + +/* Client host fingerprint from rhosts RSA authentication. */ +char *rhost_fingerprint = NULL; + /* Session id for the current session. */ unsigned char session_id[16]; @@ -1504,11 +1510,15 @@ type == SSH_CMSG_AUTH_PASSWORD) authlog = log; - authlog("%s %s for %.200s from %.200s port %d%s", + authlog("%s %s for %.200s %s%sfrom %.200s %s%sport %d%s", authenticated ? "Accepted" : "Failed", get_authname(type), pw->pw_uid == 0 ? "ROOT" : pw->pw_name, + client_fingerprint != NULL?client_fingerprint:"", + client_fingerprint != NULL?" ":"", get_remote_ipaddr(), + rhost_fingerprint != NULL?rhost_fingerprint:"", + rhost_fingerprint != NULL?" ":"", get_remote_port(), user); From djm at mindrot.org Wed Feb 2 20:31:32 2000 From: djm at mindrot.org (Damien Miller) Date: Wed, 2 Feb 2000 20:31:32 +1100 (EST) Subject: problems logging in from 1.2.2 client to 1.2.1pre24 server In-Reply-To: Message-ID: On Wed, 2 Feb 2000, Marc Haber wrote: > Enabled on all three systems. Can this have something to do with > crypt(3)/MD5 password encryption? I don't know whether this is being > used on the server that doesn't allow me to log in using passwords. > However, PAM should handle that transparently, right? It /should/ though I haven't really tries the generic PAM file on Debian. Phil Hands had Debian packages that were working OK - perhaps you could nab the PAM config file from one of those. Damien -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From dwd at bell-labs.com Thu Feb 3 02:41:46 2000 From: dwd at bell-labs.com (Dave Dykstra) Date: Wed, 2 Feb 2000 09:41:46 -0600 Subject: EGD requirement a show stopper for me In-Reply-To: ; from Gary E. Miller on Tue, Feb 01, 2000 at 03:00:20PM -0800 References: <20000201155539.A13302@lucent.com> Message-ID: <20000202094146.B21734@lucent.com> On Tue, Feb 01, 2000 at 03:00:20PM -0800, Gary E. Miller wrote: > The whole point of /dev/random is to add entropy to PNRG. The problem > with a PNRG is that once you figure out the internal state of the PNRG > you can recover past states and predict future states. Once you can > predict states, even if the prediction is slightly off, then you have > seriously reduced the strength of the encryption. > > This is the basis of the cracks for S/Key and some other crypto. OK, but could one figure out the internal state of the PNRG without having access to the seed file? I'm not worried about compromise of the seed file. I would think that if somebody could figure out what numbers were being generated by the PNRG they could predict what it might do in the future, but as far as I know there's no way for someone to do that without having already broken into the legitimate client or server. I don't get why SSH 1.2.27 can do without /dev/random and EGD and yet there's been no CERT advisories saying that that part of SSH is insecure. > The solution to this problem is to add entropy to your PNRG to make > it more truly random. That is why openssh wants to use /dev/random > or EGD at regular intervals. EGD is to much of a pig and /dev/random > requires kernel patching. So I agree with you that porting something > like EGD to C is the way to go. It's not enough to just port EGD to C, it needs to be integrated with openssh and very preferably not be a separate process. There's nothing inherently wrong with that, is there (ignoring for the moment the amount of work it would take)? - Dave Dykstra From mouring at pconline.com Thu Feb 3 03:10:17 2000 From: mouring at pconline.com (Ben Lindstrom) Date: Wed, 2 Feb 2000 10:10:17 -0600 (CST) Subject: EGD requirement a show stopper for me In-Reply-To: <20000202094146.B21734@lucent.com> Message-ID: On Wed, 2 Feb 2000, Dave Dykstra wrote: > On Tue, Feb 01, 2000 at 03:00:20PM -0800, Gary E. Miller wrote: [..] > > The solution to this problem is to add entropy to your PNRG to make > > it more truly random. That is why openssh wants to use /dev/random > > or EGD at regular intervals. EGD is to much of a pig and /dev/random > > requires kernel patching. So I agree with you that porting something > > like EGD to C is the way to go. > > It's not enough to just port EGD to C, it needs to be integrated with > openssh and very preferably not be a separate process. There's nothing > inherently wrong with that, is there (ignoring for the moment the amount > of work it would take)? > I think the main consern is if you have 5 clients all with their own EGD built into OpenSSH. They could all be pulling the same entropy and all coming up with pretty close to the same random numbers. Enough that it could be used against the box in question. Or maybe I'm off.. That is what I see at this point. Since the logic is all the same. And your feeding roughly the same data into the function. Your going to get common results. Where as a /dev/random or a single EGD process controls what each client gets out of the entropy pool therefor the data should (if it's a good sampling of entropy) be different. From stheinri at hamilton1.physik.uni-konstanz.de Thu Feb 3 03:17:26 2000 From: stheinri at hamilton1.physik.uni-konstanz.de (Stefan Heinrichs) Date: Wed, 2 Feb 2000 17:17:26 +0100 Subject: Bugreport: OpenSSH-1.2.2 Server for Linux (glibc 2.1.2) Message-ID: <20000202171726.A3423@curie.physik.uni-konstanz.de> Hi, I would like to report a bug in OpenSSH-1.2.2 (release) under Linux. Under certain conditions the sshd client process segfaults while doing the password authentification. I have observed the behaviour with glibc 2.0.7 (non-PAM), glibc 2.1.1 (PAM) and glibc 2.1.2 (PAM), when 'RhostsRSAAuthentication yes' is chosen in sshd_config. It appears to happen regardless whether PAM is used or not (but under slightly different conditions). With glibc 2.0.7/2.1.1 it happens at the first password authentication attempt, while with glibc 2.1.2 things are a bit more complicated: With PAM enabled the segfault happens at the second or third password authentication attempt regardless whether this attempt would have succeeded (i.e. when I entered the right password) or not. With PAM disabled (--without-pam) I was only able to observe it at an password authentication attempt > 1 when this attempt would have succeeded. Here is a debugger session on a glibc 2.1.2 (SuSE 6.3) system, where sshd was compiled with PAM enabled, the sshd_config file was the example file from opensshd-1.2.2.tar.gz where RhostsRSAAuthentication yes has been set: (gdb) run Starting program: /home/bernd/download/openssh-1.2.2/sshd -d -f sshd_config debug: sshd version OpenSSH-1.2.2 debug: Bind to port 22 on 0.0.0.0. Server listening on 0.0.0.0 port 22. Generating 768 bit RSA key. RSA key generation complete. debug: Server will not fork when running in debugging mode. Connection from 127.0.0.1 port 890 debug: Client protocol version 1.5; client software version OpenSSH-1.2.2 debug: Sent 768 bit public key and 1023 bit host key. debug: Encryption type: 3des debug: Received session key; encryption turned on. debug: Installing crc compensation attack detector. debug: Starting up PAM with username "bernd" debug: Attempting authentication for bernd. debug: Trying rhosts with RSA host authentication for bernd Failed rhosts-rsa for bernd from 127.0.0.1 port 890 ruser bernd debug: PAM Password authentication for "bernd" failed: Authentication failure Failed password for bernd from 127.0.0.1 port 890 Program received signal SIGSEGV, Segmentation fault. 0x400b0ef2 in chunk_alloc (ar_ptr=0x40149ba0, nb=16) at malloc.c:2707 2707 malloc.c: No such file or directory. (gdb) where #0 0x400b0ef2 in chunk_alloc (ar_ptr=0x40149ba0, nb=16) at malloc.c:2707 #1 0x400b0e14 in __libc_malloc (bytes=8) at malloc.c:2651 #2 0x804ec58 in pamconv (num_msg=1, msg=0xbfffeca0, resp=0xbfffeca4, appdata_ptr=0x0) at auth-pam.c:43 #3 0x40019911 in __get_authtok () from /lib/security/pam_unix.so #4 0x40017a5d in pam_sm_authenticate () from /lib/security/pam_unix.so #5 0x4004f648 in pam_fail_delay () from /lib/libpam.so.0 #6 0x4004f9ce in _pam_dispatch () from /lib/libpam.so.0 #7 0x400512cc in pam_authenticate () from /lib/libpam.so.0 #8 0x804ef47 in auth_pam_password (pw=0xbffff24c, password=0x80826c0 "asdf") at auth-pam.c:136 #9 0x804c75d in do_authloop (pw=0xbffff24c) at sshd.c:1445 #10 0x804c329 in do_authentication () at sshd.c:1248 #11 0x804bb58 in main (ac=4, av=0xbffff8a4) at sshd.c:873 I hope this report helps finding the bug. If you would like me to perform further tests, please let me know. Best regards, Stefan and Bernd (who originally found this behavior) ------------------------------------------------------------------- Email: Stefan.Heinrichs at uni-konstanz.de Address: Fakulaet fuer Physik, Universitaet Konstanz, Universitaetsstr.10, 78457 Konstanz, Germany Phone: +49 7531 88 3814 From andre.lucas at dial.pipex.com Thu Feb 3 03:24:30 2000 From: andre.lucas at dial.pipex.com (Andre Lucas) Date: Wed, 02 Feb 2000 16:24:30 +0000 Subject: EGD requirement a show stopper for me References: <20000201155539.A13302@lucent.com> <20000202094146.B21734@lucent.com> Message-ID: <38985A3E.19D600D7@dial.pipex.com> Dave Dykstra wrote: > 8< > OK, but could one figure out the internal state of the PNRG without having > access to the seed file? I'm not worried about compromise of the seed file. > I would think that if somebody could figure out what numbers were being > generated by the PNRG they could predict what it might do in the future, but > as far as I know there's no way for someone to do that without having already > broken into the legitimate client or server. > > I don't get why SSH 1.2.27 can do without /dev/random and EGD and yet > there's been no CERT advisories saying that that part of SSH is insecure. > That's not the way I would look at things. The absence of a compromise doesn't mean none exist. (I'm sure that's not what you meant either.) I don't accept that what ssh-1 is prepared to live with is necessarily the right way for us to go. Your point is taken. I don't think most people who use SSH use it to protect against people already logged in. Though I still think the setuid() argument stands, there are other problems with running standalone. A daemon sitting in the background has (potentially at least) a much larger entropy pool to work with, and that should give a more random result. 8< > It's not enough to just port EGD to C, it needs to be integrated with > openssh and very preferably not be a separate process. There's nothing > inherently wrong with that, is there (ignoring for the moment the amount > of work it would take)? I don't agree that it *has* to be directly linked in. That would make it easier to deploy, which is a win, and if that's the prime goal then fine. I suspect that, all things being equal, everyone would like to use /dev/random (a special case of a standalone entropy gathering program) over builtin functions with designed-in limitations. Since we have to implement something (or just stick with EGD; probably not acceptable for long) we should at least consider all the options. Disregarding the amount of work, I think it would be better to have it separate. What goes into OpenSSH is Damien's call, though, and since it's a lot of work for someone either way it might be good to see what that decision turns out to be in this case. Ta, -Andre From gem at rellim.com Thu Feb 3 06:10:19 2000 From: gem at rellim.com (Gary E. Miller) Date: Wed, 2 Feb 2000 11:10:19 -0800 (PST) Subject: EGD requirement a show stopper for me In-Reply-To: <200002021417.GAA21531@ns1.aplatform.com> Message-ID: Yo Niels! I think we basically agree, except you missed one point. SCO has no /dev/random, so open-ssh has no way of reseeding except with EGD. The problem is to find a portable way to reseed the PNRG on all UNIX hosts, even those with no /dev/random and without the problems of EGD. RGDS GARY On Wed, 2 Feb 2000, Niels Provos wrote: > Date: Wed, 02 Feb 2000 09:16:38 -0500 > From: Niels Provos > To: gary miller > Cc: Dave Dykstra , openssh-unix-dev at mindrot.org > Subject: Re: EGD requirement a show stopper for me > > In message , "Gary > E. Miller" writes: > >FreeS/WAN struggled with this issue for a while and then decided > >to just go with /dev/random. open-ssh does not have that option. > OpenSSH uses the alleged RC4 stream cipher to stretch the randomness > provided by /dev/random into a longer interval. This is a sane > approach and as far as I can see is practially as secure as the > mathematical requirements for pseudo-random generators. Furthermore, > RC4's internal state is reseeded fairly often from /dev/random. > Looking at purely statistical tests, using RC4 is far better than the > raw output from /dev/random - at least the last time that I checked on > it. > > Niels. > --------------------------------------------------------------------------- Gary E. Miller Rellim 20340 Empire Ave, Suite E-3, Bend, OR 97701 gem at rellim.com Tel:+1(541)382-8588 Fax: +1(541)382-8676 From Harald at iki.fi Thu Feb 3 06:33:35 2000 From: Harald at iki.fi (Harald Hannelius) Date: Wed, 2 Feb 2000 21:33:35 +0200 (EET) Subject: MD5 have to be enabled in acconfig.h by hand Message-ID: I noticed that openssh-1.2.2 doesn't build correctly on my slackware-7.0 (glibc-2.1.2) and with md5-passwords. One have to define "HAVE_MD5_PASSWORDS" in acconfig.h by hand, even if I choose --enable-md5-passwords when configuring. I find this to be a bug. All configuration should be done from ./configure solely when building. Is there btw a good reason for --with-ipv4-default *not* being the default? Otherwise, thanks a lot for a free-licensed and fast ssh-suite!! Keep up the good work. =========================================================== Harald H Hannelius | Harald at iki.fi | GSM +358405470870 =========================================================== From Harald at iki.fi Thu Feb 3 07:01:44 2000 From: Harald at iki.fi (Harald Hannelius) Date: Wed, 2 Feb 2000 22:01:44 +0200 (EET) Subject: bash: scp: command not found Message-ID: How come I can't get scp to work properly. It just complains like this: scp foo host: bash: scp: command not found lost connection =========================================================== Harald H Hannelius | Harald at iki.fi | GSM +358405470870 =========================================================== From domi at saargate.de Thu Feb 3 07:00:58 2000 From: domi at saargate.de (Dominik Brettnacher) Date: Wed, 2 Feb 2000 21:00:58 +0100 (CET) Subject: bash: scp: command not found In-Reply-To: Message-ID: On Wed, 2 Feb 2000, Harald at iki.fi wrote: > How come I can't get scp to work properly. It just complains like this: > > scp foo host: > bash: scp: command not found > lost connection Maybe you should check for the path on the remote machine: it seems like the remote shell can't find scp in its $PATH. -- Dominik - http://www.saargate.de/~domi/ From gem at rellim.com Thu Feb 3 07:12:08 2000 From: gem at rellim.com (Gary E. Miller) Date: Wed, 2 Feb 2000 12:12:08 -0800 (PST) Subject: EGD requirement a show stopper for me In-Reply-To: <20000202094146.B21734@lucent.com> Message-ID: Yo Dave! On Wed, 2 Feb 2000, Dave Dykstra wrote: > > The whole point of /dev/random is to add entropy to PNRG. The problem > > with a PNRG is that once you figure out the internal state of the PNRG > > you can recover past states and predict future states. Once you can > > predict states, even if the prediction is slightly off, then you have > > seriously reduced the strength of the encryption. > > > > This is the basis of the cracks for S/Key and some other crypto. > > OK, but could one figure out the internal state of the PNRG without having > access to the seed file? I'm not worried about compromise of the seed file. > I would think that if somebody could figure out what numbers were being > generated by the PNRG they could predict what it might do in the future, but > as far as I know there's no way for someone to do that without having already > broken into the legitimate client or server. I am not a crptographer, I just listen to them, and they are all fanatics about having real randomness. A lot of these guys hook geiger counters, FM radio, zener diodes, sound cards, etc. because they think they see patterns in /dev/random. I am not that fanatic, but have seen attacks based on guessing the PRNG. > I don't get why SSH 1.2.27 can do without /dev/random and EGD and yet > there's been no CERT advisories saying that that part of SSH is insecure. If you check the file randoms.c in the ssh 1.2.27 source you will see how they do it. They pull in entropy from not only /dev/random if it is available, but from a lot of other sources. Sources like: ps laxww ps -al ls -alni /tmp/. w netstat -s netstat -an netstat -in As you can see, ssh is pretty paranoid about having a good random seed. RGDS GARY --------------------------------------------------------------------------- Gary E. Miller Rellim 20340 Empire Ave, Suite E-3, Bend, OR 97701 gem at rellim.com Tel:+1(541)382-8588 Fax: +1(541)382-8676 From gem at rellim.com Thu Feb 3 07:14:23 2000 From: gem at rellim.com (Gary E. Miller) Date: Wed, 2 Feb 2000 12:14:23 -0800 (PST) Subject: bash: scp: command not found In-Reply-To: Message-ID: Yo Harald! It sounds like the sshd on the remote end can not find it's copy of scp. Check the path that is complied into the remote sshd. RGDS GARY On Wed, 2 Feb 2000, Harald Hannelius wrote: > Date: Wed, 2 Feb 2000 22:01:44 +0200 (EET) > From: Harald Hannelius > To: openssh-unix-dev at mindrot.org > Subject: bash: scp: command not found > > > How come I can't get scp to work properly. It just complains like this: > > scp foo host: > bash: scp: command not found > lost connection > > > =========================================================== > Harald H Hannelius | Harald at iki.fi | GSM +358405470870 > =========================================================== > > > --------------------------------------------------------------------------- Gary E. Miller Rellim 20340 Empire Ave, Suite E-3, Bend, OR 97701 gem at rellim.com Tel:+1(541)382-8588 Fax: +1(541)382-8676 From enigma at nmt.edu Thu Feb 3 07:15:45 2000 From: enigma at nmt.edu (SysProg - Nathan Paul Simons) Date: Wed, 2 Feb 2000 13:15:45 -0700 (MST) Subject: bash: scp: command not found In-Reply-To: Message-ID: -----BEGIN PGP SIGNED MESSAGE----- On Wed, 2 Feb 2000, Harald Hannelius wrote: > > How come I can't get scp to work properly. It just complains like this: > > scp foo host: > bash: scp: command not found > lost connection i ran into this problem when i installed ssh in /usr/local/bin on our network. Apparently bash doesn't have /usr/local/bin in it's compiled in path, and it doesn't source /etc/profile. According to the bash man page: "When an interactive shell that is not a login shell is started, bash reads and executes commands from ~/.bashrc, if that file exists." Apparently, scp is considered a non-login interactive shell that invokes bash. A couple of solutions: 1. Make each user add /usr/local/bin (or wherever scp is) to their path in their ~/.bashrc 2. Recompile bash to have /usr/local/bin (or wherever scp is) in the default path. 3. Add an option to ssh to pass a path to the shell (i've seen this in commercial ssh-1.2.27 as --with-path). And then recompile it. 4. Put scp and ssh somewhere in bash's default path (which from my experience appears to be /usr/bin:/bin:/usr/sbin:/sbin). Systems Programmer - Nathan Paul Simons http://www.nmt.edu/~enigma Speare 20 x5748 -----BEGIN PGP SIGNATURE----- Version: 2.6.2 iQCVAwUBOJiQdIagi6ObDYzdAQFhVgP8Cp/Liqg7uAWemKZTsfx4prn6suERDTTd 7hphgIebuDpy5HsRbBQlE7wPzkvgwr8KA6sgfmgTp2XPkKzkJIvt+KJKzrwwMp62 7PWOb0mAchx6LK8MT6n2JNv0Ovvn2HlumOY1XyV1XvB3Z/Lq1+uWYz0rxfC+OWYz +BzT4BmjsBM= =8iY9 -----END PGP SIGNATURE----- From dwd at bell-labs.com Thu Feb 3 07:57:08 2000 From: dwd at bell-labs.com (Dave Dykstra) Date: Wed, 2 Feb 2000 14:57:08 -0600 Subject: EGD requirement a show stopper for me In-Reply-To: ; from Gary E. Miller on Wed, Feb 02, 2000 at 12:12:08PM -0800 References: <20000202094146.B21734@lucent.com> Message-ID: <20000202145707.A14862@lucent.com> On Wed, Feb 02, 2000 at 12:12:08PM -0800, Gary E. Miller wrote: > > I don't get why SSH 1.2.27 can do without /dev/random and EGD and yet > > there's been no CERT advisories saying that that part of SSH is insecure. > If you check the file randoms.c in the ssh 1.2.27 source you > will see how they do it. They pull in entropy from not only /dev/random > if it is available, but from a lot of other sources. Sources like: > ps laxww > ps -al > ls -alni /tmp/. > w > netstat -s > netstat -an > netstat -in > > As you can see, ssh is pretty paranoid about having a good random > seed. Note that random_acquire_environmental_noise() is only called if there is no seed file. After that they frequently mix the seed file with random_acquire_light_environmental_noise(). OpenSSH could do something like that and avoid a separate process. - Dave Dykstra From domi at saargate.de Thu Feb 3 07:58:11 2000 From: domi at saargate.de (Dominik Brettnacher) Date: Wed, 2 Feb 2000 21:58:11 +0100 (CET) Subject: problems with openssh-1.2.2 and pam_tacplus.so Message-ID: Hello, I have the following problem: I have installed openssh-1.2.2 on FreeBSD 3.4-RELEASE. I intentionally did not took the FreeBSD port because it does not support PAM. My aim is to make sshd authenticate against a TACACS+ server using the pam_tacplus.so module shipped with FreeBSD. That works perfectly with this line in my /etc/pam.conf: login auth sufficient pam_tacplus.so Accordingly, I set up pam.conf like this to make sshd do the same: sshd auth required pam_tacplus.so But all I get then from sshd is this: su-2.03# /usr/local/sbin/sshd -d debug: sshd version OpenSSH-1.2.2 debug: Bind to port 22 on 0.0.0.0. Server listening on 0.0.0.0 port 22. Generating 768 bit RSA key. RSA key generation complete. debug: Server will not fork when running in debugging mode. Connection from 212.88.133.252 port 1021 debug: Client protocol version 1.5; client software version OpenSSH-1.2.1 debug: Sent 768 bit public key and 1024 bit host key. debug: Encryption type: 3des debug: Received session key; encryption turned on. debug: Installing crc compensation attack detector. debug: Starting up PAM with username "domi" debug: Attempting authentication for domi. Failed rsa for domi from 212.88.133.252 port 1021 debug: PAM Password authentication accepted for user "domi" Accepted password for domi from 212.88.133.252 port 1021 debug: PAM setting rhost to "dominik.saargate.de" PAM rejected by account configuration: Permission denied Faking authloop for illegal user domi from 212.88.133.252 port 1021 I configured openssh with ./configure --with-tcp-wrappers --with-ipv4-default --with-md5-passwords What can I do in order to make sshd work correctly? -- Dominik - http://www.saargate.de/~domi/ From andre.lucas at dial.pipex.com Thu Feb 3 09:15:47 2000 From: andre.lucas at dial.pipex.com (Andre Lucas) Date: Wed, 2 Feb 2000 22:15:47 +0000 Subject: EGD requirement a show stopper for me In-Reply-To: ; from djm@mindrot.org on Wed, Feb 02, 2000 at 07:23:49PM +1100 References: <20000201155539.A13302@lucent.com> Message-ID: <20000202221547.A686@internal.domain> On Wed, Feb 02, 2000 at 07:23:49PM +1100, Damien Miller wrote: > It would be great if someone could resurrect some of the entropy > gathering hooks from ssh-1.2.16 and combine them with the pool > functions of a Yarrow modified to use OpenSSL's crypto routines. > I'm doing the yarrow port right now, it's just a slog through the Windows typedefs right now. -Andre -- Andre Lucas http://dspace.dial.pipex.com/andre.lucas/ From karn at ka9q.ampr.org Thu Feb 3 10:36:28 2000 From: karn at ka9q.ampr.org (Phil Karn) Date: Wed, 2 Feb 2000 15:36:28 -0800 Subject: bash: scp: command not found In-Reply-To: (message from SysProg - Nathan Paul Simons on Wed, 2 Feb 2000 13:15:45 -0700 (MST)) References: Message-ID: <200002022336.PAA03002@homer.ka9q.ampr.org> A much simpler workaround is to create this symbolic link: # ln -s /usr/local/bin/scp /usr/bin This is how I fixed the problem here (Debian slink, 2.2.14 kernel). Phil From karn at ka9q.ampr.org Thu Feb 3 10:58:54 2000 From: karn at ka9q.ampr.org (Phil Karn) Date: Wed, 2 Feb 2000 15:58:54 -0800 Subject: logging RSA key IDs In-Reply-To: (message from Damien Miller on Wed, 2 Feb 2000 20:29:16 +1100 (EST)) References: Message-ID: <200002022358.PAA03224@homer.ka9q.ampr.org> Thanks. The patch works as intended, though I have no tool to map those key fingerprints back into the actual keys listed in .ssh/authorized_keys... Phil From djm at mindrot.org Thu Feb 3 12:17:34 2000 From: djm at mindrot.org (Damien Miller) Date: Thu, 3 Feb 2000 12:17:34 +1100 (EST) Subject: Bugreport: OpenSSH-1.2.2 Server for Linux (glibc 2.1.2) In-Reply-To: <20000202171726.A3423@curie.physik.uni-konstanz.de> Message-ID: On Wed, 2 Feb 2000, Stefan Heinrichs wrote: > Hi, > > I would like to report a bug in OpenSSH-1.2.2 (release) under Linux. > > Under certain conditions the sshd client process segfaults while doing > the password authentification. I have observed the behaviour with This has been fixed: Index: sshd.c =================================================================== RCS file: /var/cvs/openssh/sshd.c,v retrieving revision 1.55 retrieving revision 1.56 diff -u -r1.55 -r1.56 --- sshd.c 2000/01/26 00:07:22 1.55 +++ sshd.c 2000/02/02 14:07:08 1.56 @@ -1524,8 +1524,10 @@ return; } - if (client_user != NULL) + if (client_user != NULL) { xfree(client_user); + client_user = NULL; + } if (attempt > AUTH_FAIL_MAX) packet_disconnect(AUTH_FAIL_MSG, pw->pw_name); -d -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From djm at mindrot.org Thu Feb 3 12:23:00 2000 From: djm at mindrot.org (Damien Miller) Date: Thu, 3 Feb 2000 12:23:00 +1100 (EST) Subject: MD5 have to be enabled in acconfig.h by hand In-Reply-To: Message-ID: On Wed, 2 Feb 2000, Harald Hannelius wrote: > > I noticed that openssh-1.2.2 doesn't build correctly on my slackware-7.0 > (glibc-2.1.2) and with md5-passwords. One have to define > "HAVE_MD5_PASSWORDS" in acconfig.h by hand, even if I choose > --enable-md5-passwords when configuring. I find this to be a bug. All > configuration should be done from ./configure solely when building. That should be '--with-md5-passwords'. > Is there btw a good reason for --with-ipv4-default *not* being the > default? Because most IPv6 supporting platforms have a working getnameinfo. > Otherwise, thanks a lot for a free-licensed and fast ssh-suite!! Keep up > the good work. Thanks. Regards, Damien Miller -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From djm at mindrot.org Thu Feb 3 12:24:00 2000 From: djm at mindrot.org (Damien Miller) Date: Thu, 3 Feb 2000 12:24:00 +1100 (EST) Subject: bash: scp: command not found In-Reply-To: Message-ID: On Wed, 2 Feb 2000, Harald Hannelius wrote: > > How come I can't get scp to work properly. It just complains like this: > > scp foo host: > bash: scp: command not found > lost connection scp must be in the server's PATH. Damien -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From djm at mindrot.org Thu Feb 3 12:27:15 2000 From: djm at mindrot.org (Damien Miller) Date: Thu, 3 Feb 2000 12:27:15 +1100 (EST) Subject: problems with openssh-1.2.2 and pam_tacplus.so In-Reply-To: Message-ID: On Wed, 2 Feb 2000, Dominik Brettnacher wrote: > Hello, > > I have the following problem: I have installed openssh-1.2.2 on FreeBSD > 3.4-RELEASE. I intentionally did not took the FreeBSD port because it does > not support PAM. My aim is to make sshd authenticate against a TACACS+ > server using the pam_tacplus.so module shipped with FreeBSD. That works > perfectly with this line in my /etc/pam.conf: > > login auth sufficient pam_tacplus.so > > > Accordingly, I set up pam.conf like this to make sshd do the same: > > sshd auth required pam_tacplus.so Is this you full PAM file for sshd? It looks like there are account and session entries missing. > PAM rejected by account configuration: Permission denied What 'account' entries do you have for sshd? If there are none it may be defaulting to deny. Regards, Damien Miller -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From cb at v-wave.com Thu Feb 3 15:10:15 2000 From: cb at v-wave.com (Chris Bayly) Date: 02 Feb 2000 21:10:15 -0700 Subject: bash: scp: command not found In-Reply-To: Dominik Brettnacher's message of "Wed, 2 Feb 2000 21:00:58 +0100 (CET)" References: Message-ID: <50emavc4ew.fsf@cb.v-wave.com> >>>>> "Dominik" == Dominik Brettnacher writes: Dominik> On Wed, 2 Feb 2000, Harald at iki.fi wrote: >> How come I can't get scp to work properly. It just complains >> like this: >> >> scp foo host: bash: scp: command not found lost connection Dominik> Maybe you should check for the path on the remote Dominik> machine: it seems like the remote shell can't find scp in Dominik> its $PATH. Or the "more SSH" way would be to put PATH= in ~/.ssh/environment on the machine being scp'ed to. -- Email: cb at v-wave.com | UNIX Support Email: Chris.Bayly at UAlberta.CA | 151 General Services Building | University of Alberta | Edmonton, Alberta Web: http://www.thegeeks.net/~cb/ | Canada T6G 2S7 From domi at saargate.de Thu Feb 3 17:12:57 2000 From: domi at saargate.de (Dominik Brettnacher) Date: Thu, 3 Feb 2000 07:12:57 +0100 (CET) Subject: problems with openssh-1.2.2 and pam_tacplus.so In-Reply-To: Message-ID: On Thu, 3 Feb 2000, djm at mindrot.org wrote: > >> PAM rejected by account configuration: Permission denied > What 'account' entries do you have for sshd? If there are none it > may be defaulting to deny. You were right, I did not set up any. Now my pam.conf looks like this: sshd auth required pam_tacplus.so sshd account required pam_unix.so try_first_pass sshd password required pam_unix.so try_first_pass sshd session required pam_unix.so try_first_pass When I use "pam_permit.so" as the session module, I can login successfully, but when trying pam_unix.so, I get these errors: Feb 3 07:05:01 sshd[17265]: unable to resolve symbol: pam_sm_chauthtok Feb 3 07:05:01 sshd[17265]: unable to resolve symbol: pam_sm_open_session Feb 3 07:05:01 sshd[17265]: unable to resolve symbol: pam_sm_close_session I already linked libcrypt.so to sshd because I got error messages without. But what is missing here? -- Dominik - http://www.saargate.de/~domi/ From markus.friedl at informatik.uni-erlangen.de Thu Feb 3 18:43:40 2000 From: markus.friedl at informatik.uni-erlangen.de (Markus Friedl) Date: Thu, 3 Feb 2000 08:43:40 +0100 Subject: logging RSA key IDs In-Reply-To: <200002022358.PAA03224@homer.ka9q.ampr.org>; from karn@ka9q.ampr.org on Wed, Feb 02, 2000 at 03:58:54PM -0800 References: <200002022358.PAA03224@homer.ka9q.ampr.org> Message-ID: <20000203084340.A13931@folly.informatik.uni-erlangen.de> On Wed, Feb 02, 2000 at 03:58:54PM -0800, Phil Karn wrote: > Thanks. The patch works as intended, though I have no tool to map > those key fingerprints back into the actual keys listed in > .ssh/authorized_keys... % ssh-keygen -l -f FILE works for files with one key only, e.g. identity.pub. i'am happy to accept patches that make this work for authorized_keys and known_hosts. From djm at mindrot.org Thu Feb 3 20:39:25 2000 From: djm at mindrot.org (Damien Miller) Date: Thu, 3 Feb 2000 20:39:25 +1100 (EST) Subject: SOCKS support Message-ID: Just a warning and a call to action: Theo de Raadt has convinced me to remove SOCKS support from our port of OpenSSH. His argument is that it can be easily and generically implemented as a ProxyCommand. This fits with my desire to keep our divergences from the OpenBSD codebase to a minimum. This looks like a few hours work (for someone more familiar the SOCKS API that I). It is basically a program which connects to a commandline specified host and passes data to/from the remote host to/from stdio. "man ssh" for the details on ProxyCommands. I am therefore asking for a volunteer to implement this so I can include in the next release of OpenSSH. Any takers? Regards, Damien Miller -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From vorlon at netexpress.net Fri Feb 4 03:39:22 2000 From: vorlon at netexpress.net (Steve Langasek) Date: Thu, 3 Feb 2000 10:39:22 -0600 (CST) Subject: problems with openssh-1.2.2 and pam_tacplus.so In-Reply-To: Message-ID: On Thu, 3 Feb 2000, Dominik Brettnacher wrote: > You were right, I did not set up any. Now my pam.conf looks like this: > sshd auth required pam_tacplus.so > sshd account required pam_unix.so try_first_pass > sshd password required pam_unix.so try_first_pass > sshd session required pam_unix.so try_first_pass > When I use "pam_permit.so" as the session module, I can login > successfully, but when trying pam_unix.so, I get these errors: > Feb 3 07:05:01 sshd[17265]: unable to resolve symbol: pam_sm_chauthtok > Feb 3 07:05:01 sshd[17265]: unable to resolve symbol: pam_sm_open_session > Feb 3 07:05:01 sshd[17265]: unable to resolve symbol: pam_sm_close_session This seems to imply that the pam_unix.so module you're using is not compiled to function as a password or session module. I really have no idea why this is. It may be a problem specific to the FreeBSD port? One thing you might try is to change the lines to read: sshd auth required pam_tacplus.so sshd account required pam_unix_account.so sshd password required pam_unix_passwd.so try_first_pass sshd session required pam_unix_session.so If pam_unix is available as individual modules on your system. Otherwise, pam_unix's session support is largely a no-op, and password changing isn't crucial to sshd's proper functioning, so if all else fails you could configure it as sshd auth required pam_tacplus.so sshd account required pam_unix_account.so sshd password required pam_permit.so sshd session required pam_permit.so HTH, Steve Langasek postmodern programmer From logix at foobar.franken.de Fri Feb 4 09:38:01 2000 From: logix at foobar.franken.de (Harold Gutch) Date: Thu, 3 Feb 2000 23:38:01 +0100 Subject: logging RSA key IDs In-Reply-To: <200002012157.NAA29530@homer.ka9q.ampr.org>; from Phil Karn on Tue, Feb 01, 2000 at 01:57:05PM -0800 References: <200002012157.NAA29530@homer.ka9q.ampr.org> Message-ID: <20000203233801.C17428@foobar.franken.de> On Tue, Feb 01, 2000 at 01:57:05PM -0800, Phil Karn wrote: > Hi. To compartmentalize things a bit (e.g., to help limit the damage > should one of my machines be hacked and my private RSA keys stolen) I > use different RSA key pairs on my different client machines. > > So it occurs to me that it would be nice if ssh could log which key > was used when logging in to a particular account that has more than > one entry in .ssh/authorized_keys. Right now it simply says "Accepted > rsa for karn from " without saying which key was used. > > You obviously don't want to log the whole public key, just the comment > field from the appropriate line in .ssh/authorized_keys would do. Perhaps I'm overseeing the obvious - but why not? The only thing that gets logged, is the _public_ key, the one the server knows anyway already, the one in the user's $HOME/.ssh/identity.pub file. If the machine is compromised, this public key is compromised as well. If the machine isn't compromised, the only one who will be able to see this key, is root (you do set the correct permissions on your logfiles, don't you?); but root is always able to simply peek into the users' identity.pub files anway. All in all I don't see how logging the complete public key that was used leaks any information anywhere, neither do I see privacy issues. One might argue that the logfile will grow significantly larger, but frankly I hardly believe that they would grow as much as they need to give you problems - YMMV (and one could always add a configurable limit - like limit it to the first 64 chars etc.) bye, Harold -- Someone should do a study to find out how many human life spans have been lost waiting for NT to reboot. Ken Deboy on Dec 24 1999 in comp.unix.bsd.freebsd.misc From drankin at bohemians.lexington.ky.us Fri Feb 4 02:47:57 2000 From: drankin at bohemians.lexington.ky.us (David Rankin) Date: Thu, 3 Feb 2000 10:47:57 -0500 Subject: SOCKS support In-Reply-To: ; from Damien Miller on Thu, Feb 03, 2000 at 08:39:25PM +1100 References: Message-ID: <20000203104756.A343@rumpole.bohemians.lexington.ky.us> On Thu, Feb 03, 2000 at 08:39:25PM +1100, Damien Miller wrote: > Just a warning and a call to action: > Theo de Raadt has convinced me to remove SOCKS support from our port > of OpenSSH. I strongly disagree with this position WRT SOCKS and Dante support. There are some distinct advantages gained for keeping socks support in the code base. > His argument is that it can be easily and generically implemented as > a ProxyCommand. This fits with my desire to keep our divergences from > the OpenBSD codebase to a minimum. Dante allows sockification of incoming connections from the SOCKS server to the sshd. There's no easy way to accomplish this using a ProxyCommand-like program. > This looks like a few hours work (for someone more familiar the SOCKS > API that I). It is basically a program which connects to a commandline > specified host and passes data to/from the remote host to/from stdio. > "man ssh" for the details on ProxyCommands. This program is actually trivial to write. Take any port redirector and hack on it. My problem is that you've changed * one extra library call per socket action to * put data in pipe/socket queue * force schedule switch to "pipe" program * pull data across system/user barrier (pipe read) * push data back across system/user barrier (write to socket) Reads also add the same overhead. Basically, you've traded one extra library call for a program that has to sit there and jump into the kernel an extra two times per read/write. On these modern machines, that's a trivial add, but on the older junk I can afford (and I know others love), it adds up. Considering that Socks and Dante both are a less than 40 lines diff to one file, I don't think it'd be a big maintenance impact. IMHO, keeping the library support compiled in is a LOT more elegant than a bolt-on program. Thanks, David -- David W. Rankin, Jr. Husband, Father, and UNIX Sysadmin. Email: drankin at bohemians.lexington.ky.us Address/Phone Number: Ask me. "It's too bad she won't live! But then again, who does?" -- Gaff, BR From markus.friedl at informatik.uni-erlangen.de Fri Feb 4 01:43:40 2000 From: markus.friedl at informatik.uni-erlangen.de (Markus Friedl) Date: Thu, 3 Feb 2000 15:43:40 +0100 Subject: logging RSA key IDs In-Reply-To: <20000203084340.A13931@folly.informatik.uni-erlangen.de>; from markus.friedl@informatik.uni-erlangen.de on Thu, Feb 03, 2000 at 08:43:40AM +0100 References: <200002022358.PAA03224@homer.ka9q.ampr.org> <20000203084340.A13931@folly.informatik.uni-erlangen.de> Message-ID: <20000203154340.A8158@folly.informatik.uni-erlangen.de> On Thu, Feb 03, 2000 at 08:43:40AM +0100, Markus Friedl wrote: > On Wed, Feb 02, 2000 at 03:58:54PM -0800, Phil Karn wrote: > > Thanks. The patch works as intended, though I have no tool to map > > those key fingerprints back into the actual keys listed in > > .ssh/authorized_keys... > > % ssh-keygen -l -f FILE > works for files with one key only, e.g. identity.pub. > i'am happy to accept patches that make this work > for authorized_keys and known_hosts. try this. Index: ssh-keygen.c =================================================================== RCS file: /home/markus/cvs/ssh/ssh-keygen.c,v retrieving revision 1.14 diff -u -r1.14 ssh-keygen.c --- ssh-keygen.c 1999/11/24 19:53:52 1.14 +++ ssh-keygen.c 2000/02/03 14:42:37 @@ -76,9 +76,10 @@ void do_fingerprint(struct passwd *pw) { - char *comment; + char *comment = NULL; RSA *public_key; struct stat st; + int invalid = 0; if (!have_identity) ask_filename(pw, "Enter file in which the key is"); @@ -87,37 +88,60 @@ exit(1); } public_key = RSA_new(); - if (!load_public_key(identity_file, public_key, &comment)) { - char *cp, line[1024]; + if (load_public_key(identity_file, public_key, &comment)) { + printf("%d %s %s\n", BN_num_bits(public_key->n), + fingerprint(public_key->e, public_key->n), + comment); + RSA_free(public_key); + } else { BIGNUM *e, *n; - int dummy, invalid = 0; - FILE *f = fopen(identity_file, "r"); - n = BN_new(); - e = BN_new(); - if (f && fgets(line, sizeof(line), f)) { - cp = line; - line[strlen(line) - 1] = '\0'; - if (auth_rsa_read_key(&cp, &dummy, e, n)) { - public_key->e = e; - public_key->n = n; - comment = xstrdup(cp ? cp : "no comment"); - } else { - invalid = 1; + FILE *f; + char *cp, line[1024]; + int dummy; + + invalid = 1; + f = fopen(identity_file, "r"); + if (f != NULL) { + n = BN_new(); + e = BN_new(); + while (fgets(line, sizeof(line), f)) { + line[strlen(line) - 1] = '\0'; + + /* Skip leading whitespace, empty and comment lines. */ + for (cp = line; *cp == ' ' || *cp == '\t'; cp++) + ; + if (!*cp || *cp == '\n' || *cp == '#') + continue ; + if (*cp < '0' || *cp > '9') { + int quoted = 0; + comment = cp; + for (; *cp && (quoted || (*cp != ' ' && *cp != '\t')); cp++) { + if (*cp == '\\' && cp[1] == '"') + cp++; /* Skip both */ + else if (*cp == '"') + quoted = !quoted; + } + if (*cp == '\0') + continue; + *cp++ = '\0'; + } + if (auth_rsa_read_key(&cp, &dummy, e, n)) { + invalid = 0; + comment = *cp ? cp : comment; + printf("%d %s %s\n", BN_num_bits(n), + fingerprint(e, n), + comment ? comment : "no comment"); + } } - } else { - invalid = 1; - } - if (invalid) { - printf("%s is not a valid key file.\n", identity_file); BN_free(e); BN_free(n); - exit(1); + fclose(f); } } - printf("%d %s %s\n", BN_num_bits(public_key->n), - fingerprint(public_key->e, public_key->n), - comment); - RSA_free(public_key); + if (invalid) { + printf("%s is not a valid key file.\n", identity_file); + exit(1); + } exit(0); } @@ -310,7 +334,7 @@ usage(void) { printf("ssh-keygen version %s\n", SSH_VERSION); - printf("Usage: %s [-b bits] [-p] [-c] [-f file] [-P pass] [-N new-pass] [-C comment]\n", __progname); + printf("Usage: %s [-b bits] [-p] [-c] [-l] [-f file] [-P pass] [-N new-pass] [-C comment]\n", __progname); exit(1); } From andre.lucas at dial.pipex.com Fri Feb 4 10:14:08 2000 From: andre.lucas at dial.pipex.com (Andre Lucas) Date: Thu, 3 Feb 2000 23:14:08 +0000 Subject: EGD requirement a show stopper for me In-Reply-To: ; from djm@mindrot.org on Wed, Feb 02, 2000 at 07:23:49PM +1100 References: <20000201155539.A13302@lucent.com> Message-ID: <20000203231408.A689@internal.domain> On Wed, Feb 02, 2000 at 07:23:49PM +1100, Damien Miller wrote: 8< > It would be great if someone could resurrect some of the entropy > gathering hooks from ssh-1.2.16 and combine them with the pool > functions of a Yarrow modified to use OpenSSL's crypto routines. > I've got Yarrow0.8.71 ported over from Win32, and I'm just moving the hooks. Before I do that, can you confirm that we can use stuff from ssh version 1.2.16? The openssh ssh manpage talks about 1.2.12. I can't find a copy 1.2.12 to compare. I only bring it up because the distributions on the all the offical ssh mirrors start at 1.2.13, which makes me think 1.2.12 has some special significance. >From what I've seen, it shouldn't be too much work to port the crypto to openssl. Yarrow-0.8.71 only seems to use SHA-1 (no three key triple-DES as in the paper.) Ta, -Andre -- Andre Lucas http://dspace.dial.pipex.com/andre.lucas/ From karn at ka9q.ampr.org Fri Feb 4 10:50:55 2000 From: karn at ka9q.ampr.org (Phil Karn) Date: Thu, 3 Feb 2000 15:50:55 -0800 Subject: logging RSA key IDs In-Reply-To: <20000203233801.C17428@foobar.franken.de> (message from Harold Gutch on Thu, 3 Feb 2000 23:38:01 +0100) References: <200002012157.NAA29530@homer.ka9q.ampr.org> <20000203233801.C17428@foobar.franken.de> Message-ID: <200002032350.PAA10319@homer.ka9q.ampr.org> >One might argue that the logfile will grow significantly larger, That, and not any concern about keeping public keys private, was my concern. But it now occurs to me that on most systems, log files are routinely compressed by daemons fired off from cron. Although the public keys are themselves random and essentially uncompressible, chances are they will keep recurring in the log file, making them compress very nicely with gzip. So I now suggest that the daemon just log the full public key used. Hopefully this won't break any message length limits in syslog. Phil From jmknoble at pobox.com Fri Feb 4 11:09:36 2000 From: jmknoble at pobox.com (Jim Knoble) Date: Thu, 3 Feb 2000 19:09:36 -0500 Subject: logging RSA key IDs In-Reply-To: <200002032350.PAA10319@homer.ka9q.ampr.org>; from Phil Karn on Thu, Feb 03, 2000 at 03:50:55PM -0800 References: <200002012157.NAA29530@homer.ka9q.ampr.org> <20000203233801.C17428@foobar.franken.de> <200002032350.PAA10319@homer.ka9q.ampr.org> Message-ID: <20000203190936.F2599@quipu.earth> Logging the fingerprint would be more human-readable, however. -- jim knoble jmknoble at pobox.com P? 2000-Feb-03 klokka 15:50:55 -0800 skrivet Phil Karn: : >One might argue that the logfile will grow significantly larger, : : That, and not any concern about keeping public keys private, was my : concern. But it now occurs to me that on most systems, log files are : routinely compressed by daemons fired off from cron. Although the : public keys are themselves random and essentially uncompressible, : chances are they will keep recurring in the log file, making them : compress very nicely with gzip. : : So I now suggest that the daemon just log the full public key : used. Hopefully this won't break any message length limits in syslog. From djm at mindrot.org Fri Feb 4 11:44:07 2000 From: djm at mindrot.org (Damien Miller) Date: Fri, 4 Feb 2000 11:44:07 +1100 (EST) Subject: EGD requirement a show stopper for me In-Reply-To: <20000203231408.A689@internal.domain> Message-ID: On Thu, 3 Feb 2000, Andre Lucas wrote: > On Wed, Feb 02, 2000 at 07:23:49PM +1100, Damien Miller wrote: > > 8< > > It would be great if someone could resurrect some of the entropy > > gathering hooks from ssh-1.2.16 and combine them with the pool > > functions of a Yarrow modified to use OpenSSL's crypto routines. > > > > I've got Yarrow0.8.71 ported over from Win32, and I'm just moving the > hooks. Before I do that, can you confirm that we can use stuff from ssh > version 1.2.16? The openssh ssh manpage talks about 1.2.12. I can't find > a copy 1.2.12 to compare. Wow - well done! I think that it was ssh-1.2.16 that was used as the basis for OpenSSH, but I am not 100% In any case you can retrieve what the OpenBSD team started with: cvs -z9 -d ":pserver:anoncvs at anoncvs1.usa.openbsd.org:/cvs" co -r 1.1 -d ssh-import src/usr.bin/ssh This includes the random hooks. > >From what I've seen, it shouldn't be too much work to port the crypto to > openssl. Yarrow-0.8.71 only seems to use SHA-1 (no three key triple-DES > as in the paper.) Excellent. Yell if you want a hand. Thanks again, Damien -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From markus.friedl at informatik.uni-erlangen.de Fri Feb 4 18:41:24 2000 From: markus.friedl at informatik.uni-erlangen.de (Markus Friedl) Date: Fri, 4 Feb 2000 08:41:24 +0100 Subject: EGD requirement a show stopper for me In-Reply-To: ; from djm@mindrot.org on Fri, Feb 04, 2000 at 11:44:07AM +1100 References: <20000203231408.A689@internal.domain> Message-ID: <20000204084124.B3444@folly.informatik.uni-erlangen.de> On Fri, Feb 04, 2000 at 11:44:07AM +1100, Damien Miller wrote: > > I've got Yarrow0.8.71 ported over from Win32, and I'm just moving the > > hooks. Before I do that, can you confirm that we can use stuff from ssh > > version 1.2.16? The openssh ssh manpage talks about 1.2.12. I can't find > > a copy 1.2.12 to compare. > > Wow - well done! I think that it was ssh-1.2.16 that was used as the > basis for OpenSSH, but I am not 100% ftp://ftp.cert.dfn.de/pub/tools/net/ssh/snapshots/ssh-1.2.12.tar.gz is the base for OpenSSH. the commit message has a typo, the webpage is correct. From Marc.Haber-lists at gmx.de Fri Feb 4 21:11:25 2000 From: Marc.Haber-lists at gmx.de (Marc Haber) Date: Fri, 04 Feb 2000 10:11:25 GMT Subject: problems logging in from 1.2.2 client to 1.2.1pre24 server In-Reply-To: References: Message-ID: On Wed, 2 Feb 2000 20:31:32 +1100 (EST), you wrote: >Phil Hands had Debian packages that were working OK - perhaps you >could nab the PAM config file from one of those. He didn't update these in a long time :-( 1.2.1pre24 seem to be the latest... Greetings Marc -- -------------------------------------- !! No courtesy copies, please !! ----- Marc Haber | " Questions are the | Mailadresse im Header Karlsruhe, Germany | Beginning of Wisdom " | Fon: *49 721 966 32 15 Nordisch by Nature | Lt. Worf, TNG "Rightful Heir" | Fax: *49 721 966 31 29 From Marc.Haber-lists at gmx.de Fri Feb 4 21:14:05 2000 From: Marc.Haber-lists at gmx.de (Marc Haber) Date: Fri, 04 Feb 2000 10:14:05 GMT Subject: bash: scp: command not found In-Reply-To: References: Message-ID: On Wed, 2 Feb 2000 13:15:45 -0700 (MST), you wrote: >1. Make each user add /usr/local/bin (or wherever scp is) to their path in >their ~/.bashrc That doesn't suffice. >3. Add an option to ssh to pass a path to the shell (i've seen this in >commercial ssh-1.2.27 as --with-path). And then recompile it. For openssh, this is --with-default-path and works fine. This is the way to go. Greetings Marc -- -------------------------------------- !! No courtesy copies, please !! ----- Marc Haber | " Questions are the | Mailadresse im Header Karlsruhe, Germany | Beginning of Wisdom " | Fon: *49 721 966 32 15 Nordisch by Nature | Lt. Worf, TNG "Rightful Heir" | Fax: *49 721 966 31 29 From marc.fournier at acadiau.ca Sat Feb 5 00:28:58 2000 From: marc.fournier at acadiau.ca (Marc G. Fournier) Date: Fri, 4 Feb 2000 09:28:58 -0400 (AST) Subject: bash: scp: command not found In-Reply-To: Message-ID: On Fri, 4 Feb 2000, Marc Haber wrote: > On Wed, 2 Feb 2000 13:15:45 -0700 (MST), you wrote: > >1. Make each user add /usr/local/bin (or wherever scp is) to their path in > >their ~/.bashrc > > That doesn't suffice. > > >3. Add an option to ssh to pass a path to the shell (i've seen this in > >commercial ssh-1.2.27 as --with-path). And then recompile it. > > For openssh, this is --with-default-path and works fine. This is the > way to go. I personally feel that if you set --prefix=/usr/local to install, /usr/local/bin should be automatically added to the default path ... Marc G. Fournier marc.fournier at acadiau.ca Senior Systems Administrator Acadia University "These are my opinions, which are not necessarily shared by my employer" From partain at mekb2.sps.mot.com Sat Feb 5 02:15:39 2000 From: partain at mekb2.sps.mot.com (Will Partain) Date: Fri, 04 Feb 2000 15:15:39 +0000 Subject: problems compiling 1.2.2 on HP-UX 10.20 (gcc) Message-ID: <200002041515.PAA21301@mekb2.sps.mot.com> The problem seems to be that if you #include without suitable -DPOSIX_SOMETHING magic, you get no struct utmpx (all that stuff is wrapped w/ "#ifdef _INCLUDE_XOPEN_SOURCE_EXTENDED"). I'm not sure how you all are handling such portability issues. Thx, Will ================== I configured with # ./configure --prefix=/.=our-deploy/openssh-1.2.2 --without-shadow --with-rsh=/usr/bin/remsh --with-egd-pool=/tmp/EGD-pool Build with... % ourmake --platform=hppa1.1-hp-hpux10.20::ekbdc002 + [ -d /item/our-builds/pkgs/openssh-1.2.2 ] + [ -d /.=blob/our-install-hppa1.1-hp-hpux10.20/openssh-1.2.2 ] + /mot/bin/symlink-if-needed /.=blob/our-install-hppa1.1-hp-hpux10.20/openssh-1.2.2 /.=our-deploy/openssh-1.2.2 === hppa1.1-hp-hpux10.20::ekbdc002 ============================== ourmake patch: patching already done ourmake: skipping linktree step... ourmake: skipping configure step... ourmake: hppa1.1-hp-hpux10.20/Makefile doesn't mention `depend'... skipping /mot/bin/ersh ekbdc002 'PATH=/usr/local/bin:/mot/swdevp/bin:/mot/bin:$PATH:/usr/bin/X11:/usr/ccs/bin:/bin:/usr/bin:/usr/local/sbin:/mot/sbin:/mot/sysadmin/bin:/mot/sysadmin/sbin:/usr/sbin:/etc; export PATH; umask 002; prefix=/.=our-deploy/openssh-1.2.2; export prefix; our_package_id="openssh-1.2.2"; export our_package_id; OUR_SITE="ekbdt0"; export OUR_SITE; OUR_NSROOT="/mot"; export OUR_NSROOT; OUR_SPECIAL_ROOT="/usr/local"; export OUR_SPECIAL_ROOT; OUR_INCDIR="/mot/share/our-unix-rollout/common/perl"; export OUR_INCDIR; cd /item/our-builds/pkgs/openssh-1.2.2/hppa1.1-hp-hpux10.20 && /mot/bin/make all ' /mot/swdevp/bin/gcc -O2 -fstrict-aliasing -march=1.1 -mschedule=7200 -I/mot/swdevp/include -I/mot/include -L/mot/swdevp/lib -L/mot/lib -Wall -I/mot/swdevp/include -D_HPUX_SOURCE -DETCDIR=\"/.=our-deploy/openssh-1.2.2/etc\" -DSSH_PROGRAM=\"/.=our-deploy/openssh-1.2.2/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/.=our-deploy/openssh-1.2.2/libexec/ssh/ssh-askpass\" -DHAVE_CONFIG_H -c login.c -o login.o login.c:236: parse error before `&' login.c:236: warning: type defaults to `int' in declaration of `login' login.c:236: conflicting types for `login' bsd-login.h:12: previous declaration of `login' login.c:236: warning: data definition has no type or storage class make: *** [login.o] Error 1 ourmake failed From stheinri at hamilton1.physik.uni-konstanz.de Sat Feb 5 07:40:27 2000 From: stheinri at hamilton1.physik.uni-konstanz.de (Stefan Heinrichs) Date: Fri, 4 Feb 2000 21:40:27 +0100 Subject: Patch that allows equal sign in options Message-ID: <20000204214027.A10328@curie.physik.uni-konstanz.de> Hi, Here is a patch for release 1.2.2 that allows the use of '=' instead of whitespace when specifying options. For options on the commandline, it can be useful to be able to avoid whitespace in some situations. best regards and thanks for the patch regarding segfaulting with PAM, Stefan ------------------------------------------------------------------- Email: Stefan.Heinrichs at uni-konstanz.de Address: Fakulaet fuer Physik, Universitaet Konstanz, Universitaetsstr.10, 78457 Konstanz, Germany Phone: +49 7531 88 3814 ============================================================================= --- readconf.c.orig Mon Dec 6 01:47:29 1999 +++ readconf.c Thu Feb 3 22:37:54 2000 @@ -156,6 +156,7 @@ /* Characters considered whitespace in strtok calls. */ #define WHITESPACE " \t\r\n" +#define WHITESPACE_EQ " \t\r\n=" /* @@ -237,7 +238,7 @@ return 0; /* Get the keyword. (Each line is supposed to begin with a keyword). */ - cp = strtok(cp, WHITESPACE); + cp = strtok(cp, WHITESPACE_EQ); opcode = parse_token(cp, filename, linenum); switch (opcode) { @@ -248,7 +249,7 @@ case oForwardAgent: intptr = &options->forward_agent; parse_flag: - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing yes/no argument.", filename, linenum); value = 0; /* To avoid compiler warning... */ @@ -330,7 +331,7 @@ case oStrictHostKeyChecking: intptr = &options->strict_host_key_checking; - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing yes/no argument.", filename, linenum); @@ -364,7 +365,7 @@ goto parse_int; case oIdentityFile: - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing argument.", filename, linenum); if (*activep) { @@ -378,7 +379,7 @@ case oUser: charptr = &options->user; parse_string: - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing argument.", filename, linenum); if (*activep && *charptr == NULL) @@ -400,7 +401,7 @@ case oProxyCommand: charptr = &options->proxy_command; string = xstrdup(""); - while ((cp = strtok(NULL, WHITESPACE)) != NULL) { + while ((cp = strtok(NULL, WHITESPACE_EQ)) != NULL) { string = xrealloc(string, strlen(string) + strlen(cp) + 2); strcat(string, " "); strcat(string, cp); @@ -414,7 +415,7 @@ case oPort: intptr = &options->port; parse_int: - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing argument.", filename, linenum); if (cp[0] < '0' || cp[0] > '9') @@ -434,7 +435,7 @@ case oCipher: intptr = &options->cipher; - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); value = cipher_number(cp); if (value == -1) fatal("%.200s line %d: Bad cipher '%s'.", @@ -445,7 +446,7 @@ case oLogLevel: intptr = (int *) &options->log_level; - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); value = log_level_number(cp); if (value == (LogLevel) - 1) fatal("%.200s line %d: unsupported log level '%s'\n", @@ -455,14 +456,14 @@ break; case oRemoteForward: - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing argument.", filename, linenum); if (cp[0] < '0' || cp[0] > '9') fatal("%.200s line %d: Badly formatted port number.", filename, linenum); fwd_port = atoi(cp); - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing second argument.", filename, linenum); @@ -474,14 +475,14 @@ break; case oLocalForward: - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing argument.", filename, linenum); if (cp[0] < '0' || cp[0] > '9') fatal("%.200s line %d: Badly formatted port number.", filename, linenum); fwd_port = atoi(cp); - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing second argument.", filename, linenum); @@ -494,7 +495,7 @@ case oHost: *activep = 0; - while ((cp = strtok(NULL, WHITESPACE)) != NULL) + while ((cp = strtok(NULL, WHITESPACE_EQ)) != NULL) if (match_pattern(host, cp)) { debug("Applying options for %.100s", cp); *activep = 1; @@ -505,7 +506,7 @@ case oEscapeChar: intptr = &options->escape_char; - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing argument.", filename, linenum); if (cp[0] == '^' && cp[2] == 0 && --- readconf.c.sv Mon Dec 6 01:47:29 1999 +++ readconf.c Thu Feb 3 22:37:54 2000 @@ -156,6 +156,7 @@ /* Characters considered whitespace in strtok calls. */ #define WHITESPACE " \t\r\n" +#define WHITESPACE_EQ " \t\r\n=" /* @@ -237,7 +238,7 @@ return 0; /* Get the keyword. (Each line is supposed to begin with a keyword). */ - cp = strtok(cp, WHITESPACE); + cp = strtok(cp, WHITESPACE_EQ); opcode = parse_token(cp, filename, linenum); switch (opcode) { @@ -248,7 +249,7 @@ case oForwardAgent: intptr = &options->forward_agent; parse_flag: - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing yes/no argument.", filename, linenum); value = 0; /* To avoid compiler warning... */ @@ -330,7 +331,7 @@ case oStrictHostKeyChecking: intptr = &options->strict_host_key_checking; - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing yes/no argument.", filename, linenum); @@ -364,7 +365,7 @@ goto parse_int; case oIdentityFile: - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing argument.", filename, linenum); if (*activep) { @@ -378,7 +379,7 @@ case oUser: charptr = &options->user; parse_string: - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing argument.", filename, linenum); if (*activep && *charptr == NULL) @@ -400,7 +401,7 @@ case oProxyCommand: charptr = &options->proxy_command; string = xstrdup(""); - while ((cp = strtok(NULL, WHITESPACE)) != NULL) { + while ((cp = strtok(NULL, WHITESPACE_EQ)) != NULL) { string = xrealloc(string, strlen(string) + strlen(cp) + 2); strcat(string, " "); strcat(string, cp); @@ -414,7 +415,7 @@ case oPort: intptr = &options->port; parse_int: - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing argument.", filename, linenum); if (cp[0] < '0' || cp[0] > '9') @@ -434,7 +435,7 @@ case oCipher: intptr = &options->cipher; - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); value = cipher_number(cp); if (value == -1) fatal("%.200s line %d: Bad cipher '%s'.", @@ -445,7 +446,7 @@ case oLogLevel: intptr = (int *) &options->log_level; - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); value = log_level_number(cp); if (value == (LogLevel) - 1) fatal("%.200s line %d: unsupported log level '%s'\n", @@ -455,14 +456,14 @@ break; case oRemoteForward: - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing argument.", filename, linenum); if (cp[0] < '0' || cp[0] > '9') fatal("%.200s line %d: Badly formatted port number.", filename, linenum); fwd_port = atoi(cp); - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing second argument.", filename, linenum); @@ -474,14 +475,14 @@ break; case oLocalForward: - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing argument.", filename, linenum); if (cp[0] < '0' || cp[0] > '9') fatal("%.200s line %d: Badly formatted port number.", filename, linenum); fwd_port = atoi(cp); - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing second argument.", filename, linenum); @@ -494,7 +495,7 @@ case oHost: *activep = 0; - while ((cp = strtok(NULL, WHITESPACE)) != NULL) + while ((cp = strtok(NULL, WHITESPACE_EQ)) != NULL) if (match_pattern(host, cp)) { debug("Applying options for %.100s", cp); *activep = 1; @@ -505,7 +506,7 @@ case oEscapeChar: intptr = &options->escape_char; - cp = strtok(NULL, WHITESPACE); + cp = strtok(NULL, WHITESPACE_EQ); if (!cp) fatal("%.200s line %d: Missing argument.", filename, linenum); if (cp[0] == '^' && cp[2] == 0 && From coolio at k-r4d.com Sun Feb 6 07:12:54 2000 From: coolio at k-r4d.com (Coolio) Date: Sat, 5 Feb 2000 13:12:54 -0700 (MST) Subject: Slackware /etc/limits patch Message-ID: Requiring user resource limits on my Slackware 7 server, I made this patch. The code is taken from shadow-19990607 and integrated with openssh 1.2.2 and works well. The patch needs work, I don't know much about autoconf and I couldn't figure out how to get it to add sys/resource.h checks to the configure script. - Dennis Moran -------------- next part -------------- A non-text attachment was scrubbed... Name: openssh-1.2.2+limits.patch.tgz Type: application/octet-stream Size: 7555 bytes Desc: Url : http://lists.mindrot.org/pipermail/openssh-unix-dev/attachments/20000205/545e5331/attachment.obj From johnh at aproposretail.com Sun Feb 6 07:22:22 2000 From: johnh at aproposretail.com (John Hardin) Date: Sat, 05 Feb 2000 12:22:22 -0800 Subject: Forwarded ports: delay after last close before exiting Message-ID: <389C867E.BE84837C@aproposretail.com> I use fetchmail+ssh (soon to be openssh) to retrieve mail for several accounts. The setup for this forwards a couple of local ports to the mail server POP and IMAP ports, then sleeps. Nothing fancy. If the first poll has a lot of messages, enough that it extends beyond the end of the sleep, then when it completes ssh sees no activity on the forwarded ports and exits. This prevents subsequent polls in that run from connecting to the mail server and retrieving mail. Rather than having each poll build its own tunnel, I'd like to add some code to openssh be able to specify "If the activity on forwarded ports ends, wait N seconds before exiting" - on the assumption that it would wait long enough for the next poll in the run to start and open a forwarded port. First off, can anybody say "that won't work"? I haven't dug too deeply into the code yet so I don't know if there are more issues than simply adding a timer and re-check to the "wait for forwarded ports to complete" loop. Second, I want to specify the wait duration on the command line. Since ssh is supposed to be a drop-in replacement for rsh et. al., the selection of a letter for this is not unconstrained. Would adding the option "-W delay" break anything besides command-line compatibility with regular ssh? Thanks for your input. -- John Hardin Internal Systems Administrator Apropos Retail Management Systems, Inc. From andre.lucas at dial.pipex.com Sat Feb 5 10:32:47 2000 From: andre.lucas at dial.pipex.com (Andre Lucas) Date: Fri, 4 Feb 2000 23:32:47 +0000 Subject: problems compiling 1.2.2 on HP-UX 10.20 (gcc) In-Reply-To: <200002041515.PAA21301@mekb2.sps.mot.com>; from partain@mekb2.sps.mot.com on Fri, Feb 04, 2000 at 03:15:39PM +0000 References: <200002041515.PAA21301@mekb2.sps.mot.com> Message-ID: <20000204233247.A693@internal.domain> On Fri, Feb 04, 2000 at 03:15:39PM +0000, Will Partain wrote: > The problem seems to be that if you #include > without suitable -DPOSIX_SOMETHING magic, you get no struct > utmpx (all that stuff is wrapped w/ "#ifdef > _INCLUDE_XOPEN_SOURCE_EXTENDED"). > > I'm not sure how you all are handling such portability > issues. Thx, > Send 'em in! In this case though, it isn't a portability issue. It's not a problem with utmpx.h, it's a typo in login.c. A patch is attached. The login stuff is really system dependent, hence the profusion of '#ifdef's. Efforts are under way to clean it up. 8< > login.c:236: conflicting types for `login' > bsd-login.h:12: previous declaration of `login' > login.c:236: warning: data definition has no type or storage class > make: *** [login.o] Error 1 > ourmake failed Damien, is it time for a FAQ yet ;-) Ta, -Andre -- Andre Lucas http://dspace.dial.pipex.com/andre.lucas/ --- openssh-1.2.2/login.c Wed Jan 26 00:04:48 2000 +++ openssh-1.2.2.new/login.c Fri Jan 28 14:59:56 2000 @@ -210,7 +210,7 @@ # endif /* HAVE_SYSLEN_IN_UTMPX */ # endif #if defined(HAVE_ADDR_IN_UTMPX) - if (addr) + if (addr) { switch (addr->sa_family) { case AF_INET: { struct sockaddr_in *in = (struct sockaddr_in*)addr; From mfisk at lanl.gov Tue Feb 8 10:02:46 2000 From: mfisk at lanl.gov (Mike Fisk) Date: Mon, 7 Feb 2000 23:02:46 +0000 (GMT) Subject: openssh (fwd) Message-ID: Some people on the OpenSSH list have expressed an interest in Kerberos version 5 support. Below is a (non-US) URL recently posted for a patch to OpenSSH to work with Heimdal, the international K5 implementation. I haven't checked to see if the patch would work with MIT or MIT-derived K5 libraries. -- Mike Fisk, RADIANT Team, Network Engineering Group, Los Alamos National Lab See http://home.lanl.gov/mfisk/ for contact information ---------- Forwarded message ---------- Date: Thu, 3 Feb 2000 15:33:34 +0100 (MET) From: Daniel Kouril Subject: openssh To: heimdal-discuss at sics.se X-Sender: kouril at aisa I made a patch supporting heimdal. http://www.fi.muni.cz/~kouril/openssh-1.2.1pre24.patch From trovero at email.unc.edu Tue Feb 8 19:21:45 2000 From: trovero at email.unc.edu (Michele A Trovero) Date: Tue, 08 Feb 2000 03:21:45 -0500 Subject: compile with KTH-KRB4 Message-ID: <389FD219.A807FEB9@email.unc.edu> Hello, Has anyone tried to compile Openssh with KTH-KRB4? I tried using: ./configure --prefix=/usr --sysconfdir=/etc/ssh \ --with-gnome-askpass --with-tcp-wrappers \ --with-ipv4-default \ --with-kerberos4=/usr/athena but it complains that it cannot find krb.h (which is in /usr/athena/include). I didn't find anything in the list archive. I am using Openssh 1.2.2, RH 6.1 and KTH-KRB4 1.0. Any help is appreciated, thank you. Michele From nicku at vtc.edu.hk Tue Feb 8 21:10:40 2000 From: nicku at vtc.edu.hk (Nick Urbanik) Date: Tue, 08 Feb 2000 18:10:40 +0800 Subject: Bug report and PATCH in ssh-agent in openssh 1.2.2 Message-ID: <389FEBA0.33B7CA2C@vtc.edu.hk> Dear folks, system: RH 6.1 Linux on a PIII software: installed binaries resulting from rpm --rebuild openssh-1.2.2-1.src.rpm, downloaded from http://the.wiretapped.net/security/cryptography/ssh/OpenSSH/files/openssh-1.2.2-1.src.rpm problem program: ssh-agent problem description: When execute ssh-agent startx -- -bpp 32 ssh-agent does not pass the -bpp 32 to startx. Why problem exists: getopt() reorders args by default, but we don't want the ssh-agent args to be interchanged with those of program ssh-agent is starting up. Solution: a very simple patch: -- cut here --------------------------------------------------------- --- openssh-1.2.2/ssh-agent.c~ Mon Jan 3 20:41:05 2000 +++ openssh-1.2.2/ssh-agent.c Tue Feb 8 14:42:11 2000 @@ -515,7 +515,7 @@ __progname); exit(1); } - while ((ch = getopt(ac, av, "cks")) != -1) { + while ((ch = getopt(ac, av, "+cks")) != -1) { switch (ch) { case 'c': if (s_flag) -- cut here --------------------------------------------------------- I have built an rpm with this patch, but don't know where to upload it. -- Nick Urbanik, Dept. of Electrical & Communications Engineering Hong Kong Institute of Vocational Education (Tsing Yi) email: nicku at vtc.edu.hk, nicku at iohk.com Tel: (852) 2436 8660, (825) 2436 8492 Fax: (852) 2436 8643 pgp ID: 7529555D fingerprint: 53 B6 6D 73 52 EE 1F EE EC F8 21 98 45 1C 23 7B From phil at hands.com Wed Feb 9 10:19:39 2000 From: phil at hands.com (Philip Hands) Date: 08 Feb 2000 23:19:39 +0000 Subject: problems logging in from 1.2.2 client to 1.2.1pre24 server In-Reply-To: (Marc Haber's message of "Fri, 04 Feb 2000 10:11:25 GMT") References: Message-ID: <873dr3th84.fsf@sheikh.hands.com> Marc Haber writes: > On Wed, 2 Feb 2000 20:31:32 +1100 (EST), you wrote: > >Phil Hands had Debian packages that were working OK - perhaps you > >could nab the PAM config file from one of those. > > He didn't update these in a long time :-( > > 1.2.1pre24 seem to be the latest... Sorry, been busy --- you can expect an upload tonight (probably, although I would have told you that a few days ago, and have been lying --- things have been a bit mad around here of late. Damn clients, who'd have 'em, eh? ;-). Cheers, Phil. From phil at hands.com Wed Feb 9 12:03:26 2000 From: phil at hands.com (Philip Hands) Date: 09 Feb 2000 01:03:26 +0000 Subject: [Colin Watson ] Bug#49902: [PATCH] Bug#49902: ssh and pam conspire to deny logins Message-ID: <87ln4vrxup.fsf@sheikh.hands.com> Hi, Here's a helpful patch from one of our (Debian's) users. I'd guess that the similar if/xfree a few lines above in the #if PAM section could do with the same treatment. Cheers, Phil. --[[message/rfc822]] Date: Sat, 29 Jan 2000 11:11:32 +0000 From: Colin Watson To: 49902 at bugs.debian.org [Bug was that when sshing one's password is denied, apparently by PAM.] Firstly, moving (or linking) /etc/pam.d/ssh to /etc/pam.d/sshd as suggested doesn't help me; I still get: [cjw44 at quicksilver ~]$ ssh riva cjw44 at cjw44.trin.cam.ac.uk's password: [fx: types in correct password] Connection closed by 131.111.193.196 This bug has an interesting interaction with identities. I only experience this bug when sshing from an account with an identity file in ~/.ssh/identity to an account which is not set up to recognize that identity. A temporary workaround is to specify an identity file which isn't, as follows: [cjw44 at quicksilver ~]$ ssh -i /dev/null riva cjw44 at cjw44.trin.cam.ac.uk's password: [fx: types in correct password] Last login: Sat Jan 29 09:14:17 2000 from quicksilver.trin.cam.ac.uk [...] Running sshd in debugging mode reveals that it segfaults after receiving my password, but only if it had previously attempted to authenticate me based on an identity file. MALLOC_CHECK_ was my friend! A patch (whose purpose should be obvious) follows: --- sshd.c.orig Sat Jan 29 11:00:50 2000 +++ sshd.c Sat Jan 29 11:01:29 2000 @@ -1414,8 +1414,10 @@ return; } - if (client_user != NULL) + if (client_user != NULL) { xfree(client_user); + client_user = NULL; + } if (attempt > AUTH_FAIL_MAX) packet_disconnect(AUTH_FAIL_MSG, pw->pw_name); This should close this bug and #54894 (which I don't believe would have posed security problems), and with a bit of luck might yield more clues to #51306 as well. HTH, -- Colin Watson [cjw44 at cam.ac.uk] --[[text/plain]] From phil at hands.com Wed Feb 9 15:46:09 2000 From: phil at hands.com (Philip Hands) Date: 09 Feb 2000 04:46:09 +0000 Subject: Bug#54823: openssh: config file parse error In-Reply-To: (Markus F.X.J. Oberhumer's message of "Wed, 12 Jan 2000 00:37:51 +0100 (CET)") References: Message-ID: <87g0v3q8z2.fsf@sheikh.hands.com> "Markus F.X.J. Oberhumer" writes: > Package: ssh > Version: 1.2.1pre24-1 > Severity: important > > I've just upgraded from ssh-nonfree to openssh and it seems > that openssh doesn't allow an additional `=' in the > config file options - but ssh 1.2.27 does. > > Attached is my ~/.ssh/config. > > Markus > > > # > # ~/.ssh/config > # > > Host * > FallBackToRsh = no > UseRsh = no Hi Markus, I think you'll find this is an undocumented feature of ssh-nonfree, and that OpenSSH is implementing the manual as it's written. That hardly qualifies as an ``Important'' bug IMO. ``Wishlist'', maybe. Anyway, if the upstream authors agree that it shouldn't choke on equal signs, as I do, then it'll get changed, but I don't think it's important enough to make Debian's behaviour differ from the rest. Cheers, Phil. From renaudg at hexanet.fr Thu Feb 10 22:51:52 2000 From: renaudg at hexanet.fr (Renaud Guerin) Date: Thu, 10 Feb 2000 12:51:52 +0100 Subject: ssh_exchange_identification fails Message-ID: <38A2A658.42ABFEF0@hexanet.fr> I'm running OpenSSH 1.2.2. with OpenSSL 0.9.4 on Linux 2.2.14 (Mandrake 7.0) They were recompiled from source RPMS with gcc 2.95.2 When I try to connect to localhost, I get SSH Version OpenSSH-1.2.2, protocol version 1.5. Compiled with SSL. debug: Reading configuration data /etc/ssh/ssh_config debug: Applying options for * debug: ssh_connect: getuid 0 geteuid 0 anon 0 debug: Connecting to localhost [127.0.0.1] port 22. debug: Allocated local port 662. debug: Connection established. ssh_exchange_identification: read: No such file or directory debug: Calling cleanup 0x80572e8(0x0) When I try to connect to my remote host, I get ssh_exchange_identification: read: Success If this is a FAQ, could you please point me to an URL with the answer ? Thanks a lot. (please cc me any answer, I'm not subscribed to this list) From Javor.Evstatiev at debis.at Fri Feb 11 01:36:16 2000 From: Javor.Evstatiev at debis.at (Javor Evstatiev) Date: Thu, 10 Feb 2000 15:36:16 +0100 Subject: config problem with 1.2.2 on Redhat 6.1 / pam Message-ID: <41256881.00504BED.00@cas-int.debis.csa.at> Hi there! I have a small - but essential :) - problem with the above configuration. I compiled the 1.2.2 version straight forward, with almost default settings (sysconfdir=/etc/ssh) After that I copied the sshd.pam to /etc/pam.d, generated the host-key and started sshd Feb 10 15:29:36 FW-W1A sshd[18351]: Server listening on 0.0.0.0 port 22. Feb 10 15:29:36 FW-W1A sshd[18351]: Generating 768 bit RSA key. Feb 10 15:29:37 FW-W1A sshd[18351]: RSA key generation complete. then I tried to login: ssh localhost -l jevv and got jevv at localhost's password: <- typed wrong password Permission denied, please try again. jevv at localhost's password: <- typed the correct pwd Connection to localhost closed by remote host. Connection to localhost closed. /var/log/messages: Feb 10 15:29:53 FW-W1A sshd[18353]: Accepted password for jevv from 127.0.0.1 port 1018 Feb 10 15:29:53 FW-W1A sshd[18353]: fatal: PAM session setup failed: System error Feb 10 15:29:53 FW-W1A sshd[18353]: Cannot close PAM session: System error So, I suppose this is _not_ an ssh problem, it is a PAM problem - but what to do? Am I overseeing something? Thx 4 any ideas in advance best javor From johnh at aproposretail.com Fri Feb 11 07:45:32 2000 From: johnh at aproposretail.com (John Hardin) Date: Thu, 10 Feb 2000 12:45:32 -0800 Subject: Clarification of error message due to /etc/hosts.allow problems Message-ID: <38A3236C.3764E2DF@aproposretail.com> {beware of line wrapping...} --- openssh-1.2.2-original/sshconnect.c Thu Jan 20 03:44:09 2000 +++ openssh-1.2.2/sshconnect.c Thu Feb 10 12:44:08 2000 @@ -961,7 +961,7 @@ /* Read other side\'s version identification. */ for (i = 0; i < sizeof(buf) - 1; i++) { if (read(connection_in, &buf[i], 1) != 1) - fatal("ssh_exchange_identification: read: %.100s", strerror(errno)); + fatal("ssh_exchange_identification: read: %.100s - check remote system\'s /etc/hosts.allow", strerror(errno)); if (buf[i] == '\r') { buf[i] = '\n'; buf[i + 1] = 0; -- John Hardin Internal Systems Administrator Apropos Retail Management Systems, Inc. From gem at rellim.com Fri Feb 11 10:21:33 2000 From: gem at rellim.com (Gary E. Miller) Date: Thu, 10 Feb 2000 15:21:33 -0800 (PST) Subject: EGD requirement a show stopper for me In-Reply-To: Message-ID: Yo Damien! I found out that the Apache product used the truerandom lib as an alternative for /dev/random. Here is a message I got from SCO support about: ftp://ftp.research.att.com/dist/mab/librand.shar It looks pretty easy to port. I could do it it you are interested. RGDS GARY --------------------------------------------------------------------------- Gary E. Miller Rellim 20340 Empire Ave, Suite E-3, Bend, OR 97701 gem at rellim.com Tel:+1(541)382-8588 Fax: +1(541)382-8676 This library is used by Apache to generate random numbers in the absence of /dev/random. It isn't a standard library, but is something that seems to have floated around on the net in more-or-less source form for some time. It isn't large - only a couple of hundred lines or so of source, and works by exploiting timing differences in system interrupts, rather than on specific and deterministic algorithms. I picked up my copy of it from ftp://ftp.research.att.com/dist/mab/ in librand.shar. It's now immortalized in the Apache build, so if you have any problems getting it from here, I can send you a copy. Regarding its use, well, I've appended the Apache routine that does the either-or thing with /dev/random and librand.a. --------------83C16BD8BCDAEE8FB656BDEA Content-Type: text/plain; charset=us-ascii; name="rand" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="rand" static void initialize_secret(server_rec *s) { #ifdef DEV_RANDOM FILE *rnd; size_t got, tot; #else extern int randbyte(void); /* from the truerand library */ unsigned int idx; #endif ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_NOTICE, s, "Digest: generating secret for digest authentication ..."); #ifdef DEV_RANDOM #define XSTR(x) #x #define STR(x) XSTR(x) if ((rnd = fopen(STR(DEV_RANDOM), "rb")) == NULL) { ap_log_error(APLOG_MARK, APLOG_CRIT, s, "Digest: Couldn't open " STR(DEV_RANDOM)); exit(EXIT_FAILURE); } if (setvbuf(rnd, NULL, _IONBF, 0) != 0) { ap_log_error(APLOG_MARK, APLOG_NOERRNO|APLOG_CRIT, s, "Digest: Error trying to disable buffering for " STR(DEV_RANDOM)); exit(EXIT_FAILURE); } for (tot=0; tot An embedded and charset-unspecified text was scrubbed... Name: not available Url: http://lists.mindrot.org/pipermail/openssh-unix-dev/attachments/20000211/7cc1ece1/attachment.ksh From forsaken at forsaken.logout.net Sat Feb 12 01:18:11 2000 From: forsaken at forsaken.logout.net (Andreas Westin) Date: Fri, 11 Feb 2000 15:18:11 +0100 Subject: Authentication problem Message-ID: <002801bf749a$d3de2580$abddf082@campus.luth.se> Hi, I am unable to use the linux port of openssh since it keeps telling me that I fail the password authentication or that there was an "unknown message during authentication: type 4", I am giving it the correct password and using a standard configuration of sshd. I'm using Slackware 7.0 and the latest version of both openssh and openssl (1.2.2 and 0.9.4). I'm not sure this is the right place to send this to but since i couldn't find any help in any of the docs I did. /Andreas From 96na at eng.cam.ac.uk Sat Feb 12 03:22:57 2000 From: 96na at eng.cam.ac.uk (Naz) Date: Fri, 11 Feb 2000 16:22:57 +0000 Subject: FAQ: Re: config problem with 1.2.2 on Redhat 6.1 / pam In-Reply-To: <41256881.00504BED.00@cas-int.debis.csa.at> Message-ID: <4.1.20000211161546.009e7e30@mail.newmail.net> >From the INSTALL file: using a recent version of Redhat Linux, the config file in packages/redhat/sshd.pam should be more useful. If you aren't using this file, then you should be. If you already have, then the problem lies with your PAM - RH6.1 has an update for PAM. FYI, i'm using a a stock installation of RH6.1 + all the updates. At 14:36 10/02/00 , Javor Evstatiev wrote: >After that I copied the sshd.pam to /etc/pam.d, generated the host-key and >started sshd >Feb 10 15:29:36 FW-W1A sshd[18351]: Server listening on 0.0.0.0 port 22. >Feb 10 15:29:36 FW-W1A sshd[18351]: Generating 768 bit RSA key. >Feb 10 15:29:37 FW-W1A sshd[18351]: RSA key generation complete. >ssh localhost -l jevv >jevv at localhost's password: <- typed wrong password >Permission denied, please try again. >jevv at localhost's password: <- typed the correct pwd >Connection to localhost closed by remote host. >Connection to localhost closed. >/var/log/messages: >Feb 10 15:29:53 FW-W1A sshd[18353]: Accepted password for jevv from 127.0.0.1 >port 1018 >Feb 10 15:29:53 FW-W1A sshd[18353]: fatal: PAM session setup failed: System >error >Feb 10 15:29:53 FW-W1A sshd[18353]: Cannot close PAM session: System error >So, I suppose this is _not_ an ssh problem, it is a PAM problem - but what to >do? Am I overseeing something? >Thx 4 any ideas in advance -naz- http://liquid.phase.net/ PGPrint: 8952 D341 EDE7 B8DE 6C6B D1FD 85F9 676B FD0B 917A Deja moo: The feeling that you've heard this bull before. From chad at vision.arc.nasa.gov Sat Feb 12 12:51:03 2000 From: chad at vision.arc.nasa.gov (Chad Netzer) Date: Fri, 11 Feb 2000 17:51:03 -0800 Subject: ssh_exchange_identification fails (how to fix) Message-ID: <20000211175103.A12872@newton.arc.nasa.gov> Renaud Guerin writes: >I'm running OpenSSH 1.2.2. with OpenSSL 0.9.4 on Linux 2.2.14 >(Mandrake 7.0) They were recompiled from source RPMS with gcc 2.95.2 >When I try to connect to localhost, I get >SSH Version OpenSSH-1.2.2, protocol version 1.5. >Compiled with SSL. >debug: Reading configuration data /etc/ssh/ssh_config >debug: Applying options for * >debug: ssh_connect: getuid 0 geteuid 0 anon 0 >debug: Connecting to localhost [127.0.0.1] port 22. >debug: Allocated local port 662. >debug: Connection established. >ssh_exchange_identification: read: No such file or directory >debug: Calling cleanup 0x80572e8(0x0) > >When I try to connect to my remote host, I get >ssh_exchange_identification: read: Success > I have a similar configuration, and was getting the same problem. A long look through the sources tells the tale. Basically, the problem can be cured by adding a line like the following to /etc/hosts.allow: sshd : hostname.on.whatever.net : ALLOW ie. Just add a line like you were enabling rlogind, but for "sshd". This is necessary because your "sshd" was compiled with LIBWRAP support, and since libwrap is called from "sshd", it expects to find "sshd" in the hosts.allow. You should be seeing the tell-tale "connection refused" lines in the /var/log/messages file of the machine running "sshd". I'm not sure if this is the intended behavior, but I suspect it is not, and could be considered a bug. It is confusing to NOLT be using "sshd" under inetd.conf with TCP_Wrappers, and yet still be getting behavior as though it were. You could also compile without LIBWRAP to remove this behavior. A second buglet occurs in sshconnect.c (from OpenSSH sources), in the ssh_exchange_identification() call. Here are the relevant lines. (lines 961-964): /* Read other side\'s version identification. */ for (i = 0; i < sizeof(buf) - 1; i++) { if (read(connection_in, &buf[i], 1) != 1) fatal("ssh_exchange_identification: read: %.100s", strerror(errno)); Notice that the conditional will fail and call fatal() if there are zero bytes read, which is not an error condition. Thus the "Success" error message that you got. The problem is that the "sshd" daemon on the other end has refused the connection (due to LIBWRAP, see lines 749-767 of sshd.c:main()), before writing anything to the socket, so the read gets an EOF (zero bytes read). The program should probably report a special case when the number of bytes read is zero (indicating that the server has refused a connection, or is not responding). So, the documentation (FAQs, HOWTOs, man, etc.) should be updated to explain this behavior when using "sshd" compiled with LIBWRAP, and perhaps OpenSSH should be fixed (if this behavior is indeed not the desired one. At least a mention of the consequences should appear in the "ssh" and "sshd" man pages) Chad Netzer cnetzer at stanford.edu From helm at fionn.es.net Sat Feb 12 13:44:57 2000 From: helm at fionn.es.net (Michael Helm) Date: Fri, 11 Feb 2000 18:44:57 -0800 Subject: ssh_exchange_identification fails (how to fix) In-Reply-To: Your message of "Fri, 11 Feb 2000 17:51:03 PST." <20000211175103.A12872@newton.arc.nasa.gov> Message-ID: <200002120244.SAA17804@fionn.es.net> Chad Netzer writes: > long look through the sources tells the tale. Basically, the problem > can be cured by adding a line like the following to /etc/hosts.allow: > > sshd : hostname.on.whatever.net : ALLOW Do you have a catch-all line in /etc/hosts.allow that denies "everything", or an /etc/hosts.deny file? eg ALL: ALL: DENY at the end of the file? From cnetzer at Stanford.EDU Sat Feb 12 19:12:39 2000 From: cnetzer at Stanford.EDU (Chad Franklin Netzer) Date: Sat, 12 Feb 2000 00:12:39 -0800 (PST) Subject: ssh_exchange_identification fails (how to fix) Message-ID: <200002120812.AAA06213@tree0.Stanford.EDU> Michael Helm writes: >Do you have a catch-all line in /etc/hosts.allow that denies >"everything", or an /etc/hosts.deny file? Yes, I should have mentioned that the "problem" only occurs on systems that have explicit enabling of selected services. So, by not enabling sshd in the hosts.allow file, it is automatically denied by hosts.deny. The problem for me really (and probably for others, like Renaud) is that since the sshd damon is not run from inetd, I didn't expect it to be under hosts.deny or hosts.allow control, and the ssh error message is quite deceptive (returning a "Success" string as the failure diagnosis :) The INSTALL file does briefly mention the tcp_wrappers option; it just caught me off guard. In retrospect, however, this behavior does appear to be the desired one, and not a bug. Cheers, Chad Netzer cnetzer at stanford.edu From dem0n at istc.kiev.ua Mon Feb 14 05:16:48 2000 From: dem0n at istc.kiev.ua (Igor Grabin) Date: Sun, 13 Feb 2000 20:16:48 +0200 (EET) Subject: server-side scp strangeness on linux Message-ID: Hiya, [if this is a known issue/misconfiguration, please direct me to the right fm :-); if this is a wrong place to ask, please tell me the right one] I'm using the linux port of openssh-1.2.2. The issue is that server-side scp doesn't work: scp somefile me at myhost: seems to take forever, and does nothing. sshd -d shows that scp -t somefile is being invoked on server side, and stays running long enough to get me bored. scp me at myhost:somefile . prints: C somefile ...and exits. no file copied. sshd -d also shows that scp -f somefile is being invoked on server side, exit status 1 ssh_config and sshd_config files are the default ones... I may post them if that matters. scp -v didn't reveal anything real useful, at least for me. scp with server being sshv1 did work. I compiled the whole thing from source, the configure line was: ./configure --sysconfdir=/etc --with-tcp-wrappers --with-ipv4-default --with-default-path="/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/bin" --with-pid-dir=/var/run System is rh-5.2 based, default compiler (gcc-2.7.2.3), default libc. The kernel is 2.0.38, patched with Andrea Arcangeli's 'ping -R' patch, and latest Solar Designer's patch, all of its options being active. If that issue requires some feedback/debugging from me, I am willing to do it. tia, -- Igor Grabin alias CacoDem0n[GOD] violent at death.kiev.ua, http://zoe.istc.kiev.ua/ From charles at comm.polymtl.ca Mon Feb 14 14:01:52 2000 From: charles at comm.polymtl.ca (Charles Levert) Date: 13 Feb 2000 22:01:52 -0500 Subject: [openssh-1.2.2] some porting notes for SunOS 4.1.4 Message-ID: Hi. Here are the relevant details about the setup: SunOS 4.1.4 gcc 2.7.2.2 tcp wrappers 7.5 egd 0.6 (doesn't really come into play at compile time) The following only pertains to the compilation (and linking) stage. Code and patches are SunOS specific. -- The following functions are missing in SunOS: strerror, atexit, memmove. I wrote simple replacements in term of on_exit and bcopy and linked them without problem when necessary. (See code at end of mail.) -- The mail directory could not be deduced from any header file. In addition, the MAIL environment variable was also not defined when running configure. As a consequence, MAIL_DIRECTORY was just #undef'ined in config.h and compilation of sshd.c failed. I recommend adding and documenting an explicit --maildir configure option. -- In packet.c, some IP TOS related constants are undefined. I assumed the associated setsockopt calls were optional, but I may be wrong. (See patch at end of mail.) -- In ssh-agent.c, optind needs to be declared explicitly (it is not in any header file). (See patch at end of mail.) -- In scp.c, the SA_RESTART constant is undefined. SunOS is already based on BSD signal semantics; do they also apply when using signal functions from the POSIX interface? (See patch at end of mail.) That's it for now. Charles ======================================================================== ==> strerror.c <== extern int sys_nerr; extern char *sys_errlist[]; char * strerror(e) int e; { return (e >= 0 && e < sys_nerr) ? sys_errlist[e] : "unlisted error" ; } ==> atexit.c <== #include extern int on_exit(void (*f)(), caddr_t a); int atexit(f) void (*f)(void); { return on_exit(f, 0) ? 0 : -1; } ==> memmove.c <== extern void bcopy(char *b1, char *b2, int l); void * memmove(d, s, l) char *d; char *s; int l; { bcopy(s, d, l); return d; } ======================================================================== --- packet.c.orig-1.2.2 Sat Jan 22 17:38:00 2000 +++ packet.c Sun Feb 13 13:06:04 2000 @@ -796,22 +796,28 @@ * Set IP options for an interactive connection. Use * IPTOS_LOWDELAY and TCP_NODELAY. */ +#ifdef IPTOS_LOWDELAY int lowdelay = IPTOS_LOWDELAY; if (setsockopt(connection_in, IPPROTO_IP, IP_TOS, (void *) &lowdelay, sizeof(lowdelay)) < 0) error("setsockopt IPTOS_LOWDELAY: %.100s", strerror(errno)); +#endif /* IPTOS_LOWDELAY */ +#ifdef TCP_NODELAY if (setsockopt(connection_in, IPPROTO_TCP, TCP_NODELAY, (void *) &on, sizeof(on)) < 0) error("setsockopt TCP_NODELAY: %.100s", strerror(errno)); +#endif /* TCP_NODELAY */ } else { /* * Set IP options for a non-interactive connection. Use * IPTOS_THROUGHPUT. */ +#ifdef IPTOS_THROUGHPUT int throughput = IPTOS_THROUGHPUT; if (setsockopt(connection_in, IPPROTO_IP, IP_TOS, (void *) &throughput, sizeof(throughput)) < 0) error("setsockopt IPTOS_THROUGHPUT: %.100s", strerror(errno)); +#endif /* IPTOS_THROUGHPUT */ } } ======================================================================== --- ssh-agent.c.orig-1.2.2 Mon Jan 3 07:41:05 2000 +++ ssh-agent.c Sun Feb 13 15:35:23 2000 @@ -507,6 +507,7 @@ struct sockaddr_un sunaddr; pid_t pid; char *shell, *format, *pidstr, pidstrbuf[1 + 3 * sizeof pid]; + extern int optind; /* check if RSA support exists */ if (rsa_alive() == 0) { ======================================================================== --- scp.c.orig-1.2.2 Thu Jan 13 23:45:51 2000 +++ scp.c Sun Feb 13 15:58:20 2000 @@ -1229,7 +1229,10 @@ struct sigaction sa; sa.sa_handler = updateprogressmeter; sigemptyset(&sa.sa_mask); - sa.sa_flags = SA_RESTART; + sa.sa_flags = 0; +#ifdef SA_RESTART + sa.sa_flags |= SA_RESTART; +#endif /* SA_RESTART */ sigaction(SIGALRM, &sa, NULL); alarmtimer(1); } else if (flag == 1) { ======================================================================== From yoshfuji at ecei.tohoku.ac.jp Mon Feb 14 17:52:54 2000 From: yoshfuji at ecei.tohoku.ac.jp (Hideaki YOSHIFUJI) Date: Mon, 14 Feb 2000 15:52:54 +0900 Subject: X11 forwarding issues with Linux Message-ID: <20000214155254W.yoshfuji@cerberus.nemoto.ecei.tohoku.ac.jp> Hi, >I think I might have a bug here, but I'm not sure. > >I just cannot seem to win with X11 forwarding and OpenSSH-1.2.2! >The shell works fine though. : >After I compiled it in, with the 2.3.42 kernel, sshd was saying this: > >debug: Received request for X11 forwarding with auth spoofing. >debug: bind port 6010: Address already in use >debug: bind port 6011: Address already in use >... >debug: bind port 6998: Address already in use >debug: bind port 6999: Address already in use >error: Failed to allocate internet-domain X11 display socket. >debug: Forking shell. This is because the Linux kernel won't have sockets bound to the same ports even in different families (like IPv6 and IPv4). (This problem also exists in old IPv6 patch for ssh-nonfree.) I've made a patch and it is available at It also fixes the IPv4-mapped address problem (sshd on IPv6 node warns connections from ssh/IPv4). Thanks. -- Hideaki YOSHIFUJI Web Page: http://www.ecei.tohoku.ac.jp/%7Eyoshfuji/ PGP5i FP: F731 6599 5EB2 BBA7 1515 1323 1806 A96F 5700 6B25 From Ola at Sigurdson.SE Mon Feb 14 23:54:00 2000 From: Ola at Sigurdson.SE (Ola Sigurdson) Date: Mon, 14 Feb 2000 13:54:00 +0100 Subject: Binding ssh to priviledged port breaks rule (port < 1024 => system service) Message-ID: <38A7FAE8.D7CE59D@Sigurdson.SE> I'm sure there is a rationale for binding the ssh client to a priviledged port. (Which?) However there are several drawbacks to this: o It breaks firewall rules that assume that user connections start at port > 1024 or > 32768. o It breaks monitoring software using the same assumptions. o Every suid program is a separate evil (caused by the flawed security model in most unices). I therefore suggest that distribution ship with no suid. Anyway, thanks for a great piece of software. /Ola Sigurdson -------------- next part -------------- A non-text attachment was scrubbed... Name: smime.p7s Type: application/x-pkcs7-signature Size: 1116 bytes Desc: S/MIME Cryptographic Signature Url : http://lists.mindrot.org/pipermail/openssh-unix-dev/attachments/20000214/5aea133f/attachment.bin From Nigel.Metheringham at VData.co.uk Tue Feb 15 00:06:52 2000 From: Nigel.Metheringham at VData.co.uk (Nigel Metheringham) Date: Mon, 14 Feb 2000 13:06:52 +0000 Subject: Binding ssh to priviledged port breaks rule (port < 1024 => system service) In-Reply-To: Message from Ola Sigurdson of "Mon, 14 Feb 2000 13:54:00 +0100." <38A7FAE8.D7CE59D@Sigurdson.SE> Message-ID: Ola at Sigurdson.SE said: > I'm sure there is a rationale for binding the ssh client to a > priviledged port. (Which?) If you are doing rsh like authentication (you trust the host (having authenticated the host), on the identity of the user as opposed to making the user authenticate with his own keys), then you need to be able to read the host key (that requires root normally). Tied in with that is the server expects connections from trusted hosts should be originated from priv ports. You can just knock the SUID bit off ssh if you use only user based keys and/or password authentication, and do not use host based authentication. Nigel. -- [ - Opinions expressed are personal and may not be shared by VData - ] [ Nigel Metheringham Nigel.Metheringham at VData.co.uk ] [ Phone: +44 1423 850000 Fax +44 1423 858866 ] From markus.friedl at informatik.uni-erlangen.de Tue Feb 15 00:17:54 2000 From: markus.friedl at informatik.uni-erlangen.de (Markus Friedl) Date: Mon, 14 Feb 2000 14:17:54 +0100 Subject: Binding ssh to priviledged port breaks rule (port < 1024 => system service) In-Reply-To: <38A7FAE8.D7CE59D@Sigurdson.SE>; from Ola@Sigurdson.SE on Mon, Feb 14, 2000 at 01:54:00PM +0100 References: <38A7FAE8.D7CE59D@Sigurdson.SE> Message-ID: <20000214141754.A19732@folly.informatik.uni-erlangen.de> On Mon, Feb 14, 2000 at 01:54:00PM +0100, Ola Sigurdson wrote: > I'm sure there is a rationale for binding the ssh client to a > priviledged port. (Which?) for rhosts/rhosts-rsa authentication the server has to trust the username supplied by the client program. the client is only trusted if it runs as root and 'shows' its privileges by binding to a random low port. you can turn this behaviour of with: Host * UsePrivilegedPort no or Host * RhostsAuthentication no RhostsRSAAuthentication no -markus From sen_ml at eccosys.com Tue Feb 15 00:42:11 2000 From: sen_ml at eccosys.com (sen_ml at eccosys.com) Date: Mon, 14 Feb 2000 22:42:11 +0900 Subject: Binding ssh to priviledged port breaks rule (port < 1024 => system service) In-Reply-To: <38A7FAE8.D7CE59D@Sigurdson.SE> References: <38A7FAE8.D7CE59D@Sigurdson.SE> Message-ID: <20000214224211E.1000@eccosys.com> Ola> o It breaks firewall rules that assume that user connections start at Ola> port > 1024 or > 32768. bad assumption on the part of the rule writer. Ola> o It breaks monitoring software using the same assumptions. bad assumption on the part of the software author. Ola> o Every suid program is a separate evil (caused by the flawed security Ola> model in most unices). using setuid properly is hard, but setuid is not evil, imo. From Ola at Sigurdson.SE Tue Feb 15 00:49:14 2000 From: Ola at Sigurdson.SE (Ola Sigurdson) Date: Mon, 14 Feb 2000 14:49:14 +0100 Subject: Binding ssh to priviledged port breaks rule (port < 1024 => system service) References: <38A7FAE8.D7CE59D@Sigurdson.SE> <20000214141754.A19732@folly.informatik.uni-erlangen.de> Message-ID: <38A807DA.3B5133AD@Sigurdson.SE> Well, yes I know how to turn it off. What I'm saying is that suid should be turned off by default as it will cause problems for a large subset of sites who only want to use ssh as a secure telnet replacement. (If you want to allow automatic logins without passwords you anyway have some serious thinking and configuration to do. Turning on the suid bit is not that big a deal in that case. From ssh.1: /etc/hosts.equiv, .rhosts, and the rlogin/rsh protocol in general, are inherently insecure and should be disabled if security is desired. ) Markus Friedl wrote: > > On Mon, Feb 14, 2000 at 01:54:00PM +0100, Ola Sigurdson wrote: > > I'm sure there is a rationale for binding the ssh client to a > > priviledged port. (Which?) > > for rhosts/rhosts-rsa authentication the server has to trust the > username supplied by the client program. > > the client is only trusted if it runs as root and 'shows' its > privileges by binding to a random low port. > > you can turn this behaviour of with: > Host * > UsePrivilegedPort no > or > Host * > RhostsAuthentication no > RhostsRSAAuthentication no > > -markus From Markus.Friedl at informatik.uni-erlangen.de Tue Feb 15 01:11:00 2000 From: Markus.Friedl at informatik.uni-erlangen.de (Markus Friedl) Date: Mon, 14 Feb 2000 15:11:00 +0100 Subject: Binding ssh to priviledged port breaks rule (port < 1024 => system service) In-Reply-To: <38A807DA.3B5133AD@Sigurdson.SE>; from Ola@Sigurdson.SE on Mon, Feb 14, 2000 at 02:49:14PM +0100 References: <38A7FAE8.D7CE59D@Sigurdson.SE> <20000214141754.A19732@folly.informatik.uni-erlangen.de> <38A807DA.3B5133AD@Sigurdson.SE> Message-ID: <20000214151100.A19430@faui01.informatik.uni-erlangen.de> On Mon, Feb 14, 2000 at 02:49:14PM +0100, Ola Sigurdson wrote: > What I'm saying is that suid should be turned off by default as it will > cause problems for a large subset of sites who only want to use ssh as a > secure telnet replacement. ssh is a rsh replacement, too and rhosts-rsa is not considered inherently insecure but needs the s-bit. please tell me the problems caused by the s-bit. -markus From Ola at Sigurdson.SE Tue Feb 15 02:28:09 2000 From: Ola at Sigurdson.SE (Ola Sigurdson) Date: Mon, 14 Feb 2000 16:28:09 +0100 Subject: Binding ssh to priviledged port breaks rule (port < 1024 => system service) References: <38A7FAE8.D7CE59D@Sigurdson.SE> <20000214141754.A19732@folly.informatik.uni-erlangen.de> <38A807DA.3B5133AD@Sigurdson.SE> <20000214151100.A19430@faui01.informatik.uni-erlangen.de> Message-ID: <38A81F09.1631FCE@Sigurdson.SE> Markus Friedl wrote: > > On Mon, Feb 14, 2000 at 02:49:14PM +0100, Ola Sigurdson wrote: > > What I'm saying is that suid should be turned off by default as it will > > cause problems for a large subset of sites who only want to use ssh as a > > secure telnet replacement. > > ssh is a rsh replacement, too and rhosts-rsa is not > considered inherently insecure but needs the s-bit. > please tell me the problems caused by the s-bit. The problems are not caused by the s-bit as such, they are caused by ssh binding to a random priviledged port when running as root. For example if you have a firewall denying traffic to and from port 137 (Netbios) and ssh binds to 137 (on a host not running netbios services) you will get no connection out, and the firewall will log an illegal packet. The majority of people installing ssh do just "make install" or "rpm -U openssh*" which will give them ssh connections from random priviledged ports regardless of whether the remote host uses rhost-based login or not. Philosophical discussion: Suid programs are bad, hard to debug and and only exist as a hack around flawed security models or policies. The less the better. Regarding the rhost-rsa authentication it is also a hack around a flawed security model, the idea being to do two very different authentications at the same time: The user id and the specific machine id of the client. It's better to split the authentication into two different steps, for example using IPsec to verify the connection, and then using ssh with rsa chap to verify the user. Besides, for most applications, user authentication with a rsa certificate should be enough for access control. From info at digital-concepts.net Tue Feb 15 14:25:29 2000 From: info at digital-concepts.net (Chris Ihlenfeld) Date: Mon, 14 Feb 2000 22:25:29 -0500 Subject: Problem compiling 1.2.2 on solaris Message-ID: <38A8C729.B6AEA5C8@digital-concepts.net> I am trying to run the configure for 1.2.2 on an intel solaris 2.7 box and I get an error for urandom not found. I cant find anything related to rand, urand, random, rng, or urandom on my box. How can I get around this, or where can I get urandom? Chris From djm at mindrot.org Tue Feb 15 18:45:58 2000 From: djm at mindrot.org (Damien Miller) Date: Tue, 15 Feb 2000 18:45:58 +1100 (EST) Subject: Binding ssh to priviledged port breaks rule (port < 1024 => system service) In-Reply-To: <38A807DA.3B5133AD@Sigurdson.SE> Message-ID: On Mon, 14 Feb 2000, Ola Sigurdson wrote: > Well, yes I know how to turn it off. > > What I'm saying is that suid should be turned off by default as it will > cause problems for a large subset of sites who only want to use ssh as a > secure telnet replacement. {Open}SSH is a secure _rsh_ replacement. If you think about it like this then its use of a secure port should be no surprise. -d -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From sumikawa at ebina.hitachi.co.jp Tue Feb 15 22:18:47 2000 From: sumikawa at ebina.hitachi.co.jp (sumikawa at ebina.hitachi.co.jp) Date: Tue, 15 Feb 2000 20:18:47 +0900 (JST) Subject: tiny bug fix Message-ID: <200002151118.UAA58729@prince.net.ebina.hitachi.co.jp> Hi, when IPv4-only client connect to a server which have IPv4 and IPv6 addresses, the client can't connect to the server via IPv4 because the client give up on first rresevport_af(). the below patch fixes it. --- Munechika SUMIKAWA @ KAME Project / FreeBSD.org Index: sshconnect.c =================================================================== RCS file: /cvs/src/usr.bin/ssh/sshconnect.c,v retrieving revision 1.53 diff -u -r1.53 sshconnect.c --- sshconnect.c 2000/01/18 09:42:17 1.53 +++ sshconnect.c 2000/02/15 10:18:18 @@ -150,7 +150,7 @@ int p = IPPORT_RESERVED - 1; sock = rresvport_af(&p, family); if (sock < 0) - fatal("rresvport: af=%d %.100s", family, strerror(errno)); + error("rresvport: af=%d %.100s", family, strerror(errno)); debug("Allocated local port %d.", p); } else { /* From mortene at sim.no Wed Feb 16 01:57:24 2000 From: mortene at sim.no (Morten Eriksen) Date: 15 Feb 2000 15:57:24 +0100 Subject: Problem compiling 1.2.2 on solaris In-Reply-To: Chris Ihlenfeld's message of "Mon, 14 Feb 2000 22:25:29 -0500" References: <38A8C729.B6AEA5C8@digital-concepts.net> Message-ID: <51k8k6secr.fsf@trh.sim.no> A non-text attachment was scrubbed... Name: fallback-openssh.diff Type: application/octet-stream Size: 3197 bytes Desc: not available Url : http://lists.mindrot.org/pipermail/openssh-unix-dev/attachments/20000215/3c1cec94/attachment.obj From mortene at sim.no Wed Feb 16 02:10:12 2000 From: mortene at sim.no (Morten Eriksen) Date: 15 Feb 2000 16:10:12 +0100 Subject: [PATCH] minor build fixes Message-ID: <51bt5isdrf.fsf@trh.sim.no> An embedded and charset-unspecified text was scrubbed... Name: config-openssh.diff Url: http://lists.mindrot.org/pipermail/openssh-unix-dev/attachments/20000215/dade6992/attachment.ksh From djm at mindrot.org Wed Feb 16 07:11:17 2000 From: djm at mindrot.org (Damien Miller) Date: Wed, 16 Feb 2000 07:11:17 +1100 (EST) Subject: Problem compiling 1.2.2 on solaris In-Reply-To: <51k8k6secr.fsf@trh.sim.no> Message-ID: On 15 Feb 2000, Morten Eriksen wrote: > Here's a patch I've written which makes the code fall back on srand() > and rand() if neither /dev/urandom nor the EGD is available. > > Note that this has implications for the security of your ssh/sshd > installation, and if I've understood the discussion from last week > correctly, something like this will never actually make it into the > distribution -- not even only as a last resort fallback. Please don't use such patches, they completely ruin OpenSSH's cryptographic security. The crypto in OpenSSH needs good, hard to predict random numbers. We prefer that such random numbers come from a range of difficult to guess sources such as interrupt timings, keystroke and mouse event times, etc. The free Unices kernel random number pools do a great job of collecting and aggregating these sources. EGD is patterned after these designs, but it doesn't have access to the wide variety of entropy sources that the kernel does. Still, it uses good algorithms to aggregate the entropy it does collect and maintains a fairly large pool. On the other hand, libc's rand functions use a linear congruential generator to generate their "random" numbers. Such functions are very simple [r=(a+b)%p;a=r; IIRC] and vary easy to reverse. You probably wouldn't need to reverse it anyway - most rand() functions only have 32 bits of state and they are usually seeded with the current system time and/or pid, both of which are available to an attacker. Work is underway to port Schneier and Kelsey's Yarrow PRNG code from Windows to a Unix library. When this is done and audited, it will probably replace EGD in OpenSSH. Regards, Damien Miller -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From carrier at cs.purdue.edu Wed Feb 16 08:22:19 2000 From: carrier at cs.purdue.edu (Brian Carrier) Date: Tue, 15 Feb 2000 16:22:19 -0500 (EST) Subject: Rekeying Message-ID: Hello, I apologize that this is slightly off topic. According to the Internet Draft I found for SSH ver 1 (draft-ietf-tls-ssh-00.txt from Jun 13, 1996), the client or server can send a SSH_MSG_KEXINIT at any time to force a new key exchange. I looked through the code for OpenSSH and ssh-1.2.27 and can't find where it does this. I then searched the Secure Shell mailing list archives and saw some comments that rekeying will be implemented in Ver 2. Did I miss the code in OpenSSH? Are there any ver. 1 implementations that provide rekeying? The draft also says that the session key is broken up to provide different encryption keys and iv's, but the code seems to use the same keys for both directions and iv = 0. Is there anywhere that I can get a more up to date protocol spec? thanks, brian From markus.friedl at informatik.uni-erlangen.de Wed Feb 16 09:40:23 2000 From: markus.friedl at informatik.uni-erlangen.de (Markus Friedl) Date: Tue, 15 Feb 2000 23:40:23 +0100 Subject: Rekeying In-Reply-To: ; from carrier@cs.purdue.edu on Tue, Feb 15, 2000 at 04:22:19PM -0500 References: Message-ID: <20000215234023.A9796@folly.informatik.uni-erlangen.de> Hello Brian, 1) draft-ietf-tls-ssh-00.txt is obsolete. There is no known implementation. 2) OpenSSH-1.2.2 and ssh-1.2.27 implement the SSH-1.5 protocol. This version does not support rekeying or IV's other then zero. The file RFC.nroff from the OpenSSH distribution describes SSH-1.3. 3) SSH2 supports all the features you mentioned (IVs, different keys and algorithms per direction, rekeying and much more). See the draft-ietf-secsh-* series for more information, especially draft-ietf-secsh-transport-06.txt -markus On Tue, Feb 15, 2000 at 04:22:19PM -0500, Brian Carrier wrote: > According to the Internet Draft I found for SSH ver 1 > (draft-ietf-tls-ssh-00.txt from Jun 13, 1996), the client or server can > send a SSH_MSG_KEXINIT at any time to force a new key exchange. I looked > through the code for OpenSSH and ssh-1.2.27 and can't find where it does > this. I then searched the Secure Shell mailing list archives and saw some > comments that rekeying will be implemented in Ver 2. > > Did I miss the code in OpenSSH? Are there any ver. 1 implementations that > provide rekeying? The draft also says that the session key is broken up > to provide different encryption keys and iv's, but the code seems to use > the same keys for both directions and iv = 0. Is there anywhere that I > can get a more up to date protocol spec? > > thanks, > brian > > > > From info at digital-concepts.net Wed Feb 16 10:25:43 2000 From: info at digital-concepts.net (Chris Ihlenfeld) Date: Tue, 15 Feb 2000 18:25:43 -0500 Subject: Problem compiling 1.2.2 on solaris References: Message-ID: <38A9E077.73191AE4@digital-concepts.net> I managed to get the egd working...pretty poor documentation on how to get it working with ssh. Is there a way to secure ftp? So that people from the outside using cuteftp, or some other windows type ftp are secured also? Chris Damien Miller wrote: > On 15 Feb 2000, Morten Eriksen wrote: > > > Here's a patch I've written which makes the code fall back on srand() > > and rand() if neither /dev/urandom nor the EGD is available. > > > > Note that this has implications for the security of your ssh/sshd > > installation, and if I've understood the discussion from last week > > correctly, something like this will never actually make it into the > > distribution -- not even only as a last resort fallback. > > Please don't use such patches, they completely ruin OpenSSH's > cryptographic security. > > The crypto in OpenSSH needs good, hard to predict random numbers. We > prefer that such random numbers come from a range of difficult to > guess sources such as interrupt timings, keystroke and mouse event > times, etc. The free Unices kernel random number pools do a great job > of collecting and aggregating these sources. > > EGD is patterned after these designs, but it doesn't have access to > the wide variety of entropy sources that the kernel does. Still, it > uses good algorithms to aggregate the entropy it does collect and > maintains a fairly large pool. > > On the other hand, libc's rand functions use a linear congruential > generator to generate their "random" numbers. Such functions are very > simple [r=(a+b)%p;a=r; IIRC] and vary easy to reverse. You probably > wouldn't need to reverse it anyway - most rand() functions only have > 32 bits of state and they are usually seeded with the current system > time and/or pid, both of which are available to an attacker. > > Work is underway to port Schneier and Kelsey's Yarrow PRNG code from > Windows to a Unix library. When this is done and audited, it will > probably replace EGD in OpenSSH. > > Regards, > Damien Miller > > -- > | "Bombay is 250ms from New York in the new world order" - Alan Cox > | Damien Miller - http://www.mindrot.org/ > | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From buhr at stat.wisc.edu Wed Feb 16 11:30:49 2000 From: buhr at stat.wisc.edu (Kevin Buhr) Date: 15 Feb 2000 18:30:49 -0600 Subject: a protocol weakness at the user-interface level Message-ID: I'm afraid I'm not at all involved with OpenSSH development, so perhaps this attack has been discussed in the past. It's something that seems difficult to search for in mailing list archives. I found myself reflecting on the following, mildly serious, protocol weakness at the user-interface level. In a nutshell, the OpenSSH client (at least as of version 1.2.2) fails to provide explicit notification to the user that the authentication process has completed and he or she has crossed a "trust barrier" from the local machine to a remote machine. For example, if a user is authenticated via a key held by "ssh-agent" or via host-based authentication through a "hosts.equiv" or ".shosts" file, there is no indication of successful authentication other than a login banner. Obviously, then, a user cannot easily distinguish a legitimate authentication prompt presented by the local machine from a phony one presented by a remote machine that has somehow permitted the user's client to "silently" authenticate. Similarly, a user cannot easily distinguish between the legitimate case of an incorrectly entered passphrase and a phony error message and second passphrase prompt provided by a remote machine. What is the impact? Well, it has always been the case that password-based authentication to a compromised host is unsafe, at least in the sense that a compromised OpenSSH (or original SSH) daemon can collect plaintext passwords. On the other hand, there is an expectation that RSA-based authentication is safe (in the sense of keeping the passphrase secret), even when connecting to an untrusted host. Unfortunately, a compromised OpenSSH daemon can allow the client to authenticate without requiring a passphrase or password, send a phony passphrase prompt to the user, and collect the plaintext passphrase from the user. In an ideal world, this passphrase would still be largely useless. In practice, I don't think a passphrase is something anyone wants to give away. For most users, it's hard to resist the temptation to use the same (or at least a similar) passphrase for multiple private keys on different hosts. Also, a decoy attack like this can be launched quite easily from a single compromised user account against its owner. If the OpenSSH daemon on the half-compromised host is configured to permit RSA-based host authentication via ".shosts" and ".ssh/known_hosts" files, the attacker can modify a few dotfiles (including creating a ".hushlogin" file) to very effectively prompt for and store a user's plaintext passphrase without any indication that something is seriously wrong. There's one simple solution, of course. Have the client alert the user when authentication completes: any authentication-related prompts following that message are not legitimate. Ideally, the message should be followed by a "press enter to continue" prompt (or at least a short pause) to prevent the remote end from immediately sending terminal control information to overwrite the authentication completion message and circumventing the protection. Any other thoughts? In the meantime, I offer a simple workaround. Use "ssh-agent" or ".shosts" files preemptively; then, *any* prompts for passphrases are immediately suspect. Kevin From provos at citi.umich.edu Wed Feb 16 13:00:08 2000 From: provos at citi.umich.edu (Niels Provos) Date: Tue, 15 Feb 2000 21:00:08 -0500 Subject: Problem compiling 1.2.2 on solaris In-Reply-To: Morten Eriksen, 15 Feb 2000 15:57:24 +0100 Message-ID: <20000216020205.24F702728D@toad.mindrot.org> In message <51k8k6secr.fsf at trh.sim.no>, Morten Eriksen writes: >Here's a patch I've written which makes the code fall back on srand() >and rand() if neither /dev/urandom nor the EGD is available. > >Note that this has implications for the security of your ssh/sshd >installation, and if I've understood the discussion from last week >correctly, something like this will never actually make it into the >distribution -- not even only as a last resort fallback. I am sorry. It seems to me that you understand why using such a patch is completely wrong. So, why do you post it here? If there is no way to get good randomness than openssh should terminate. Your operating system should provide application programs with a source of randomness. If it doesnt, than it needs to be fixed. You might want to look into a user provided one-time randomness file. While not perfect, it is certainly better than using rand(). Niels. From dugsong at monkey.org Wed Feb 16 17:51:23 2000 From: dugsong at monkey.org (Dug Song) Date: Wed, 16 Feb 2000 01:51:23 -0500 (EST) Subject: new OpenSSH t-shirts Message-ID: new OpenSSH t-shirts for sale: http://www.monkey.org/openssh/ 3-D rendered blowfish design, $15 USD ppd. limited time only. slices and dices. etc. -d. --- http://www.monkey.org/~dugsong/ From mortene at sim.no Wed Feb 16 18:30:32 2000 From: mortene at sim.no (Morten Eriksen) Date: 16 Feb 2000 08:30:32 +0100 Subject: Problem compiling 1.2.2 on solaris In-Reply-To: Damien Miller's message of "Wed, 16 Feb 2000 07:11:17 +1100 (EST)" References: Message-ID: <51hff938pz.fsf@trh.sim.no> * Damien Miller > The crypto in OpenSSH needs good, hard to predict random numbers. We > prefer that such random numbers come from a range of difficult to > guess sources such as interrupt timings, keystroke and mouse event > times, etc. > > On the other hand, libc's rand functions [...] are usually seeded > with the current system time and/or pid, both of which are available > to an attacker. The microseconds part of the struct timeval filled in by the gettimeofday() call seems like it could be a decent source of entropy in itself to me. Would you care to explain why this is not correct? Is it because the granularity of system clocks are not good enough, or is there a pattern to how the value of the microseconds part will be set? > Work is underway to port Schneier and Kelsey's Yarrow PRNG code from > Windows to a Unix library. When this is done and audited, it will > probably replace EGD in OpenSSH. Ok, great. Does the functionality of this code include both a PRNG and an entropy source for the seed? Regards, Morten Eriksen From mortene at sim.no Wed Feb 16 18:39:00 2000 From: mortene at sim.no (Morten Eriksen) Date: 16 Feb 2000 08:39:00 +0100 Subject: Problem compiling 1.2.2 on solaris In-Reply-To: Niels Provos's message of "Tue, 15 Feb 2000 21:00:08 -0500" References: <51ln4l39if.fsf@totally-fudged-out-message-id> Message-ID: <51d7px38bv.fsf@trh.sim.no> * Niels Provos > I am sorry. It seems to me that you understand why using such a > patch is completely wrong. So, why do you post it here? First you snip away the text where I explain why I posted it ("if I've understood the discussion from last week correctly, something like this will never actually make it into the distribution [...] But I don't know much about the issues involved, and I might be wrong."), then you ask why I posted it? Come on, give me a break. > You might want to look into a user provided one-time randomness > file. While not perfect, it is certainly better than using rand(). Sounds like a good idea, and I guess this is what the original ssh does when it asks the user to move the mouse around or bang the keyboard, right? Would there be any point in submitting a patch which implements the same "file of randomness" generation as ssh? Or would that just be "super-seeded" (*ough* what a terrible pun) by the effort to port Yarrow? Regards, Morten Eriksen From markus.friedl at informatik.uni-erlangen.de Wed Feb 16 21:07:56 2000 From: markus.friedl at informatik.uni-erlangen.de (Markus Friedl) Date: Wed, 16 Feb 2000 11:07:56 +0100 Subject: a protocol weakness at the user-interface level In-Reply-To: ; from buhr@stat.wisc.edu on Tue, Feb 15, 2000 at 06:30:49PM -0600 References: Message-ID: <20000216110756.A10932@folly.informatik.uni-erlangen.de> > Any other thoughts? use 'ssh -v host' if you really want to know what's going on. From dzhao1 at gl.umbc.edu Thu Feb 17 12:06:05 2000 From: dzhao1 at gl.umbc.edu (Di Zhao) Date: Wed, 16 Feb 2000 20:06:05 -0500 Subject: Idle time out Message-ID: Hi, I don't know if this is the approriate place to post it. But it really annoying me. My ssh connection times out every 10 minutes or so and I want it to keep open for like 3 hours so that I don't have to relogin. However, I cannot find an option to change this!! In the Secure SSH we have a option called IdelTimeout to deal with this but OpenSSH seems to totally ignore this option. Can somebody tell me how to modify the c files to change this?? Or will there be support for this? Many thanks. -- "My grandpa told me to remember two things in life. Look out for Number One, and remember your number" - Orville Cogswell -- http://members.xoom.com/_XOOM/dizhao/index.html From Nigel.Metheringham at VData.co.uk Thu Feb 17 20:24:54 2000 From: Nigel.Metheringham at VData.co.uk (Nigel Metheringham) Date: Thu, 17 Feb 2000 09:24:54 +0000 Subject: Idle time out In-Reply-To: Message from Di Zhao of "Wed, 16 Feb 2000 20:06:05 EST." Message-ID: dzhao1 at gl.umbc.edu said: > My ssh connection times out every 10 minutes or so and I want it to > keep open for like 3 hours so that I don't have to relogin. This would normally be a function of the shell/utilties/policy on the box you are logging into and nothing to do with ssh. There is a keep-alive function - this I understand is done by putting a keep-alive on the socket used, and the timeouts cannot be easily tweaked on OSes I use. Nigel. -- [ - Opinions expressed are personal and may not be shared by VData - ] [ Nigel Metheringham Nigel.Metheringham at VData.co.uk ] [ Phone: +44 1423 850000 Fax +44 1423 858866 ] From itamars at ibm.net Thu Feb 17 21:30:31 2000 From: itamars at ibm.net (Itamar Shtull-Trauring) Date: Thu, 17 Feb 2000 12:30:31 +0200 Subject: OpenSSH allows guessing of root password? Message-ID: <38ABCDC7.E22113B7@ibm.net> I set sshd to deny root login. But I still get a password prompt! So if I get the password right, I get one error message: Received disconnect: ROOT LOGIN REFUSED FROM example.com while if I simply put in a wrong password three times I get Permission denied. If this means I set it up wrong please mail me directly - I'm not subscribed to the list. Otherwise please fix this. -- The SNAFU Principle: True communication is possible only between equals Itamar S.T. itamars at ibm.net From markus.friedl at informatik.uni-erlangen.de Thu Feb 17 22:06:18 2000 From: markus.friedl at informatik.uni-erlangen.de (Markus Friedl) Date: Thu, 17 Feb 2000 12:06:18 +0100 Subject: OpenSSH allows guessing of root password? In-Reply-To: <38ABCDC7.E22113B7@ibm.net>; from itamars@ibm.net on Thu, Feb 17, 2000 at 12:30:31PM +0200 References: <38ABCDC7.E22113B7@ibm.net> Message-ID: <20000217120618.A25751@folly.informatik.uni-erlangen.de> On Thu, Feb 17, 2000 at 12:30:31PM +0200, Itamar Shtull-Trauring wrote: > I set sshd to deny root login. But I still get a password prompt! So if I > get the password right, I get one error message: > > Received disconnect: ROOT LOGIN REFUSED FROM example.com > > while if I simply put in a wrong password three times I get > > Permission denied. > > If this means I set it up wrong please mail me directly - I'm not subscribed > to the list. Otherwise please fix this. could you please try this: Index: sshd.c =================================================================== RCS file: /home/markus/cvs/ssh/sshd.c,v retrieving revision 1.88 diff -u -p -r1.88 sshd.c --- sshd.c 2000/02/15 16:52:57 1.88 +++ sshd.c 2000/02/17 11:03:08 @@ -1244,14 +1244,6 @@ do_authentication() do_authloop(pw); } - /* Check if the user is logging in as root and root logins are disallowed. */ - if (pw->pw_uid == 0 && !options.permit_root_login) { - if (forced_command) - log("Root login accepted for forced command."); - else - packet_disconnect("ROOT LOGIN REFUSED FROM %.200s", - get_canonical_hostname()); - } /* The user has been authenticated and accepted. */ packet_start(SSH_SMSG_SUCCESS); packet_send(); @@ -1487,6 +1479,21 @@ do_authloop(struct passwd * pw) */ log("Unknown message during authentication: type %d", type); break; + } + + /* + * Check if the user is logging in as root and root logins + * are disallowed. + * Note that root login is allowed for forced commands. + */ + if (authenticated && pw->pw_uid == 0 && !options.permit_root_login) { + if (forced_command) { + log("Root login accepted for forced command."); + } else { + authenticated = 0; + log("ROOT LOGIN REFUSED FROM %.200s", + get_canonical_hostname()); + } } /* Raise logging level */ From dzhao1 at gl.umbc.edu Fri Feb 18 02:35:18 2000 From: dzhao1 at gl.umbc.edu (Di Zhao) Date: Thu, 17 Feb 2000 10:35:18 -0500 Subject: Idle time out In-Reply-To: Message-ID: Thank you for the answer. But my telnet session has far longer time out than the ssh session. And when I check the Secure SSH, they do have such a IdelTimeout function. The KeepAlive doesn't have much to do with this case I am afraid. On Thu, 17 Feb 2000, Nigel Metheringham wrote: > > dzhao1 at gl.umbc.edu said: > > My ssh connection times out every 10 minutes or so and I want it to > > keep open for like 3 hours so that I don't have to relogin. > > This would normally be a function of the shell/utilties/policy on the > box you are logging into and nothing to do with ssh. > > There is a keep-alive function - this I understand is done by putting a > keep-alive on the socket used, and the timeouts cannot be easily > tweaked on OSes I use. > > Nigel. > -- > [ - Opinions expressed are personal and may not be shared by VData - ] > [ Nigel Metheringham Nigel.Metheringham at VData.co.uk ] > [ Phone: +44 1423 850000 Fax +44 1423 858866 ] > > -- "My grandpa told me to remember two things in life. Look out for Number One, and remember your number" - Orville Cogswell -- http://members.xoom.com/_XOOM/dizhao/index.html From markus.friedl at informatik.uni-erlangen.de Fri Feb 18 02:47:17 2000 From: markus.friedl at informatik.uni-erlangen.de (Markus Friedl) Date: Thu, 17 Feb 2000 16:47:17 +0100 Subject: Idle time out In-Reply-To: ; from dzhao1@gl.umbc.edu on Thu, Feb 17, 2000 at 10:35:18AM -0500 References: Message-ID: <20000217164717.A29352@folly.informatik.uni-erlangen.de> i don't understand what you want. how could a 'IdleTimeout' option make the ssh session last longer? OpenSSH does not log out idle users, so 'IdleTimeout' would be very useless. turn off 'KeepAlive' if you don't want TCP keep alive packets. On Thu, Feb 17, 2000 at 10:35:18AM -0500, Di Zhao wrote: > Thank you for the answer. But my telnet session has far longer time out > than the ssh session. And when I check the Secure SSH, they do have such a > IdelTimeout function. The KeepAlive doesn't have much to do with this case > I am afraid. From tech at mscs.mu.edu Fri Feb 18 04:02:44 2000 From: tech at mscs.mu.edu (MSCS Technician) Date: Thu, 17 Feb 2000 11:02:44 -0600 Subject: Problems building host keys on some SPARCs In-Reply-To: ; from MAILER-DAEMON@mscs.mu.edu on Wed, Feb 16, 2000 at 06:05:38PM -0000 Message-ID: <20000217110244.A748@studsys.mscs.mu.edu> Hi, I've compiled openssh 1.2.2 on Solaris 7/SPARC. On most hosts, things are fine. I get EGD going, compile openssh, and I can then generate hostkeys as described in the INSTALL file to get things running. On a few hosts though, the keygen fails like this: root at sylow:/source/USR_LOCAL/OFFICIAL/OPENSSH/ssh_client# ssh-keygen -b 1024 -f /etc/ssh/ssh_host_key -N '' ksh: ssh-keygen: cannot execute or fail like this: root at sylow:/source/USR_LOCAL/OFFICIAL/OPENSSH/ssh_client# cat build_host_key /usr/local/bin/ssh-keygen -b 1024 -f /etc/ssh/ssh_host_key -N '' root at sylow:/source/USR_LOCAL/OFFICIAL/OPENSSH/ssh_client# sh build_host_key /usr/local/bin/ssh-keygen: syntax error at line 1: `(' unexpected These same invokations work fine on most of our other systems. Info on the system above: root at sylow:/source/USR_LOCAL/OFFICIAL/OPENSSH/ssh_client# uname -a SunOS sylow 5.7 Generic_106541-07 sun4m sparc SUNW,SPARCstation-20 The only thing different I can see here is that the working systems are Ultra class machines, and the non-working ones are SparcStations. Any ideas? Thanks, -Robb From dzhao1 at gl.umbc.edu Fri Feb 18 05:47:38 2000 From: dzhao1 at gl.umbc.edu (Di Zhao) Date: Thu, 17 Feb 2000 13:47:38 -0500 Subject: Idle time out In-Reply-To: <20000217164717.A29352@folly.informatik.uni-erlangen.de> Message-ID: On Thu, 17 Feb 2000, Markus Friedl wrote: > i don't understand what you want. I want that, if I leave my ssh client for a while(2,3 hours), the sshd will still keep the connection, not like now, when I ssh to my server and leave, my ssh client always tell me (both client/serve are RH6.0) "Read from remote host my_ssh_server: Connection reset by peer" >From my network course, that should be the error message when the server send a RST packet to my client server. > > how could a 'IdleTimeout' option make the ssh session last longer? I figure that sshd must have some default value like 10 minutes, if there's not detected client activities going on for that time period, it will close the connection. > OpenSSH does not log out idle users, so 'IdleTimeout' would be > very useless. > > turn off 'KeepAlive' if you don't want TCP keep alive packets. I turned it off, but still get the same error message. > > On Thu, Feb 17, 2000 at 10:35:18AM -0500, Di Zhao wrote: > > Thank you for the answer. But my telnet session has far longer time out > > than the ssh session. And when I check the Secure SSH, they do have such a > > IdelTimeout function. The KeepAlive doesn't have much to do with this case > > I am afraid. > -- "My grandpa told me to remember two things in life. Look out for Number One, and remember your number" - Orville Cogswell -- http://members.xoom.com/_XOOM/dizhao/index.html From keld at dkuug.dk Fri Feb 18 10:10:52 2000 From: keld at dkuug.dk (Keld =?iso-8859-1?Q?J=F8rn?= Simonsen) Date: Fri, 18 Feb 2000 00:10:52 +0100 Subject: rpm 3.0.3 required Message-ID: <38AC7FFA.49B72D30@dkuug.dk> Hi! I was a bit puzzled when I tried to install openssh-server-1.2.2-1.i386.rpm on my redhat 6.0 system, it required rpm 3.0.3 - while I only have 3.0 Is it really necessary to require rpm 3.0.3 ? Keld Simonsen From djm at mindrot.org Fri Feb 18 11:19:24 2000 From: djm at mindrot.org (Damien Miller) Date: Fri, 18 Feb 2000 11:19:24 +1100 (EST) Subject: rpm 3.0.3 required In-Reply-To: <38AC7FFA.49B72D30@dkuug.dk> Message-ID: On Fri, 18 Feb 2000, Keld [iso-8859-1] J?rn Simonsen wrote: > Hi! > > I was a bit puzzled when I tried to install > openssh-server-1.2.2-1.i386.rpm on > my redhat 6.0 system, it required rpm 3.0.3 - while I only have 3.0 > > Is it really necessary to require rpm 3.0.3 ? Try rebuilding the SRPM. -d From ishikawa at yk.rim.or.jp Fri Feb 18 12:29:32 2000 From: ishikawa at yk.rim.or.jp (Ishikawa) Date: Fri, 18 Feb 2000 10:29:32 +0900 Subject: Problems building host keys on some SPARCs References: <20000217110244.A748@studsys.mscs.mu.edu> Message-ID: <38ACA07C.65ABB345@yk.rim.or.jp> Hi, MSCS Technician wrote: > Hi, > > I've compiled openssh 1.2.2 on Solaris 7/SPARC. On most hosts, things > are fine. I get EGD going, compile openssh, and I can then generate > hostkeys as described in the INSTALL file to get things running. > > On a few hosts though, the keygen fails like this: > > root at sylow:/source/USR_LOCAL/OFFICIAL/OPENSSH/ssh_client# ssh-keygen -b 1024 -f /etc/ssh/ssh_host_key -N '' > ksh: ssh-keygen: cannot execute > > or fail like this: > I suspect the above error could result from the use of "ssh-keygen" as opposed to "./ssh-keygen". Root should not have "." in its PATH setting. Looks that some of your hosts do have "." in root PATH and others don't. The next error message looks like one when I try to run binaries meant for a different OS. In your case, it is possible that you may have tried to run binary, meant for Solaris 2.x ( SunOS 5.x ) on Ultra, on SunOS 4.1.4 (or older?). When you type the command, the name of the executable file (mounted via NFS from Solaris host possibly) to the shell on SunOS 4.1.4. Then, the shell figures out it is not an object file since the newer ELF format is not known to it, and tries to run this as shell script, and we get the error. I have seen this message too many times to figure out the architecture mimsmatch immediately :-) (I used to have Sun, DEC and HP, but now stick to Sun, but we have SunOS 4.1.4 still running as well as later SunOS 5.x) If the above was the cause of your problem, you need to create a binary meant for SunOS 4.1.4 . That you mention the non-working ones are SparcStation makes me suspect this scenario. > root at sylow:/source/USR_LOCAL/OFFICIAL/OPENSSH/ssh_client# cat build_host_key > /usr/local/bin/ssh-keygen -b 1024 -f /etc/ssh/ssh_host_key -N '' > root at sylow:/source/USR_LOCAL/OFFICIAL/OPENSSH/ssh_client# sh build_host_key > /usr/local/bin/ssh-keygen: syntax error at line 1: `(' unexpected > > These same invokations work fine on most of our other systems. > > Info on the system above: > root at sylow:/source/USR_LOCAL/OFFICIAL/OPENSSH/ssh_client# uname -a > SunOS sylow 5.7 Generic_106541-07 sun4m sparc SUNW,SPARCstation-20 > > The only thing different I can see here is that the working systems > are Ultra class machines, and the non-working ones are SparcStations. > > Any ideas? > > Thanks, > > -Robb From nazark at register.com Fri Feb 18 12:45:28 2000 From: nazark at register.com (Nazar Kulynych) Date: Thu, 17 Feb 2000 20:45:28 -0500 Subject: ssh Error Message-ID: <00021720465600.08335@naz> ssh -l user host ssh_exchange_identification: read: Address already in use this is what I get when I try to login. what is it, what does it mean? Thanx From keld at dkuug.dk Sun Feb 20 06:21:13 2000 From: keld at dkuug.dk (=?iso-8859-1?Q?Keld_J=F8rn_Simonsen?=) Date: Sat, 19 Feb 2000 20:21:13 +0100 Subject: rpm 3.0.3 required In-Reply-To: ; from Damien Miller on Fri, Feb 18, 2000 at 11:19:24AM +1100 References: <38AC7FFA.49B72D30@dkuug.dk> Message-ID: <20000219202112.B1266@light.dkuug.dk> On Fri, Feb 18, 2000 at 11:19:24AM +1100, Damien Miller wrote: > On Fri, 18 Feb 2000, Keld [iso-8859-1] J?rn Simonsen wrote: > > > Hi! > > > > I was a bit puzzled when I tried to install > > openssh-server-1.2.2-1.i386.rpm on > > my redhat 6.0 system, it required rpm 3.0.3 - while I only have 3.0 > > > > Is it really necessary to require rpm 3.0.3 ? > > Try rebuilding the SRPM. Well, I could probably do a number of things to remedy this. But my point is that I would expect a number of other people having the same trouble, and it thus would be advisable for your project to pack the export files with a slightly less bleeding edge rpm, so that the binaries could be installed off-the-shelf on most systems. Else people have to install new rpm, or recompile it from sources or the like. Not so expedient. Kind regards Keld Simonsen From tech at mscs.mu.edu Sat Feb 19 02:09:13 2000 From: tech at mscs.mu.edu (MSCS Technician) Date: Fri, 18 Feb 2000 09:09:13 -0600 Subject: Problems building host keys on some SPARCs In-Reply-To: <38ACA07C.65ABB345@yk.rim.or.jp>; from ishikawa@yk.rim.or.jp on Fri, Feb 18, 2000 at 10:29:32AM +0900 References: <20000217110244.A748@studsys.mscs.mu.edu> <38ACA07C.65ABB345@yk.rim.or.jp> Message-ID: <20000218090913.A6764@studsys.mscs.mu.edu> Thanks for your response. Here's some new info. >> root at sylow:/source/USR_LOCAL/OFFICIAL/OPENSSH/ssh_client# ssh-keygen -b 1024 -f /etc/ssh/ssh_host_key -N '' >> ksh: ssh-keygen: cannot execute > I suspect the above error could result from > the use of "ssh-keygen" as opposed to "./ssh-keygen". > Root should not have "." in its PATH setting. Looks that some of your hosts > do have "." in root PATH and others don't. This appears to have been the result of the same problem others were having with scp. --with-default-path was needed to get that working properly. >> root at sylow:/source/USR_LOCAL/OFFICIAL/OPENSSH/ssh_client# sh build_host_key >> /usr/local/bin/ssh-keygen: syntax error at line 1: `(' unexpected > The next error message looks like one when I try to run > binaries meant for a different OS. > In your case, it is possible that you may have tried to run > binary, meant for Solaris 2.x ( SunOS 5.x ) on Ultra, on > SunOS 4.1.4 (or older?). The only problem with this hypothesis is that both machines, the working and the broken, run Solaris 7. I am trying to use a single set of executables NFS mounted. Recompiling it on the broken machines didn't help. They do have different kernel architectures: the ultras and enterprise servers that work are sun4u, the sparcstations that aren't working are sun4m. This wasn't a problem with the commercial ssh-1.2.27 though. As strange as it seems, is it possible there's something going on with sun4m only? Thanks, -Robb From dcato at crunchyfrog.net Fri Feb 18 17:39:47 2000 From: dcato at crunchyfrog.net (David Cato) Date: Fri, 18 Feb 2000 00:39:47 -0600 Subject: Idle time out Message-ID: <200002180639.AAA06197@ninkasi.crunchyfrog.net> Di Zhao wrote ... > I want that, if I leave my ssh client for a while(2,3 hours), the sshd > will still keep the connection, not like now, when I ssh to my server and > leave, my ssh client always tell me (both client/serve are RH6.0) > "Read from remote host my_ssh_server: Connection reset by peer" > >From my network course, that should be the error message when the server > send a RST packet to my client server. I've noticed the same timeout behavior as well, but only when connected from outside the local network. ssh connections between machines on the local network stay connected until I terminate them. However, when I connect from a remote network, the connection does get dropped after some amount of time. However, when this happened, I did not have any spare time to investigate, so I can't offer any further information at this time. FWIW, my ssh server is OpenBSD 2.6 with OpenSSH-1.2 while both ssh clients (local and remote) are Linux 2.2.x with OpenSSH-1.2.2. -- David Cato dcato at crunchyfrog.net From cnetzer at Stanford.EDU Fri Feb 18 13:20:39 2000 From: cnetzer at Stanford.EDU (Chad Netzer) Date: Thu, 17 Feb 2000 18:20:39 -0800 Subject: ssh Error In-Reply-To: <00021720465600.08335@naz>; from nazark@register.com on Thu, Feb 17, 2000 at 08:45:28PM -0500 References: <00021720465600.08335@naz> Message-ID: <20000217182039.A29@tree0.Stanford.EDU> On Thu, Feb 17, 2000 at 08:45:28PM -0500, Nazar Kulynych wrote: > ssh -l user host > ssh_exchange_identification: read: Address already in use > > this is what I get when I try to login. > what is it, what does it mean? This is the same as error as I got when the remote host was refusing "sshd" logins. The read() call fails in sshconnect.c with this (or wierder) messages. If the daemon was compiled with LIBWRAP, make sure it allows sshd (ie. if your hosts.deny is set to deny everything by default, you must enable sshd. Enabling rshd won't work in this case.) ie. (in /etc/hosts.allow): sshd : hostname.at.domain : ALLOW I brought this up recently, and this is another case of the strange diagnostic messages that occur due to using LIBWRAP. If I get time this weekend, I'll code and submit a patch to make the diagnostic a bit clearer. Chad Netzer cnetzer at stanford.edu From djm at mindrot.org Sun Feb 20 23:32:38 2000 From: djm at mindrot.org (Damien Miller) Date: Sun, 20 Feb 2000 23:32:38 +1100 (EST) Subject: rpm 3.0.3 required In-Reply-To: <20000219202112.B1266@light.dkuug.dk> Message-ID: On Sat, 19 Feb 2000, Keld J?rn Simonsen wrote: > Well, I could probably do a number of things to remedy this. > > But my point is that I would expect a number of other people > having the same trouble, and it thus would be advisable for > your project to pack the export files with a slightly less > bleeding edge rpm, so that the binaries could be installed > off-the-shelf on most systems. rpm-3.0.3 is the latest stable release of RPM for the current Redhat distribution. This is what the OpenSSH RPMs are built with. I don't expect the RPMs will work for everyone, the differences in PAM and glibc practically guarantee this. Please regard the binary RPMs as a convenience only. -d -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From jbarnett at axil.netmate.com Tue Feb 22 01:30:23 2000 From: jbarnett at axil.netmate.com (Jack Barnett) Date: Mon, 21 Feb 2000 08:30:23 -0600 Subject: OpenSSH doesn't compile under Solaris 2.3 Sparc Message-ID: <000701bf7c78$37be6e90$153046c6@inx.net> Hi, We are trying to get OpenSSH-1.2.2 stable release to compile under Solaris 2.3 Sparc. It worked perfect for Solaris 2.5, Solaris 2.5.1, Solaris 7 (All on Sparc) and Linux 2.2.13 Intel x86 OpenSSL installs fine without problem, zlib is installed fine without problems and egd.pl installs fine without problems. These are all the current releases, I can get the version numbers if you need them. egd.pl is started like so (and it is running when configure and make are run). /usr/local/bin/egd.pl /dev/random --hostname~/open/openssh-1.2.2 -->./configure --with-egd-pool /dev/random This runs and doesn't look like any real problems. --hostname~/open/openssh-1.2.2 -->make This runs for awhile and looks like it is working till ... gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROG RAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ssh/ss h-as kpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o bsd-snprintf.c: In function `getpagesize': bsd-snprintf.c:70: `NBPC' undeclared (first use this function) bsd-snprintf.c:70: (Each undeclared identifier is reported only once bsd-snprintf.c:70: for each function it appears in.) bsd-snprintf.c:73: warning: control reaches end of non-void function bsd-snprintf.c: In function `vsnprintf': bsd-snprintf.c:133: warning: variable `ret' might be clobbered by `longjmp' or ` vfork' bsd-snprintf.c: At top level: bsd-snprintf.c:52: warning: `caught' defined but not used make: *** [bsd-snprintf.o] Error 1 --hostname~/open/openssh-1.2.2 --> Any ideas? I think it has something to do with Solaris 2.3 since it worked fine for 2.5 and up. I am not sure how to get past this (I'm not a programmer) but would really like to get this going if possiable. If you want any output, files or want me to try something just shoot an email over (I am not subscribed to the list). Thanks, Jack jbarnett at ixc.net From andre.lucas at dial.pipex.com Tue Feb 22 02:22:24 2000 From: andre.lucas at dial.pipex.com (Andre Lucas) Date: Mon, 21 Feb 2000 15:22:24 +0000 Subject: OpenSSH doesn't compile under Solaris 2.3 Sparc References: <000701bf7c78$37be6e90$153046c6@inx.net> Message-ID: <38B15830.27F54CF1@dial.pipex.com> I'm surprised getpagesize(3C) isn't present. I wonder if it is just being missed by the tests, or if is it genuinely not there. Try 'man getpagesize' for starters. If there's no manpage, it's probably not there. Can you call 'sysconf(_SC_PAGESIZE)' - try 'man sysconf' and search for SC_PAGE - to get the system pagesize? I don't have a sol2.3 system to try for myself. Ta, -Andre Jack Barnett wrote: > > Hi, > > We are trying to get OpenSSH-1.2.2 stable release to compile under Solaris > 2.3 Sparc. It worked perfect for Solaris 2.5, Solaris 2.5.1, Solaris 7 (All > on Sparc) and Linux 2.2.13 Intel x86 > > OpenSSL installs fine without problem, zlib is installed fine without > problems and egd.pl installs fine without problems. These are all the > current releases, I can get the version numbers if you need them. > > egd.pl is started like so (and it is running when configure and make are > run). > > /usr/local/bin/egd.pl /dev/random > > --hostname~/open/openssh-1.2.2 -->./configure --with-egd-pool /dev/random > > This runs and doesn't look like any real problems. > > --hostname~/open/openssh-1.2.2 -->make > > This runs for awhile and looks like it is working till ... > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > PROG > RAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ssh/ss > h-as > kpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o > bsd-snprintf.c: In function `getpagesize': > bsd-snprintf.c:70: `NBPC' undeclared (first use this function) > bsd-snprintf.c:70: (Each undeclared identifier is reported only once > bsd-snprintf.c:70: for each function it appears in.) > bsd-snprintf.c:73: warning: control reaches end of non-void function > bsd-snprintf.c: In function `vsnprintf': > bsd-snprintf.c:133: warning: variable `ret' might be clobbered by `longjmp' > or ` > vfork' > bsd-snprintf.c: At top level: > bsd-snprintf.c:52: warning: `caught' defined but not used > make: *** [bsd-snprintf.o] Error 1 > --hostname~/open/openssh-1.2.2 --> > > Any ideas? I think it has something to do with Solaris 2.3 since it worked > fine for 2.5 and up. I am not sure how to get past this (I'm not a > programmer) but would really like to get this going if possiable. If you > want any output, files or want me to try something just shoot an email over > (I am not subscribed to the list). > > Thanks, > Jack > jbarnett at ixc.net From jbarnett at axil.netmate.com Tue Feb 22 03:07:57 2000 From: jbarnett at axil.netmate.com (Jack Barnett) Date: Mon, 21 Feb 2000 10:07:57 -0600 Subject: OpenSSH doesn't compile under Solaris 2.3 Sparc References: <000701bf7c78$37be6e90$153046c6@inx.net> <38B15830.27F54CF1@dial.pipex.com> Message-ID: <002601bf7c85$d353ead0$153046c6@inx.net> ----- Original Message ----- From: Andre Lucas To: Jack Barnett Cc: Sent: Monday, February 21, 2000 9:22 AM Subject: Re: OpenSSH doesn't compile under Solaris 2.3 Sparc > I'm surprised getpagesize(3C) isn't present. I wonder if it is just > being missed by the tests, or if is it genuinely not there. Try 'man > getpagesize' for starters. If there's no manpage, it's probably not > there. --inx-->man getpagesize Reformatting page. Wait... done getpagesize(SunOS/BSD Compatibility Library Functigetpagesize(3B) NAME getpagesize - get system page size It should be noted that it is tring to compile it under gcc version 2.7.2.1 GNU Make version 3.70 > > Can you call 'sysconf(_SC_PAGESIZE)' - try 'man sysconf' and search for > SC_PAGE - to get the system pagesize? I don't have a sol2.3 system to try for myself. --inx-->man sysconf Reformatting page. Wait... done sysconf(3C) C Library Functions sysconf(3C) NAME sysconf - get configurable system variables _SC_PAGESIZE PAGESIZE System memory page size > > Ta, > -Andre > > Jack Barnett wrote: > > > > Hi, > > > > We are trying to get OpenSSH-1.2.2 stable release to compile under Solaris > > 2.3 Sparc. It worked perfect for Solaris 2.5, Solaris 2.5.1, Solaris 7 (All > > on Sparc) and Linux 2.2.13 Intel x86 > > > > OpenSSL installs fine without problem, zlib is installed fine without > > problems and egd.pl installs fine without problems. These are all the > > current releases, I can get the version numbers if you need them. > > > > egd.pl is started like so (and it is running when configure and make are > > run). > > > > /usr/local/bin/egd.pl /dev/random > > > > --hostname~/open/openssh-1.2.2 -->./configure --with-egd-pool /dev/random > > > > This runs and doesn't look like any real problems. > > > > --hostname~/open/openssh-1.2.2 -->make > > > > This runs for awhile and looks like it is working till ... > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > PROG > > RAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ssh/ss > > h-as > > kpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o > > bsd-snprintf.c: In function `getpagesize': > > bsd-snprintf.c:70: `NBPC' undeclared (first use this function) > > bsd-snprintf.c:70: (Each undeclared identifier is reported only once > > bsd-snprintf.c:70: for each function it appears in.) > > bsd-snprintf.c:73: warning: control reaches end of non-void function > > bsd-snprintf.c: In function `vsnprintf': > > bsd-snprintf.c:133: warning: variable `ret' might be clobbered by `longjmp' > > or ` > > vfork' > > bsd-snprintf.c: At top level: > > bsd-snprintf.c:52: warning: `caught' defined but not used > > make: *** [bsd-snprintf.o] Error 1 > > --hostname~/open/openssh-1.2.2 --> > > > > Any ideas? I think it has something to do with Solaris 2.3 since it worked > > fine for 2.5 and up. I am not sure how to get past this (I'm not a > > programmer) but would really like to get this going if possiable. If you > > want any output, files or want me to try something just shoot an email over > > (I am not subscribed to the list). > > > > Thanks, > > Jack > > jbarnett at ixc.net > From ishikawa at yk.rim.or.jp Tue Feb 22 03:25:10 2000 From: ishikawa at yk.rim.or.jp (Ishikawa) Date: Tue, 22 Feb 2000 01:25:10 +0900 Subject: Problems building host keys on some SPARCs References: <20000217110244.A748@studsys.mscs.mu.edu> <38ACA07C.65ABB345@yk.rim.or.jp> <20000218090913.A6764@studsys.mscs.mu.edu> Message-ID: <38B166E6.CFB7E57C@yk.rim.or.jp> MSCS Technician wrote: > Thanks for your response. Here's some new info. > > >> root at sylow:/source/USR_LOCAL/OFFICIAL/OPENSSH/ssh_client# ssh-keygen -b 1024 -f /etc/ssh/ssh_host_key -N '' > >> ksh: ssh-keygen: cannot execute > > I suspect the above error could result from > > the use of "ssh-keygen" as opposed to "./ssh-keygen". > > Root should not have "." in its PATH setting. Looks that some of your hosts > > do have "." in root PATH and others don't. > > This appears to have been the result of the same problem others were > having with scp. --with-default-path was needed to get that working > properly. > Ok, I missed the possibility. > > >> root at sylow:/source/USR_LOCAL/OFFICIAL/OPENSSH/ssh_client# sh build_host_key > >> /usr/local/bin/ssh-keygen: syntax error at line 1: `(' unexpected > > The next error message looks like one when I try to run > > binaries meant for a different OS. > > In your case, it is possible that you may have tried to run > > binary, meant for Solaris 2.x ( SunOS 5.x ) on Ultra, on > > SunOS 4.1.4 (or older?). > > The only problem with this hypothesis is that both machines, the working > and the broken, run Solaris 7. > > I am trying to use a single set of executables NFS mounted. Recompiling > it on the broken machines didn't help. > I am surprised at this. I mean, in most of the cases I encountred it was possible to run open-source programs by - recompiling the program on the target architecture, and - making sure that the command searched is the right one (compiled for right-architecture, that is). Hmm... Something else might be to blame. Have you re-compiled the libraries, too? (Zlib and openssh comes to mind for starters.) > > They do have different kernel architectures: the ultras and enterprise > servers that work are sun4u, the sparcstations that aren't working are sun4m. > This wasn't a problem with the commercial ssh-1.2.27 though. > > As strange as it seems, is it possible there's something going on with > sun4m only? > I know that sun4m and sun4u are very different architecture, but usually it is only noticeable at the OS kernel-level and such architecture difference is more or less hidden behind system calls (except for the fact that some instructions are missing in sun4m and have to be emulated in software, and that the sun4m is sparc V8 architecuture and sun4u is v9.) I am at a loss to figure out the situation. I wonder what the output of the following command is. file /usr/local/bin/ssh-keygen Also, you might want to try sh -vx build_host_key in order to trace where the error occurs. From bent at clark.net Tue Feb 22 05:22:09 2000 From: bent at clark.net (Ben Taylor) Date: Mon, 21 Feb 2000 13:22:09 -0500 (EST) Subject: OpenSSH doesn't compile under Solaris 2.3 Sparc In-Reply-To: <002601bf7c85$d353ead0$153046c6@inx.net> Message-ID: On Mon, 21 Feb 2000, Jack Barnett wrote: If it's in the BSD compatibility libraries, you may have to link against the libaries in /usr/ucblib. Do a /usr/ccs/bin/nm on the libraries in /usr/ucblib and see if getpagesize pops out. If so, you'll need to add a -L/usr/ucblib to the end of the compile line so you don't end up with any other functions in that library. Hope this helps. Ben > ----- Original Message ----- > From: Andre Lucas > To: Jack Barnett > Cc: > Sent: Monday, February 21, 2000 9:22 AM > Subject: Re: OpenSSH doesn't compile under Solaris 2.3 Sparc > > > > I'm surprised getpagesize(3C) isn't present. I wonder if it is just > > being missed by the tests, or if is it genuinely not there. Try 'man > > getpagesize' for starters. If there's no manpage, it's probably not > > there. > > --inx-->man getpagesize > Reformatting page. Wait... done > > getpagesize(SunOS/BSD Compatibility Library Functigetpagesize(3B) > > NAME > getpagesize - get system page size > > > It should be noted that it is tring to compile it under > > gcc version 2.7.2.1 > GNU Make version 3.70 > > > > > Can you call 'sysconf(_SC_PAGESIZE)' - try 'man sysconf' and search for > > SC_PAGE - to get the system pagesize? I don't have a sol2.3 system to try > for myself. > > --inx-->man sysconf > Reformatting page. Wait... done > > sysconf(3C) C Library Functions sysconf(3C) > > NAME > sysconf - get configurable system variables > > > > _SC_PAGESIZE PAGESIZE System memory page size > > > > > > > > > > > Ta, > > -Andre > > > > Jack Barnett wrote: > > > > > > Hi, > > > > > > We are trying to get OpenSSH-1.2.2 stable release to compile under > Solaris > > > 2.3 Sparc. It worked perfect for Solaris 2.5, Solaris 2.5.1, Solaris 7 > (All > > > on Sparc) and Linux 2.2.13 Intel x86 > > > > > > OpenSSL installs fine without problem, zlib is installed fine without > > > problems and egd.pl installs fine without problems. These are all the > > > current releases, I can get the version numbers if you need them. > > > > > > egd.pl is started like so (and it is running when configure and make are > > > run). > > > > > > /usr/local/bin/egd.pl /dev/random > > > > > > --hostname~/open/openssh-1.2.2 -->./configure --with-egd-pool > /dev/random > > > > > > This runs and doesn't look like any real problems. > > > > > > --hostname~/open/openssh-1.2.2 -->make > > > > > > This runs for awhile and looks like it is working till ... > > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > PROG > > > > RAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ssh/ss > > > h-as > > > kpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o > > > bsd-snprintf.c: In function `getpagesize': > > > bsd-snprintf.c:70: `NBPC' undeclared (first use this function) > > > bsd-snprintf.c:70: (Each undeclared identifier is reported only once > > > bsd-snprintf.c:70: for each function it appears in.) > > > bsd-snprintf.c:73: warning: control reaches end of non-void function > > > bsd-snprintf.c: In function `vsnprintf': > > > bsd-snprintf.c:133: warning: variable `ret' might be clobbered by > `longjmp' > > > or ` > > > vfork' > > > bsd-snprintf.c: At top level: > > > bsd-snprintf.c:52: warning: `caught' defined but not used > > > make: *** [bsd-snprintf.o] Error 1 > > > --hostname~/open/openssh-1.2.2 --> > > > > > > Any ideas? I think it has something to do with Solaris 2.3 since it > worked > > > fine for 2.5 and up. I am not sure how to get past this (I'm not a > > > programmer) but would really like to get this going if possiable. If > you > > > want any output, files or want me to try something just shoot an email > over > > > (I am not subscribed to the list). > > > > > > Thanks, > > > Jack > > > jbarnett at ixc.net > > > > From jbarnett at axil.netmate.com Tue Feb 22 06:02:29 2000 From: jbarnett at axil.netmate.com (Jack Barnett) Date: Mon, 21 Feb 2000 13:02:29 -0600 Subject: OpenSSH doesn't compile under Solaris 2.3 Sparc References: Message-ID: <005e01bf7c9e$384164f0$153046c6@inx.net> ----- Original Message ----- From: Ben Taylor To: Jack Barnett Cc: Andre Lucas ; Sent: Monday, February 21, 2000 12:22 PM Subject: Re: OpenSSH doesn't compile under Solaris 2.3 Sparc > On Mon, 21 Feb 2000, Jack Barnett wrote: > > If it's in the BSD compatibility libraries, you may have to link > against the libaries in /usr/ucblib. Do a /usr/ccs/bin/nm on the > libraries in /usr/ucblib and see if getpagesize pops out. --host-->/usr/ccs/bin/nm /usr/ucblib/* | grep -i page Symbols from /usr/ucblib/libucb.a[getpagesize.o]: [1] | 0| 0|FILE |LOCL |0 |ABS |getpagesize.c [8] | 0| 16|FUNC |GLOB |0 |2 |getpagesize [136] | 0| 0|FILE |LOCL |0 |ABS |getpagesize.c [304] | 31132| 16|FUNC |GLOB |0 |8 |getpagesize [136] | 0| 0|FILE |LOCL |0 |ABS |getpagesize.c /usr/ccs/bin/nm: /usr/ucblib/llib-lcurses: invalid file type /usr/ccs/bin/nm: /usr/ucblib/llib-lcurses.ln: invalid file type /usr/ccs/bin/nm: /usr/ucblib/llib-ldbm: invalid file type /usr/ccs/bin/nm: /usr/ucblib/llib-ldbm.ln: invalid file type /usr/ccs/bin/nm: /usr/ucblib/llib-lrpcsoc: invalid file type /usr/ccs/bin/nm: /usr/ucblib/llib-lrpcsoc.ln: invalid file type /usr/ccs/bin/nm: /usr/ucblib/llib-ltermcap: invalid file type /usr/ccs/bin/nm: /usr/ucblib/llib-ltermcap.ln: invalid file type /usr/ccs/bin/nm: /usr/ucblib/llib-lucb: invalid file type /usr/ccs/bin/nm: /usr/ucblib/llib-lucb.ln: invalid file type /usr/ccs/bin/nm: /usr/ucblib/ucblinks.awk: invalid file type [304] | 31132| 16|FUNC |GLOB |0 |8 |getpagesize Looks like it is there. > If so, > you'll need to add a -L/usr/ucblib to the end of the compile line > so you don't end up with any other functions in that library. Ok you are going to have to slow down a bit, I am not a programmer. Passing that to ./configure or make breaks them with an error. If I ./configure like normal then edit the Makefile by hand it gives the error --host~/open/openssh-1.2.2 -->make Makefile:38: *** missing separator. Stop. Even if the only thing I do is open the file in vi or pico, hit enter, backspace then exist and save the file (Basically doing nothing but changing the modification date) it will trip the above error on me. I tried putting it under cflags and ldpath and it gives the same error. I don't know how I am supose to edit the file if the slightest thing causes it to barf. Any ideas? Thanks, Jack > > Hope this helps. > > Ben > > > ----- Original Message ----- > > From: Andre Lucas > > To: Jack Barnett > > Cc: > > Sent: Monday, February 21, 2000 9:22 AM > > Subject: Re: OpenSSH doesn't compile under Solaris 2.3 Sparc > > > > > > > I'm surprised getpagesize(3C) isn't present. I wonder if it is just > > > being missed by the tests, or if is it genuinely not there. Try 'man > > > getpagesize' for starters. If there's no manpage, it's probably not > > > there. > > > > --inx-->man getpagesize > > Reformatting page. Wait... done > > > > getpagesize(SunOS/BSD Compatibility Library Functigetpagesize(3B) > > > > NAME > > getpagesize - get system page size > > > > > > It should be noted that it is tring to compile it under > > > > gcc version 2.7.2.1 > > GNU Make version 3.70 > > > > > > > > Can you call 'sysconf(_SC_PAGESIZE)' - try 'man sysconf' and search for > > > SC_PAGE - to get the system pagesize? I don't have a sol2.3 system to try > > for myself. > > > > --inx-->man sysconf > > Reformatting page. Wait... done > > > > sysconf(3C) C Library Functions sysconf(3C) > > > > NAME > > sysconf - get configurable system variables > > > > > > > > _SC_PAGESIZE PAGESIZE System memory page size > > > > > > > > > > > > > > > > > > > > Ta, > > > -Andre > > > > > > Jack Barnett wrote: > > > > > > > > Hi, > > > > > > > > We are trying to get OpenSSH-1.2.2 stable release to compile under > > Solaris > > > > 2.3 Sparc. It worked perfect for Solaris 2.5, Solaris 2.5.1, Solaris 7 > > (All > > > > on Sparc) and Linux 2.2.13 Intel x86 > > > > > > > > OpenSSL installs fine without problem, zlib is installed fine without > > > > problems and egd.pl installs fine without problems. These are all the > > > > current releases, I can get the version numbers if you need them. > > > > > > > > egd.pl is started like so (and it is running when configure and make are > > > > run). > > > > > > > > /usr/local/bin/egd.pl /dev/random > > > > > > > > --hostname~/open/openssh-1.2.2 -->./configure --with-egd-pool > > /dev/random > > > > > > > > This runs and doesn't look like any real problems. > > > > > > > > --hostname~/open/openssh-1.2.2 -->make > > > > > > > > This runs for awhile and looks like it is working till ... > > > > > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROG > > > > > > RAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ssh/ss > > > > h-as > > > > kpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o > > > > bsd-snprintf.c: In function `getpagesize': > > > > bsd-snprintf.c:70: `NBPC' undeclared (first use this function) > > > > bsd-snprintf.c:70: (Each undeclared identifier is reported only once > > > > bsd-snprintf.c:70: for each function it appears in.) > > > > bsd-snprintf.c:73: warning: control reaches end of non-void function > > > > bsd-snprintf.c: In function `vsnprintf': > > > > bsd-snprintf.c:133: warning: variable `ret' might be clobbered by > > `longjmp' > > > > or ` > > > > vfork' > > > > bsd-snprintf.c: At top level: > > > > bsd-snprintf.c:52: warning: `caught' defined but not used > > > > make: *** [bsd-snprintf.o] Error 1 > > > > --hostname~/open/openssh-1.2.2 --> > > > > > > > > Any ideas? I think it has something to do with Solaris 2.3 since it > > worked > > > > fine for 2.5 and up. I am not sure how to get past this (I'm not a > > > > programmer) but would really like to get this going if possiable. If > > you > > > > want any output, files or want me to try something just shoot an email > > over > > > > (I am not subscribed to the list). > > > > > > > > Thanks, > > > > Jack > > > > jbarnett at ixc.net > > > > > > > > > From bent at clark.net Tue Feb 22 08:35:47 2000 From: bent at clark.net (Ben Taylor) Date: Mon, 21 Feb 2000 16:35:47 -0500 (EST) Subject: OpenSSH doesn't compile under Solaris 2.3 Sparc In-Reply-To: <005e01bf7c9e$384164f0$153046c6@inx.net> Message-ID: On Mon, 21 Feb 2000, Jack Barnett wrote: > > On Mon, 21 Feb 2000, Jack Barnett wrote: > > > > If it's in the BSD compatibility libraries, you may have to link > > against the libaries in /usr/ucblib. Do a /usr/ccs/bin/nm on the > > libraries in /usr/ucblib and see if getpagesize pops out. > > --host-->/usr/ccs/bin/nm /usr/ucblib/* | grep -i page > Symbols from /usr/ucblib/libucb.a[getpagesize.o]: > [1] | 0| 0|FILE |LOCL |0 |ABS |getpagesize.c > [8] | 0| 16|FUNC |GLOB |0 |2 |getpagesize > [136] | 0| 0|FILE |LOCL |0 |ABS |getpagesize.c > [304] | 31132| 16|FUNC |GLOB |0 |8 |getpagesize > [136] | 0| 0|FILE |LOCL |0 |ABS |getpagesize.c > > Looks like it is there. Yep. > > If so, > > you'll need to add a -L/usr/ucblib to the end of the compile line > > so you don't end up with any other functions in that library. > > Ok you are going to have to slow down a bit, I am not a programmer. Passing > that to ./configure or make breaks them with an error. If I ./configure > like normal then edit the Makefile by hand it gives the error try doing the configure with "env LDFLAGS="-L/usr/ucblib" ./configure ..." > --host~/open/openssh-1.2.2 -->make > Makefile:38: *** missing separator. Stop. > > Even if the only thing I do is open the file in vi or pico, hit enter, > backspace then exist and save the file (Basically doing nothing but changing > the modification date) it will trip the above error on me. I tried putting > it under cflags and ldpath and it gives the same error. I don't know how I > am supose to edit the file if the slightest thing causes it to barf. Weird. I've munged the Makefile before, and only problem I ever had was trying to build a Solaris package from the makefile. I gave up in frustration. Did you try adding "-L/usr/ucblib" to the end of the LDFLAGS in the Makefile. That should do it for you since I don't think there's a shared library version in the /usr/ucblib directory. Hope this helps. Ben > > Any ideas? > > Thanks, > Jack > > > > > Hope this helps. > > > > Ben > > > > > ----- Original Message ----- > > > From: Andre Lucas > > > To: Jack Barnett > > > Cc: > > > Sent: Monday, February 21, 2000 9:22 AM > > > Subject: Re: OpenSSH doesn't compile under Solaris 2.3 Sparc > > > > > > > > > > I'm surprised getpagesize(3C) isn't present. I wonder if it is just > > > > being missed by the tests, or if is it genuinely not there. Try 'man > > > > getpagesize' for starters. If there's no manpage, it's probably not > > > > there. > > > > > > --inx-->man getpagesize > > > Reformatting page. Wait... done > > > > > > getpagesize(SunOS/BSD Compatibility Library Functigetpagesize(3B) > > > > > > NAME > > > getpagesize - get system page size > > > > > > > > > It should be noted that it is tring to compile it under > > > > > > gcc version 2.7.2.1 > > > GNU Make version 3.70 > > > > > > > > > > > Can you call 'sysconf(_SC_PAGESIZE)' - try 'man sysconf' and search > for > > > > SC_PAGE - to get the system pagesize? I don't have a sol2.3 system to > try > > > for myself. > > > > > > --inx-->man sysconf > > > Reformatting page. Wait... done > > > > > > sysconf(3C) C Library Functions sysconf(3C) > > > > > > NAME > > > sysconf - get configurable system variables > > > > > > > > > > > > _SC_PAGESIZE PAGESIZE System memory page size > > > > > > > > > > > > > > > > > > > > > > > > > > > > > Ta, > > > > -Andre > > > > > > > > Jack Barnett wrote: > > > > > > > > > > Hi, > > > > > > > > > > We are trying to get OpenSSH-1.2.2 stable release to compile under > > > Solaris > > > > > 2.3 Sparc. It worked perfect for Solaris 2.5, Solaris 2.5.1, > Solaris 7 > > > (All > > > > > on Sparc) and Linux 2.2.13 Intel x86 > > > > > > > > > > OpenSSL installs fine without problem, zlib is installed fine > without > > > > > problems and egd.pl installs fine without problems. These are all > the > > > > > current releases, I can get the version numbers if you need them. > > > > > > > > > > egd.pl is started like so (and it is running when configure and make > are > > > > > run). > > > > > > > > > > /usr/local/bin/egd.pl /dev/random > > > > > > > > > > --hostname~/open/openssh-1.2.2 -->./configure --with-egd-pool > > > /dev/random > > > > > > > > > > This runs and doesn't look like any real problems. > > > > > > > > > > --hostname~/open/openssh-1.2.2 -->make > > > > > > > > > > This runs for awhile and looks like it is working till ... > > > > > > > > > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > PROG > > > > > > > > > RAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ssh/ss > > > > > h-as > > > > > kpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o > > > > > bsd-snprintf.c: In function `getpagesize': > > > > > bsd-snprintf.c:70: `NBPC' undeclared (first use this function) > > > > > bsd-snprintf.c:70: (Each undeclared identifier is reported only once > > > > > bsd-snprintf.c:70: for each function it appears in.) > > > > > bsd-snprintf.c:73: warning: control reaches end of non-void function > > > > > bsd-snprintf.c: In function `vsnprintf': > > > > > bsd-snprintf.c:133: warning: variable `ret' might be clobbered by > > > `longjmp' > > > > > or ` > > > > > vfork' > > > > > bsd-snprintf.c: At top level: > > > > > bsd-snprintf.c:52: warning: `caught' defined but not used > > > > > make: *** [bsd-snprintf.o] Error 1 > > > > > --hostname~/open/openssh-1.2.2 --> > > > > > > > > > > Any ideas? I think it has something to do with Solaris 2.3 since it > > > worked > > > > > fine for 2.5 and up. I am not sure how to get past this (I'm not a > > > > > programmer) but would really like to get this going if possiable. > If > > > you > > > > > want any output, files or want me to try something just shoot an > email > > > over > > > > > (I am not subscribed to the list). > > > > > > > > > > Thanks, > > > > > Jack > > > > > jbarnett at ixc.net > > > > > > > > > > > > > > > From lucas at dial.pipex.com Tue Feb 22 10:47:32 2000 From: lucas at dial.pipex.com (Andre Lucas) Date: Mon, 21 Feb 2000 23:47:32 +0000 Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) In-Reply-To: ; from bent@clark.net on Mon, Feb 21, 2000 at 04:35:47PM -0500 References: <005e01bf7c9e$384164f0$153046c6@inx.net> Message-ID: <20000221234732.A780@internal.domain> Attached is a patch that should make configure look in the bsd compat library for getpagesize(). [list note: I'm a little worried that we could potentially be adding "-lbsd" to LDFLAGS three times now :-) ] If you need help applying the patch: ungzip the patch file, change to your openssh source directory and do patch -p1 < unzipped-patch-filename Ta, -Andre -- Andre Lucas http://dspace.dial.pipex.com/andre.lucas/ -------------- next part -------------- A non-text attachment was scrubbed... Name: openssh-1.2.2-getpagesize.patch.gz Type: application/x-gunzip Size: 5111 bytes Desc: getpagesize() patch (gzipped) Url : http://lists.mindrot.org/pipermail/openssh-unix-dev/attachments/20000221/7e5cae81/attachment.bin From jbarnett at axil.netmate.com Wed Feb 23 00:50:48 2000 From: jbarnett at axil.netmate.com (Jack Barnett) Date: Tue, 22 Feb 2000 07:50:48 -0600 Subject: OpenSSH on Solaris 2.3 Sparc Warning allot of text References: Message-ID: <00aa01bf7d3c$559a2b60$153046c6@inx.net> ----- Original Message ----- From: Ben Taylor To: Jack Barnett Cc: Andre Lucas ; Sent: Monday, February 21, 2000 3:35 PM Subject: Re: OpenSSH doesn't compile under Solaris 2.3 Sparc > On Mon, 21 Feb 2000, Jack Barnett wrote: > > > > On Mon, 21 Feb 2000, Jack Barnett wrote: > > > > > > If it's in the BSD compatibility libraries, you may have to link > > > against the libaries in /usr/ucblib. Do a /usr/ccs/bin/nm on the > > > libraries in /usr/ucblib and see if getpagesize pops out. > > > > --host-->/usr/ccs/bin/nm /usr/ucblib/* | grep -i page > > Symbols from /usr/ucblib/libucb.a[getpagesize.o]: > > [1] | 0| 0|FILE |LOCL |0 |ABS |getpagesize.c > > [8] | 0| 16|FUNC |GLOB |0 |2 |getpagesize > > [136] | 0| 0|FILE |LOCL |0 |ABS |getpagesize.c > > [304] | 31132| 16|FUNC |GLOB |0 |8 |getpagesize > > [136] | 0| 0|FILE |LOCL |0 |ABS |getpagesize.c > > > > Looks like it is there. > > Yep. > > > > If so, > > > you'll need to add a -L/usr/ucblib to the end of the compile line > > > so you don't end up with any other functions in that library. > > > > Ok you are going to have to slow down a bit, I am not a programmer. Passing > > that to ./configure or make breaks them with an error. If I ./configure > > like normal then edit the Makefile by hand it gives the error > > try doing the configure with "env LDFLAGS="-L/usr/ucblib" ./configure ..." --host~/open/openssh-1.2.2 -->env LDFLAGS="-L/usr/ucblib" ./configure --with-tcp-wrappers --with-egd-pool=/dev/random creating cache ./config.cache checking host system type... sparc-sun-solaris2.3 checking for gcc... gcc checking whether the C compiler (gcc -L/usr/ucblib) works... yes checking whether the C compiler (gcc -L/usr/ucblib) is a cross-compiler... no checking whether we are using GNU C... yes checking whether gcc accepts -g... yes checking how to run the C preprocessor... gcc -E checking for ranlib... : checking for a BSD compatible install... ./install-sh -c checking for ar... ar checking for perl... /bin/perl checking for rsh... /bin/rsh checking for xauth... /usr/openwin/bin/xauth checking for inline... inline checking for OpenSSL/SSLeay directory... /usr/local/ssl checking for RSAref library... no checking for CRYPTO_lock in -lcrypto... yes checking for deflate in -lz... yes checking for login in -lutil... no checking for yp_match in -lnsl... yes checking for main in -lsocket... yes checking for bstring.h... no checking for endian.h... no checking for lastlog.h... yes checking for login.h... no checking for maillock.h... yes checking for netdb.h... yes checking for netgroup.h... no checking for paths.h... no checking for poll.h... yes checking for pty.h... no checking for shadow.h... yes checking for security/pam_appl.h... no checking for sys/bitypes.h... no checking for sys/bsdtty.h... no checking for sys/cdefs.h... no checking for sys/poll.h... yes checking for sys/select.h... yes checking for sys/stropts.h... yes checking for sys/sysmacros.h... yes checking for sys/time.h... yes checking for sys/ttcompat.h... yes checking for stddef.h... yes checking for util.h... no checking for utmp.h... yes checking for utmpx.h... yes checking for arc4random... no checking for bindresvport_af... no checking for freeaddrinfo... no checking for gai_strerror... no checking for getaddrinfo... no checking for getpagesize... no checking for getnameinfo... no checking for innetgr... yes checking for md5_crypt... no checking for mkdtemp... no checking for openpty... no checking for rresvport_af... no checking for setenv... no checking for seteuid... yes checking for setlogin... no checking for setproctitle... no checking for setreuid... no checking for snprintf... no checking for strlcat... no checking for strlcpy... no checking for updwtmpx... yes checking for vsnprintf... no checking for _getpty... no checking for login... no checking for login in -lbsd... no checking for daemon... no checking for daemon in -lbsd... no checking size of char... 1 checking size of short int... 2 checking size of int... 4 checking size of long int... 4 checking size of long long int... 8 checking for intXX_t types... no checking for u_intXX_t types... no checking for intXX_t and u_intXX_t types in sys/bitypes.h... no checking for uintXX_t types... no checking for socklen_t... no checking for size_t... yes checking for struct sockaddr_storage... no checking for struct sockaddr_in6... no checking for struct in6_addr... no checking for struct addrinfo... no checking whether to build GNOME ssh-askpass... no checking for /dev/urandom... no checking whether utmp.h has ut_host field... no checking whether utmpx.h has ut_host field... yes checking whether utmpx.h has syslen field... yes checking whether utmp.h has ut_pid field... yes checking whether utmp.h has ut_type field... yes checking whether utmp.h has ut_tv field... no checking whether utmp.h has ut_id field... yes checking whether utmp.h has ut_addr field... no checking whether utmpx.h has ut_addr field... no checking whether utmp.h has ut_addr_v6 field... no checking whether utmpx.h has ut_addr_v6 field... no checking whether struct sockaddr_storage has ss_family field... no checking whether struct sockaddr_storage has __ss_family field... no checking location of lastlog file... /var/adm/lastlog checking for /dev/ptmx... yes checking for /dev/ptc... no checking whether libc defines __progname... no updating cache ./config.cache creating ./config.status creating Makefile creating config.h --host~/open/openssh-1.2.2 -->make gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c atomicio.c -o atomicio.o gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c authfd.c -o authfd.o gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c authfile.c -o authfile.o authfile.c: In function `load_private_key': authfile.c:238: warning: unsigned int format, long unsigned int arg (arg 2) gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-bindresvport.c -o bsd-bindresvport.o gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-daemon.c -o bsd-daemon.o gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-misc.c -o bsd-misc.o gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-mktemp.c -o bsd-mktemp.o gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-rresvport.c -o bsd-rresvport.o bsd-rresvport.c: In function `rresvport_af': bsd-rresvport.c:66: warning: implicit declaration of function `bzero' gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o bsd-snprintf.c: In function `getpagesize': bsd-snprintf.c:70: `NBPC' undeclared (first use this function) bsd-snprintf.c:70: (Each undeclared identifier is reported only once bsd-snprintf.c:70: for each function it appears in.) bsd-snprintf.c:73: warning: control reaches end of non-void function bsd-snprintf.c: In function `vsnprintf': bsd-snprintf.c:133: warning: variable `ret' might be clobbered by `longjmp' or `vfork' bsd-snprintf.c: At top level: bsd-snprintf.c:52: warning: `caught' defined but not used make: *** [bsd-snprintf.o] Error 1 --host~/open/openssh-1.2.2 --> I posted the output to make sure there wasn't something else that could be effecting it. From what I can tell it looks find tell it hits the getpagesize. I also tried it without the --with-tcp-wrappers options and it did the same thing. Thanks, Jack > > > --host~/open/openssh-1.2.2 -->make > > Makefile:38: *** missing separator. Stop. > > > > Even if the only thing I do is open the file in vi or pico, hit enter, > > backspace then exist and save the file (Basically doing nothing but changing > > the modification date) it will trip the above error on me. I tried putting > > it under cflags and ldpath and it gives the same error. I don't know how I > > am supose to edit the file if the slightest thing causes it to barf. > > Weird. I've munged the Makefile before, and only problem I ever had was > trying to build a Solaris package from the makefile. I gave up in > frustration. > > Did you try adding "-L/usr/ucblib" to the end of the LDFLAGS in the > Makefile. That should do it for you since I don't think there's a shared > library version in the /usr/ucblib directory. > > Hope this helps. > > Ben > > > > > Any ideas? > > > > Thanks, > > Jack > > > > > > > > Hope this helps. > > > > > > Ben > > > > > > > ----- Original Message ----- > > > > From: Andre Lucas > > > > To: Jack Barnett > > > > Cc: > > > > Sent: Monday, February 21, 2000 9:22 AM > > > > Subject: Re: OpenSSH doesn't compile under Solaris 2.3 Sparc > > > > > > > > > > > > > I'm surprised getpagesize(3C) isn't present. I wonder if it is just > > > > > being missed by the tests, or if is it genuinely not there. Try 'man > > > > > getpagesize' for starters. If there's no manpage, it's probably not > > > > > there. > > > > > > > > --inx-->man getpagesize > > > > Reformatting page. Wait... done > > > > > > > > getpagesize(SunOS/BSD Compatibility Library Functigetpagesize(3B) > > > > > > > > NAME > > > > getpagesize - get system page size > > > > > > > > > > > > It should be noted that it is tring to compile it under > > > > > > > > gcc version 2.7.2.1 > > > > GNU Make version 3.70 > > > > > > > > > > > > > > Can you call 'sysconf(_SC_PAGESIZE)' - try 'man sysconf' and search > > for > > > > > SC_PAGE - to get the system pagesize? I don't have a sol2.3 system to > > try > > > > for myself. > > > > > > > > --inx-->man sysconf > > > > Reformatting page. Wait... done > > > > > > > > sysconf(3C) C Library Functions sysconf(3C) > > > > > > > > NAME > > > > sysconf - get configurable system variables > > > > > > > > > > > > > > > > _SC_PAGESIZE PAGESIZE System memory page size > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > Ta, > > > > > -Andre > > > > > > > > > > Jack Barnett wrote: > > > > > > > > > > > > Hi, > > > > > > > > > > > > We are trying to get OpenSSH-1.2.2 stable release to compile under > > > > Solaris > > > > > > 2.3 Sparc. It worked perfect for Solaris 2.5, Solaris 2.5.1, > > Solaris 7 > > > > (All > > > > > > on Sparc) and Linux 2.2.13 Intel x86 > > > > > > > > > > > > OpenSSL installs fine without problem, zlib is installed fine > > without > > > > > > problems and egd.pl installs fine without problems. These are all > > the > > > > > > current releases, I can get the version numbers if you need them. > > > > > > > > > > > > egd.pl is started like so (and it is running when configure and make > > are > > > > > > run). > > > > > > > > > > > > /usr/local/bin/egd.pl /dev/random > > > > > > > > > > > > --hostname~/open/openssh-1.2.2 -->./configure --with-egd-pool > > > > /dev/random > > > > > > > > > > > > This runs and doesn't look like any real problems. > > > > > > > > > > > > --hostname~/open/openssh-1.2.2 -->make > > > > > > > > > > > > This runs for awhile and looks like it is working till ... > > > > > > > > > > > > > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROG > > > > > > > > > > > > RAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ssh/ss > > > > > > h-as > > > > > > kpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o > > > > > > bsd-snprintf.c: In function `getpagesize': > > > > > > bsd-snprintf.c:70: `NBPC' undeclared (first use this function) > > > > > > bsd-snprintf.c:70: (Each undeclared identifier is reported only once > > > > > > bsd-snprintf.c:70: for each function it appears in.) > > > > > > bsd-snprintf.c:73: warning: control reaches end of non-void function > > > > > > bsd-snprintf.c: In function `vsnprintf': > > > > > > bsd-snprintf.c:133: warning: variable `ret' might be clobbered by > > > > `longjmp' > > > > > > or ` > > > > > > vfork' > > > > > > bsd-snprintf.c: At top level: > > > > > > bsd-snprintf.c:52: warning: `caught' defined but not used > > > > > > make: *** [bsd-snprintf.o] Error 1 > > > > > > --hostname~/open/openssh-1.2.2 --> > > > > > > > > > > > > Any ideas? I think it has something to do with Solaris 2.3 since it > > > > worked > > > > > > fine for 2.5 and up. I am not sure how to get past this (I'm not a > > > > > > programmer) but would really like to get this going if possiable. > > If > > > > you > > > > > > want any output, files or want me to try something just shoot an > > email > > > > over > > > > > > (I am not subscribed to the list). > > > > > > > > > > > > Thanks, > > > > > > Jack > > > > > > jbarnett at ixc.net > > > > > > > > > > > > > > > > > > > > > > > From jbarnett at axil.netmate.com Wed Feb 23 01:04:38 2000 From: jbarnett at axil.netmate.com (Jack Barnett) Date: Tue, 22 Feb 2000 08:04:38 -0600 Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) References: <005e01bf7c9e$384164f0$153046c6@inx.net> <20000221234732.A780@internal.domain> Message-ID: <00ab01bf7d3d$c4059340$153046c6@inx.net> ----- Original Message ----- From: Andre Lucas To: OpenSSH Unix Dev list Cc: Jack Barnett Sent: Monday, February 21, 2000 5:47 PM Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) > Attached is a patch that should make configure look in the bsd compat > library for getpagesize(). [list note: I'm a little worried that we could > potentially be adding "-lbsd" to LDFLAGS three times now :-) ] > > If you need help applying the patch: ungzip the patch file, change to > your openssh source directory and do > patch -p1 < unzipped-patch-filename > > Ta, > -Andre > > -- > Andre Lucas > http://dspace.dial.pipex.com/andre.lucas/ --hostname~/open/openssh-1.2.2 -->patch -p1 < openssh-1.2.2-getpagesize.patch Hmm... Looks like a unified diff to me... The text leading up to this was: -------------------------- |diff -Purd openssh-1.2.2/acconfig.h openssh-1.2.2.new/acconfig.h |--- openssh-1.2.2/acconfig.h Sat Jan 22 23:32:03 2000 |+++ openssh-1.2.2.new/acconfig.h Mon Feb 21 23:39:08 2000 -------------------------- Patching file acconfig.h using Plan A... Hunk #1 succeeded at 95. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |diff -Purd openssh-1.2.2/config.h.in openssh-1.2.2.new/config.h.in |--- openssh-1.2.2/config.h.in Thu Jan 27 03:17:05 2000 |+++ openssh-1.2.2.new/config.h.in Mon Feb 21 23:39:13 2000 -------------------------- Patching file config.h.in using Plan A... Hunk #1 succeeded at 89. Hunk #2 succeeded at 185. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |diff -Purd openssh-1.2.2/configure openssh-1.2.2.new/configure |--- openssh-1.2.2/configure Thu Jan 27 03:17:06 2000 |+++ openssh-1.2.2.new/configure Mon Feb 21 23:39:17 2000 -------------------------- Patching file configure using Plan A... Hunk #1 succeeded at 1655. Hunk #2 succeeded at 1903. Hunk #3 succeeded at 2010. Hunk #4 succeeded at 2021. Hunk #5 succeeded at 2041. Hunk #6 succeeded at 2049. Hunk #7 succeeded at 2060. Hunk #8 succeeded at 2080. Hunk #9 succeeded at 2088. Hunk #10 succeeded at 2099. Hunk #11 succeeded at 2119. Hunk #12 succeeded at 2127. Hunk #13 succeeded at 2138. Hunk #14 succeeded at 2158. Hunk #15 succeeded at 2166. Hunk #16 succeeded at 2177. Hunk #17 succeeded at 2198. Hunk #18 succeeded at 2227. Hunk #19 succeeded at 2259. Hunk #20 succeeded at 2273. Hunk #21 succeeded at 2297. Hunk #22 succeeded at 2325. Hunk #23 succeeded at 2337. Hunk #24 succeeded at 2356. Hunk #25 succeeded at 2384. Hunk #26 succeeded at 2396. Hunk #27 succeeded at 2415. Hunk #28 succeeded at 2443. Hunk #29 succeeded at 2471. Hunk #30 succeeded at 2484. Hunk #31 succeeded at 2520. Hunk #32 succeeded at 2528. Hunk #33 succeeded at 2539. Hunk #34 succeeded at 2568. Hunk #35 succeeded at 2580. Hunk #36 succeeded at 2600. Hunk #37 succeeded at 2636. Hunk #38 succeeded at 2695. Hunk #39 succeeded at 2716. Hunk #40 succeeded at 2737. Hunk #41 succeeded at 2758. Hunk #42 succeeded at 2779. Hunk #43 succeeded at 2800. Hunk #44 succeeded at 2821. Hunk #45 succeeded at 2842. Hunk #46 succeeded at 2863. Hunk #47 succeeded at 2884. Hunk #48 succeeded at 2905. Hunk #49 succeeded at 2927. Hunk #50 succeeded at 2939. Hunk #51 succeeded at 2957. Hunk #52 succeeded at 2969. Hunk #53 succeeded at 3006. Hunk #54 succeeded at 3061. Hunk #55 succeeded at 3069. Hunk #56 succeeded at 3080. Hunk #57 succeeded at 3123. Hunk #58 succeeded at 3131. Hunk #59 succeeded at 3142. Hunk #60 succeeded at 3185. Hunk #61 succeeded at 3193. Hunk #62 succeeded at 3204. Hunk #63 succeeded at 3261. Hunk #64 succeeded at 3290. Hunk #65 succeeded at 3317. Hunk #66 succeeded at 3365. Hunk #67 succeeded at 3402. Hunk #68 succeeded at 3410. Hunk #69 succeeded at 3453. Hunk #70 succeeded at 3461. Hunk #71 succeeded at 3472. Hmm... The next patch looks like a unified diff to me... The text leading up to this was: -------------------------- |diff -Purd openssh-1.2.2/configure.in openssh-1.2.2.new/configure.in |--- openssh-1.2.2/configure.in Wed Jan 26 01:15:31 2000 |+++ openssh-1.2.2.new/configure.in Mon Feb 21 23:38:09 2000 -------------------------- Patching file configure.in using Plan A... Hunk #1 succeeded at 157. Hunk #2 succeeded at 167. done --hostname~/open/openssh-1.2.2 -->./configure --with-tcp-wrappers --with-egd -pool=/dev/random No obvoius errors or warnings here --hostname~/open/openssh-1.2.2 -->make gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c atomicio.c -o atomicio.o gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c authfd.c -o authfd.o gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c authfile.c -o authfile.o authfile.c: In function `load_private_key': authfile.c:238: warning: unsigned int format, long unsigned int arg (arg 2) gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-bindresvport.c -o bsd-bindresvport.o gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-daemon.c -o bsd-daemon.o gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-misc.c -o bsd-misc.o gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-mktemp.c -o bsd-mktemp.o gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-rresvport.c -o bsd-rresvport.o bsd-rresvport.c: In function `rresvport_af': bsd-rresvport.c:66: warning: implicit declaration of function `bzero' gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o bsd-snprintf.c: In function `getpagesize': bsd-snprintf.c:70: `NBPC' undeclared (first use this function) bsd-snprintf.c:70: (Each undeclared identifier is reported only once bsd-snprintf.c:70: for each function it appears in.) bsd-snprintf.c:73: warning: control reaches end of non-void function bsd-snprintf.c: In function `vsnprintf': bsd-snprintf.c:133: warning: variable `ret' might be clobbered by `longjmp' or `vfork' bsd-snprintf.c: At top level: bsd-snprintf.c:52: warning: `caught' defined but not used make: *** [bsd-snprintf.o] Error 1 I won't post the entire output in the furture. Thanks, Jack From charvel at link.pl Wed Feb 23 01:17:48 2000 From: charvel at link.pl (Piotr Majka) Date: Tue, 22 Feb 2000 15:17:48 +0100 (CET) Subject: 1.2.2 + glibc 2.1.3 Message-ID: Hi :) Yes, _I known_ that is a devel glibc version but all of my others daemon works fine, eventual will be rebuild, and all works fine, but not openssh - compiling without errors, but when I try run.. [root at link /root]# /usr/sbin/opensshd BUG IN DYNAMIC LINKER ld.so: dynamic-link.h: 57: elf_get_dynamic_info: Assertion `! "bad dynamic tag"' failed! [root at link /root]# [root at link /root]# ldd /usr/sbin/opensshd BUG IN DYNAMIC LINKER ld.so: dynamic-link.h: 57: elf_get_dynamic_info: Assertion `! "bad dynamic tag"' failed! ldd: /lib/ld-linux.so.2 exited with unknown exit code (127) [root at link /root]# Interesting matters ;) -- Piotr "Charvel" Majka | PGP & GPG Public Key: finger charvel at link.pl | Uin: 20873695 GCM d- s-:- a-- C++ UL++++ P+ L+++ E--- W+ N+++ !o !K w--- !O M V- PS+ PE !Y PGP+ t--- !5 X R tv- b !DI D+ G++ e h r y++** From drankin at bohemians.lexington.ky.us Wed Feb 23 01:17:03 2000 From: drankin at bohemians.lexington.ky.us (David Rankin) Date: Tue, 22 Feb 2000 09:17:03 -0500 Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) In-Reply-To: <00ab01bf7d3d$c4059340$153046c6@inx.net>; from Jack Barnett on Tue, Feb 22, 2000 at 08:04:38AM -0600 References: <005e01bf7c9e$384164f0$153046c6@inx.net> <20000221234732.A780@internal.domain> <00ab01bf7d3d$c4059340$153046c6@inx.net> Message-ID: <20000222091703.A269@rumpole.bohemians.lexington.ky.us> > ----- Original Message ----- > From: Andre Lucas > To: OpenSSH Unix Dev list > Cc: Jack Barnett > Sent: Monday, February 21, 2000 5:47 PM > Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) > > > Attached is a patch that should make configure look in the bsd compat > > library for getpagesize(). [list note: I'm a little worried that we could > > potentially be adding "-lbsd" to LDFLAGS three times now :-) ] If we are worried about this, the easy answer would be to add a variable like "USE_LIBBSD" to configure.in, set it to one each positive test (and leave it alone for negative tests), and then add -lbsd to LDFLAGS iff USE_LIBBSD is 1. Of course, this only matters if we really, really care about the library getting referenced more than once. I doubt that we really care. David -- David W. Rankin, Jr. Husband, Father, and UNIX Sysadmin. Email: drankin at bohemians.lexington.ky.us Address/Phone Number: Ask me. "It's too bad she won't live! But then again, who does?" -- Gaff, _Blade Runner_ From bent at clark.net Wed Feb 23 01:49:10 2000 From: bent at clark.net (Ben Taylor) Date: Tue, 22 Feb 2000 09:49:10 -0500 (EST) Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) In-Reply-To: <00ab01bf7d3d$c4059340$153046c6@inx.net> Message-ID: On Tue, 22 Feb 2000, Jack Barnett wrote: > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o > bsd-snprintf.c: In function `getpagesize': > bsd-snprintf.c:70: `NBPC' undeclared (first use this function) > bsd-snprintf.c:70: (Each undeclared identifier is reported only once > bsd-snprintf.c:70: for each function it appears in.) > bsd-snprintf.c:73: warning: control reaches end of non-void function > bsd-snprintf.c: In function `vsnprintf': > bsd-snprintf.c:133: warning: variable `ret' might be clobbered by `longjmp' > or `vfork' > bsd-snprintf.c: At top level: > bsd-snprintf.c:52: warning: `caught' defined but not used > make: *** [bsd-snprintf.o] Error 1 This is a bit weird. It still looks like HAVE_GETPAGESIZE is still not getting set, because it's entering the code for the "replacement" getpagesize. NBPC is defined in /usr/include/sys/param.h in Solaris 2.5.1, but I have the suspicion, it's not defined in Solaris 2.3. At least not in /usr/include/sys/param.h. I'd bet that those defines are probably somewhere down in /usr/ucbinclude. Given that, we could either use the getpagesize call from Solaris 2.3, or check for the define NBPC. Either way, this should get us a working version in Solaris 2.3. Try a 'find /usr/ucbinclude -exec egrep "NBPC|getpagesize" {} /dev/null \;' and see what you come up with. The information you return will probably help us fix the problem. Ben From andre.lucas at dial.pipex.com Wed Feb 23 03:16:13 2000 From: andre.lucas at dial.pipex.com (Andre Lucas) Date: Tue, 22 Feb 2000 16:16:13 +0000 Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) References: <005e01bf7c9e$384164f0$153046c6@inx.net> <20000221234732.A780@internal.domain> <00ab01bf7d3d$c4059340$153046c6@inx.net> Message-ID: <38B2B64D.2AA91606@dial.pipex.com> Before I dig in further with this: You did do 'make distclean' and rerun configure before retrying the make? -Andr? Jack Barnett wrote: > > ----- Original Message ----- > From: Andre Lucas > To: OpenSSH Unix Dev list > Cc: Jack Barnett > Sent: Monday, February 21, 2000 5:47 PM > Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) > > > Attached is a patch that should make configure look in the bsd compat > > library for getpagesize(). [list note: I'm a little worried that we could > > potentially be adding "-lbsd" to LDFLAGS three times now :-) ] > > > > If you need help applying the patch: ungzip the patch file, change to > > your openssh source directory and do > > patch -p1 < unzipped-patch-filename > > > > Ta, > > -Andre > > > > -- > > Andre Lucas > > http://dspace.dial.pipex.com/andre.lucas/ > > --hostname~/open/openssh-1.2.2 -->patch -p1 < > openssh-1.2.2-getpagesize.patch > Hmm... Looks like a unified diff to me... > The text leading up to this was: > -------------------------- > |diff -Purd openssh-1.2.2/acconfig.h openssh-1.2.2.new/acconfig.h > |--- openssh-1.2.2/acconfig.h Sat Jan 22 23:32:03 2000 > |+++ openssh-1.2.2.new/acconfig.h Mon Feb 21 23:39:08 2000 > -------------------------- > Patching file acconfig.h using Plan A... > Hunk #1 succeeded at 95. > Hmm... The next patch looks like a unified diff to me... > The text leading up to this was: > -------------------------- > |diff -Purd openssh-1.2.2/config.h.in openssh-1.2.2.new/config.h.in > |--- openssh-1.2.2/config.h.in Thu Jan 27 03:17:05 2000 > |+++ openssh-1.2.2.new/config.h.in Mon Feb 21 23:39:13 2000 > -------------------------- > Patching file config.h.in using Plan A... > Hunk #1 succeeded at 89. > Hunk #2 succeeded at 185. > Hmm... The next patch looks like a unified diff to me... > The text leading up to this was: > -------------------------- > |diff -Purd openssh-1.2.2/configure openssh-1.2.2.new/configure > |--- openssh-1.2.2/configure Thu Jan 27 03:17:06 2000 > |+++ openssh-1.2.2.new/configure Mon Feb 21 23:39:17 2000 > -------------------------- > Patching file configure using Plan A... > Hunk #1 succeeded at 1655. > Hunk #2 succeeded at 1903. > Hunk #3 succeeded at 2010. > Hunk #4 succeeded at 2021. > Hunk #5 succeeded at 2041. > Hunk #6 succeeded at 2049. > Hunk #7 succeeded at 2060. > Hunk #8 succeeded at 2080. > Hunk #9 succeeded at 2088. > Hunk #10 succeeded at 2099. > Hunk #11 succeeded at 2119. > Hunk #12 succeeded at 2127. > Hunk #13 succeeded at 2138. > Hunk #14 succeeded at 2158. > Hunk #15 succeeded at 2166. > Hunk #16 succeeded at 2177. > Hunk #17 succeeded at 2198. > Hunk #18 succeeded at 2227. > Hunk #19 succeeded at 2259. > Hunk #20 succeeded at 2273. > Hunk #21 succeeded at 2297. > Hunk #22 succeeded at 2325. > Hunk #23 succeeded at 2337. > Hunk #24 succeeded at 2356. > Hunk #25 succeeded at 2384. > Hunk #26 succeeded at 2396. > Hunk #27 succeeded at 2415. > Hunk #28 succeeded at 2443. > Hunk #29 succeeded at 2471. > Hunk #30 succeeded at 2484. > Hunk #31 succeeded at 2520. > Hunk #32 succeeded at 2528. > Hunk #33 succeeded at 2539. > Hunk #34 succeeded at 2568. > Hunk #35 succeeded at 2580. > Hunk #36 succeeded at 2600. > Hunk #37 succeeded at 2636. > Hunk #38 succeeded at 2695. > Hunk #39 succeeded at 2716. > Hunk #40 succeeded at 2737. > Hunk #41 succeeded at 2758. > Hunk #42 succeeded at 2779. > Hunk #43 succeeded at 2800. > Hunk #44 succeeded at 2821. > Hunk #45 succeeded at 2842. > Hunk #46 succeeded at 2863. > Hunk #47 succeeded at 2884. > Hunk #48 succeeded at 2905. > Hunk #49 succeeded at 2927. > Hunk #50 succeeded at 2939. > Hunk #51 succeeded at 2957. > Hunk #52 succeeded at 2969. > Hunk #53 succeeded at 3006. > Hunk #54 succeeded at 3061. > Hunk #55 succeeded at 3069. > Hunk #56 succeeded at 3080. > Hunk #57 succeeded at 3123. > Hunk #58 succeeded at 3131. > Hunk #59 succeeded at 3142. > Hunk #60 succeeded at 3185. > Hunk #61 succeeded at 3193. > Hunk #62 succeeded at 3204. > Hunk #63 succeeded at 3261. > Hunk #64 succeeded at 3290. > Hunk #65 succeeded at 3317. > Hunk #66 succeeded at 3365. > Hunk #67 succeeded at 3402. > Hunk #68 succeeded at 3410. > Hunk #69 succeeded at 3453. > Hunk #70 succeeded at 3461. > Hunk #71 succeeded at 3472. > Hmm... The next patch looks like a unified diff to me... > The text leading up to this was: > -------------------------- > |diff -Purd openssh-1.2.2/configure.in openssh-1.2.2.new/configure.in > |--- openssh-1.2.2/configure.in Wed Jan 26 01:15:31 2000 > |+++ openssh-1.2.2.new/configure.in Mon Feb 21 23:38:09 2000 > -------------------------- > Patching file configure.in using Plan A... > Hunk #1 succeeded at 157. > Hunk #2 succeeded at 167. > done > > --hostname~/open/openssh-1.2.2 -->./configure --with-tcp-wrappers --with-egd > -pool=/dev/random > > No obvoius errors or warnings here > > --hostname~/open/openssh-1.2.2 -->make > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > h/ssh-askpass\" -DHAVE_CONFIG_H -c atomicio.c -o atomicio.o > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > h/ssh-askpass\" -DHAVE_CONFIG_H -c authfd.c -o authfd.o > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > h/ssh-askpass\" -DHAVE_CONFIG_H -c authfile.c -o authfile.o > authfile.c: In function `load_private_key': > authfile.c:238: warning: unsigned int format, long unsigned int arg (arg 2) > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-bindresvport.c -o > bsd-bindresvport.o > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-daemon.c -o bsd-daemon.o > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-misc.c -o bsd-misc.o > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-mktemp.c -o bsd-mktemp.o > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-rresvport.c -o bsd-rresvport.o > bsd-rresvport.c: In function `rresvport_af': > bsd-rresvport.c:66: warning: implicit declaration of function `bzero' > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o > bsd-snprintf.c: In function `getpagesize': > bsd-snprintf.c:70: `NBPC' undeclared (first use this function) > bsd-snprintf.c:70: (Each undeclared identifier is reported only once > bsd-snprintf.c:70: for each function it appears in.) > bsd-snprintf.c:73: warning: control reaches end of non-void function > bsd-snprintf.c: In function `vsnprintf': > bsd-snprintf.c:133: warning: variable `ret' might be clobbered by `longjmp' > or `vfork' > bsd-snprintf.c: At top level: > bsd-snprintf.c:52: warning: `caught' defined but not used > make: *** [bsd-snprintf.o] Error 1 > > I won't post the entire output in the furture. > > Thanks, > Jack From jbarnett at axil.netmate.com Thu Feb 24 00:04:21 2000 From: jbarnett at axil.netmate.com (Jack Barnett) Date: Wed, 23 Feb 2000 07:04:21 -0600 Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) References: <005e01bf7c9e$384164f0$153046c6@inx.net> <20000221234732.A780@internal.domain> <00ab01bf7d3d$c4059340$153046c6@inx.net> <38B2B64D.2AA91606@dial.pipex.com> Message-ID: <006901bf7dfe$81b98ed0$153046c6@inx.net> Do you guys have any other suggestions? I am not on the list so I may be missing something. Thanks, Jack ----- Original Message ----- From: Andre Lucas To: Jack Barnett Cc: Andre Lucas ; OpenSSH Unix Dev list Sent: Tuesday, February 22, 2000 10:16 AM Subject: Re: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) > Before I dig in further with this: You did do 'make distclean' and rerun > configure before retrying the make? > > -Andr? > > Jack Barnett wrote: > > > > ----- Original Message ----- > > From: Andre Lucas > > To: OpenSSH Unix Dev list > > Cc: Jack Barnett > > Sent: Monday, February 21, 2000 5:47 PM > > Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) > > > > > Attached is a patch that should make configure look in the bsd compat > > > library for getpagesize(). [list note: I'm a little worried that we could > > > potentially be adding "-lbsd" to LDFLAGS three times now :-) ] > > > > > > If you need help applying the patch: ungzip the patch file, change to > > > your openssh source directory and do > > > patch -p1 < unzipped-patch-filename > > > > > > Ta, > > > -Andre > > > > > > -- > > > Andre Lucas > > > http://dspace.dial.pipex.com/andre.lucas/ > > > > --hostname~/open/openssh-1.2.2 -->patch -p1 < > > openssh-1.2.2-getpagesize.patch > > Hmm... Looks like a unified diff to me... > > The text leading up to this was: > > -------------------------- > > |diff -Purd openssh-1.2.2/acconfig.h openssh-1.2.2.new/acconfig.h > > |--- openssh-1.2.2/acconfig.h Sat Jan 22 23:32:03 2000 > > |+++ openssh-1.2.2.new/acconfig.h Mon Feb 21 23:39:08 2000 > > -------------------------- > > Patching file acconfig.h using Plan A... > > Hunk #1 succeeded at 95. > > Hmm... The next patch looks like a unified diff to me... > > The text leading up to this was: > > -------------------------- > > |diff -Purd openssh-1.2.2/config.h.in openssh-1.2.2.new/config.h.in > > |--- openssh-1.2.2/config.h.in Thu Jan 27 03:17:05 2000 > > |+++ openssh-1.2.2.new/config.h.in Mon Feb 21 23:39:13 2000 > > -------------------------- > > Patching file config.h.in using Plan A... > > Hunk #1 succeeded at 89. > > Hunk #2 succeeded at 185. > > Hmm... The next patch looks like a unified diff to me... > > The text leading up to this was: > > -------------------------- > > |diff -Purd openssh-1.2.2/configure openssh-1.2.2.new/configure > > |--- openssh-1.2.2/configure Thu Jan 27 03:17:06 2000 > > |+++ openssh-1.2.2.new/configure Mon Feb 21 23:39:17 2000 > > -------------------------- > > Patching file configure using Plan A... > > Hunk #1 succeeded at 1655. > > Hunk #2 succeeded at 1903. > > Hunk #3 succeeded at 2010. > > Hunk #4 succeeded at 2021. > > Hunk #5 succeeded at 2041. > > Hunk #6 succeeded at 2049. > > Hunk #7 succeeded at 2060. > > Hunk #8 succeeded at 2080. > > Hunk #9 succeeded at 2088. > > Hunk #10 succeeded at 2099. > > Hunk #11 succeeded at 2119. > > Hunk #12 succeeded at 2127. > > Hunk #13 succeeded at 2138. > > Hunk #14 succeeded at 2158. > > Hunk #15 succeeded at 2166. > > Hunk #16 succeeded at 2177. > > Hunk #17 succeeded at 2198. > > Hunk #18 succeeded at 2227. > > Hunk #19 succeeded at 2259. > > Hunk #20 succeeded at 2273. > > Hunk #21 succeeded at 2297. > > Hunk #22 succeeded at 2325. > > Hunk #23 succeeded at 2337. > > Hunk #24 succeeded at 2356. > > Hunk #25 succeeded at 2384. > > Hunk #26 succeeded at 2396. > > Hunk #27 succeeded at 2415. > > Hunk #28 succeeded at 2443. > > Hunk #29 succeeded at 2471. > > Hunk #30 succeeded at 2484. > > Hunk #31 succeeded at 2520. > > Hunk #32 succeeded at 2528. > > Hunk #33 succeeded at 2539. > > Hunk #34 succeeded at 2568. > > Hunk #35 succeeded at 2580. > > Hunk #36 succeeded at 2600. > > Hunk #37 succeeded at 2636. > > Hunk #38 succeeded at 2695. > > Hunk #39 succeeded at 2716. > > Hunk #40 succeeded at 2737. > > Hunk #41 succeeded at 2758. > > Hunk #42 succeeded at 2779. > > Hunk #43 succeeded at 2800. > > Hunk #44 succeeded at 2821. > > Hunk #45 succeeded at 2842. > > Hunk #46 succeeded at 2863. > > Hunk #47 succeeded at 2884. > > Hunk #48 succeeded at 2905. > > Hunk #49 succeeded at 2927. > > Hunk #50 succeeded at 2939. > > Hunk #51 succeeded at 2957. > > Hunk #52 succeeded at 2969. > > Hunk #53 succeeded at 3006. > > Hunk #54 succeeded at 3061. > > Hunk #55 succeeded at 3069. > > Hunk #56 succeeded at 3080. > > Hunk #57 succeeded at 3123. > > Hunk #58 succeeded at 3131. > > Hunk #59 succeeded at 3142. > > Hunk #60 succeeded at 3185. > > Hunk #61 succeeded at 3193. > > Hunk #62 succeeded at 3204. > > Hunk #63 succeeded at 3261. > > Hunk #64 succeeded at 3290. > > Hunk #65 succeeded at 3317. > > Hunk #66 succeeded at 3365. > > Hunk #67 succeeded at 3402. > > Hunk #68 succeeded at 3410. > > Hunk #69 succeeded at 3453. > > Hunk #70 succeeded at 3461. > > Hunk #71 succeeded at 3472. > > Hmm... The next patch looks like a unified diff to me... > > The text leading up to this was: > > -------------------------- > > |diff -Purd openssh-1.2.2/configure.in openssh-1.2.2.new/configure.in > > |--- openssh-1.2.2/configure.in Wed Jan 26 01:15:31 2000 > > |+++ openssh-1.2.2.new/configure.in Mon Feb 21 23:38:09 2000 > > -------------------------- > > Patching file configure.in using Plan A... > > Hunk #1 succeeded at 157. > > Hunk #2 succeeded at 167. > > done > > > > --hostname~/open/openssh-1.2.2 -->./configure --with-tcp-wrappers --with-e gd > > -pool=/dev/random > > > > No obvoius errors or warnings here > > > > --hostname~/open/openssh-1.2.2 -->make > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > h/ssh-askpass\" -DHAVE_CONFIG_H -c atomicio.c -o atomicio.o > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > h/ssh-askpass\" -DHAVE_CONFIG_H -c authfd.c -o authfd.o > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > h/ssh-askpass\" -DHAVE_CONFIG_H -c authfile.c -o authfile.o > > authfile.c: In function `load_private_key': > > authfile.c:238: warning: unsigned int format, long unsigned int arg (arg 2) > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-bindresvport.c -o > > bsd-bindresvport.o > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-daemon.c -o bsd-daemon.o > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-misc.c -o bsd-misc.o > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-mktemp.c -o bsd-mktemp.o > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-rresvport.c -o bsd-rresvport.o > > bsd-rresvport.c: In function `rresvport_af': > > bsd-rresvport.c:66: warning: implicit declaration of function `bzero' > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o > > bsd-snprintf.c: In function `getpagesize': > > bsd-snprintf.c:70: `NBPC' undeclared (first use this function) > > bsd-snprintf.c:70: (Each undeclared identifier is reported only once > > bsd-snprintf.c:70: for each function it appears in.) > > bsd-snprintf.c:73: warning: control reaches end of non-void function > > bsd-snprintf.c: In function `vsnprintf': > > bsd-snprintf.c:133: warning: variable `ret' might be clobbered by `longjmp' > > or `vfork' > > bsd-snprintf.c: At top level: > > bsd-snprintf.c:52: warning: `caught' defined but not used > > make: *** [bsd-snprintf.o] Error 1 > > > > I won't post the entire output in the furture. > > > > Thanks, > > Jack > From andre.lucas at dial.pipex.com Thu Feb 24 00:56:15 2000 From: andre.lucas at dial.pipex.com (Andre Lucas) Date: Wed, 23 Feb 2000 13:56:15 +0000 Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) References: <005e01bf7c9e$384164f0$153046c6@inx.net> <20000221234732.A780@internal.domain> <00ab01bf7d3d$c4059340$153046c6@inx.net> <38B2B64D.2AA91606@dial.pipex.com> <006901bf7dfe$81b98ed0$153046c6@inx.net> Message-ID: <38B3E6FF.7BB96A03@dial.pipex.com> The patch should have made configure look in the bsd library for getpagesize(), and when it found it set a macro in config.h. I don't understand why it hasn't done so. Would you mind sending a copy of your config.h, after you've run configure on the patched version? I think you may have sent this already (I'm at work now, the email I use here is my home address), if so then please send it just to me rather than to the list. Same for the output from ./configure after the patch. Thanks, -Andr? Jack Barnett wrote: > > Do you guys have any other suggestions? I am not on the list so I may be > missing something. > > Thanks, > Jack > > ----- Original Message ----- > From: Andre Lucas > To: Jack Barnett > Cc: Andre Lucas ; OpenSSH Unix Dev list > > Sent: Tuesday, February 22, 2000 10:16 AM > Subject: Re: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) > > > Before I dig in further with this: You did do 'make distclean' and rerun > > configure before retrying the make? > > > > -Andr? > > > > Jack Barnett wrote: > > > > > > ----- Original Message ----- > > > From: Andre Lucas > > > To: OpenSSH Unix Dev list > > > Cc: Jack Barnett > > > Sent: Monday, February 21, 2000 5:47 PM > > > Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) > > > > > > > Attached is a patch that should make configure look in the bsd compat > > > > library for getpagesize(). [list note: I'm a little worried that we > could > > > > potentially be adding "-lbsd" to LDFLAGS three times now :-) ] > > > > > > > > If you need help applying the patch: ungzip the patch file, change to > > > > your openssh source directory and do > > > > patch -p1 < unzipped-patch-filename > > > > > > > > Ta, > > > > -Andre > > > > > > > > -- > > > > Andre Lucas > > > > http://dspace.dial.pipex.com/andre.lucas/ > > > > > > --hostname~/open/openssh-1.2.2 -->patch -p1 < > > > openssh-1.2.2-getpagesize.patch > > > Hmm... Looks like a unified diff to me... > > > The text leading up to this was: > > > -------------------------- > > > |diff -Purd openssh-1.2.2/acconfig.h openssh-1.2.2.new/acconfig.h > > > |--- openssh-1.2.2/acconfig.h Sat Jan 22 23:32:03 2000 > > > |+++ openssh-1.2.2.new/acconfig.h Mon Feb 21 23:39:08 2000 > > > -------------------------- > > > Patching file acconfig.h using Plan A... > > > Hunk #1 succeeded at 95. > > > Hmm... The next patch looks like a unified diff to me... > > > The text leading up to this was: > > > -------------------------- > > > |diff -Purd openssh-1.2.2/config.h.in openssh-1.2.2.new/config.h.in > > > |--- openssh-1.2.2/config.h.in Thu Jan 27 03:17:05 2000 > > > |+++ openssh-1.2.2.new/config.h.in Mon Feb 21 23:39:13 2000 > > > -------------------------- > > > Patching file config.h.in using Plan A... > > > Hunk #1 succeeded at 89. > > > Hunk #2 succeeded at 185. > > > Hmm... The next patch looks like a unified diff to me... > > > The text leading up to this was: > > > -------------------------- > > > |diff -Purd openssh-1.2.2/configure openssh-1.2.2.new/configure > > > |--- openssh-1.2.2/configure Thu Jan 27 03:17:06 2000 > > > |+++ openssh-1.2.2.new/configure Mon Feb 21 23:39:17 2000 > > > -------------------------- > > > Patching file configure using Plan A... > > > Hunk #1 succeeded at 1655. > > > Hunk #2 succeeded at 1903. > > > Hunk #3 succeeded at 2010. > > > Hunk #4 succeeded at 2021. > > > Hunk #5 succeeded at 2041. > > > Hunk #6 succeeded at 2049. > > > Hunk #7 succeeded at 2060. > > > Hunk #8 succeeded at 2080. > > > Hunk #9 succeeded at 2088. > > > Hunk #10 succeeded at 2099. > > > Hunk #11 succeeded at 2119. > > > Hunk #12 succeeded at 2127. > > > Hunk #13 succeeded at 2138. > > > Hunk #14 succeeded at 2158. > > > Hunk #15 succeeded at 2166. > > > Hunk #16 succeeded at 2177. > > > Hunk #17 succeeded at 2198. > > > Hunk #18 succeeded at 2227. > > > Hunk #19 succeeded at 2259. > > > Hunk #20 succeeded at 2273. > > > Hunk #21 succeeded at 2297. > > > Hunk #22 succeeded at 2325. > > > Hunk #23 succeeded at 2337. > > > Hunk #24 succeeded at 2356. > > > Hunk #25 succeeded at 2384. > > > Hunk #26 succeeded at 2396. > > > Hunk #27 succeeded at 2415. > > > Hunk #28 succeeded at 2443. > > > Hunk #29 succeeded at 2471. > > > Hunk #30 succeeded at 2484. > > > Hunk #31 succeeded at 2520. > > > Hunk #32 succeeded at 2528. > > > Hunk #33 succeeded at 2539. > > > Hunk #34 succeeded at 2568. > > > Hunk #35 succeeded at 2580. > > > Hunk #36 succeeded at 2600. > > > Hunk #37 succeeded at 2636. > > > Hunk #38 succeeded at 2695. > > > Hunk #39 succeeded at 2716. > > > Hunk #40 succeeded at 2737. > > > Hunk #41 succeeded at 2758. > > > Hunk #42 succeeded at 2779. > > > Hunk #43 succeeded at 2800. > > > Hunk #44 succeeded at 2821. > > > Hunk #45 succeeded at 2842. > > > Hunk #46 succeeded at 2863. > > > Hunk #47 succeeded at 2884. > > > Hunk #48 succeeded at 2905. > > > Hunk #49 succeeded at 2927. > > > Hunk #50 succeeded at 2939. > > > Hunk #51 succeeded at 2957. > > > Hunk #52 succeeded at 2969. > > > Hunk #53 succeeded at 3006. > > > Hunk #54 succeeded at 3061. > > > Hunk #55 succeeded at 3069. > > > Hunk #56 succeeded at 3080. > > > Hunk #57 succeeded at 3123. > > > Hunk #58 succeeded at 3131. > > > Hunk #59 succeeded at 3142. > > > Hunk #60 succeeded at 3185. > > > Hunk #61 succeeded at 3193. > > > Hunk #62 succeeded at 3204. > > > Hunk #63 succeeded at 3261. > > > Hunk #64 succeeded at 3290. > > > Hunk #65 succeeded at 3317. > > > Hunk #66 succeeded at 3365. > > > Hunk #67 succeeded at 3402. > > > Hunk #68 succeeded at 3410. > > > Hunk #69 succeeded at 3453. > > > Hunk #70 succeeded at 3461. > > > Hunk #71 succeeded at 3472. > > > Hmm... The next patch looks like a unified diff to me... > > > The text leading up to this was: > > > -------------------------- > > > |diff -Purd openssh-1.2.2/configure.in openssh-1.2.2.new/configure.in > > > |--- openssh-1.2.2/configure.in Wed Jan 26 01:15:31 2000 > > > |+++ openssh-1.2.2.new/configure.in Mon Feb 21 23:38:09 2000 > > > -------------------------- > > > Patching file configure.in using Plan A... > > > Hunk #1 succeeded at 157. > > > Hunk #2 succeeded at 167. > > > done > > > > > > > --hostname~/open/openssh-1.2.2 -->./configure --with-tcp-wrappers --with-e > gd > > > -pool=/dev/random > > > > > > No obvoius errors or warnings here > > > > > > --hostname~/open/openssh-1.2.2 -->make > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c atomicio.c -o atomicio.o > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c authfd.c -o authfd.o > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c authfile.c -o authfile.o > > > authfile.c: In function `load_private_key': > > > authfile.c:238: warning: unsigned int format, long unsigned int arg (arg > 2) > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-bindresvport.c -o > > > bsd-bindresvport.o > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-daemon.c -o bsd-daemon.o > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-misc.c -o bsd-misc.o > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-mktemp.c -o bsd-mktemp.o > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-rresvport.c -o bsd-rresvport.o > > > bsd-rresvport.c: In function `rresvport_af': > > > bsd-rresvport.c:66: warning: implicit declaration of function `bzero' > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o > > > bsd-snprintf.c: In function `getpagesize': > > > bsd-snprintf.c:70: `NBPC' undeclared (first use this function) > > > bsd-snprintf.c:70: (Each undeclared identifier is reported only once > > > bsd-snprintf.c:70: for each function it appears in.) > > > bsd-snprintf.c:73: warning: control reaches end of non-void function > > > bsd-snprintf.c: In function `vsnprintf': > > > bsd-snprintf.c:133: warning: variable `ret' might be clobbered by > `longjmp' > > > or `vfork' > > > bsd-snprintf.c: At top level: > > > bsd-snprintf.c:52: warning: `caught' defined but not used > > > make: *** [bsd-snprintf.o] Error 1 > > > > > > I won't post the entire output in the furture. > > > > > > Thanks, > > > Jack > > From S.Pacut at gazeta.pl Thu Feb 24 01:55:59 2000 From: S.Pacut at gazeta.pl (Szczepan Pacut) Date: Wed, 23 Feb 2000 15:55:59 +0100 Subject: ssh, pam & radius Message-ID: <38B3F4FF.C727D59A@gazeta.pl> Hello! I would like to setup ssh on solaris7/x86 to use PAM authentication by pam_radius_auth. Neither openssh-1.2.2 nor ssh-1.2.27 with ssh-1.2.27.pam.patch work with it - I've got message: debug: RSA authentication for test failed. On remete radius server I've information in logs that authentication was accepted(!). When I connect by telnet all is right. My /etc/pam.conf: login auth sufficient /usr/lib/security/pam_radius_auth.so.1 login auth required /usr/lib/security/pam_unix.so.1 login auth required /usr/lib/security/pam_dial_auth.so.1 telnet auth sufficient /usr/lib/security/pam_radius_auth.so.1 telnet auth required /usr/lib/security/pam_unix.so.1 ssh auth required /usr/lib/security/pam_radius_auth.so.1 rlogin auth sufficient /usr/lib/security/pam_rhosts_auth.so.1 rlogin auth required /usr/lib/security/pam_unix.so.1 dtlogin auth required /usr/lib/security/pam_unix.so.1 rsh auth required /usr/lib/security/pam_rhosts_auth.so.1 other auth required /usr/lib/security/pam_unix.so.1 login account required /usr/lib/security/pam_unix.so.1 dtlogin account required /usr/lib/security/pam_unix.so.1 other account required /usr/lib/security/pam_unix.so.1 other session required /usr/lib/security/pam_unix.so.1 Any help will be appreciated. Regards -- ____ ____ Szczepan Pacut http://www.ia.pw.edu.pl/~spacut / __)| \ Telecommunication Department of Agora SA \__ \| _/ email: S.Pacut at gazeta.pl (____/|_| ICQ 22551352 From andre.lucas at dial.pipex.com Thu Feb 24 02:38:09 2000 From: andre.lucas at dial.pipex.com (Andre Lucas) Date: Wed, 23 Feb 2000 15:38:09 +0000 Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) References: <005e01bf7c9e$384164f0$153046c6@inx.net> <20000221234732.A780@internal.domain> <00ab01bf7d3d$c4059340$153046c6@inx.net> <38B2B64D.2AA91606@dial.pipex.com> <006901bf7dfe$81b98ed0$153046c6@inx.net> Message-ID: <38B3FEE1.606E0DF3@dial.pipex.com> Thanks for the files. The mistake is mine, I was looking in -lbsd when the function is in /usr/ucblib/libucb.a . Had I referred back to the nm output you provided before, I'd have seen that. Doh. All: It appears /usr/ucblib isn't in the library search path on Sol2.3, so we want to be linking against /usr/ucblib/libucb.a instead of .so . The only way I know to specify that I want specifically a static link is to name the file on the command line, i.e. LIBS="$LIBS /usr/ucblib/libucb.a". Does anyone know a better way? In any case, I'll put up a new patch later when I get home. I hope that will sort this out. In the meantime, you may have some luck hacking it with this: make distclean LIBS="/usr/ucblib/libucb.a" ./configure which should sub in the required library for you. Ta, -Andr? Jack Barnett wrote: > > Do you guys have any other suggestions? I am not on the list so I may be > missing something. > > Thanks, > Jack > > ----- Original Message ----- > From: Andre Lucas > To: Jack Barnett > Cc: Andre Lucas ; OpenSSH Unix Dev list > > Sent: Tuesday, February 22, 2000 10:16 AM > Subject: Re: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) > > > Before I dig in further with this: You did do 'make distclean' and rerun > > configure before retrying the make? > > > > -Andr? > > > > Jack Barnett wrote: > > > > > > ----- Original Message ----- > > > From: Andre Lucas > > > To: OpenSSH Unix Dev list > > > Cc: Jack Barnett > > > Sent: Monday, February 21, 2000 5:47 PM > > > Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) > > > > > > > Attached is a patch that should make configure look in the bsd compat > > > > library for getpagesize(). [list note: I'm a little worried that we > could > > > > potentially be adding "-lbsd" to LDFLAGS three times now :-) ] > > > > > > > > If you need help applying the patch: ungzip the patch file, change to > > > > your openssh source directory and do > > > > patch -p1 < unzipped-patch-filename > > > > > > > > Ta, > > > > -Andre > > > > > > > > -- > > > > Andre Lucas > > > > http://dspace.dial.pipex.com/andre.lucas/ > > > > > > --hostname~/open/openssh-1.2.2 -->patch -p1 < > > > openssh-1.2.2-getpagesize.patch > > > Hmm... Looks like a unified diff to me... > > > The text leading up to this was: > > > -------------------------- > > > |diff -Purd openssh-1.2.2/acconfig.h openssh-1.2.2.new/acconfig.h > > > |--- openssh-1.2.2/acconfig.h Sat Jan 22 23:32:03 2000 > > > |+++ openssh-1.2.2.new/acconfig.h Mon Feb 21 23:39:08 2000 > > > -------------------------- > > > Patching file acconfig.h using Plan A... > > > Hunk #1 succeeded at 95. > > > Hmm... The next patch looks like a unified diff to me... > > > The text leading up to this was: > > > -------------------------- > > > |diff -Purd openssh-1.2.2/config.h.in openssh-1.2.2.new/config.h.in > > > |--- openssh-1.2.2/config.h.in Thu Jan 27 03:17:05 2000 > > > |+++ openssh-1.2.2.new/config.h.in Mon Feb 21 23:39:13 2000 > > > -------------------------- > > > Patching file config.h.in using Plan A... > > > Hunk #1 succeeded at 89. > > > Hunk #2 succeeded at 185. > > > Hmm... The next patch looks like a unified diff to me... > > > The text leading up to this was: > > > -------------------------- > > > |diff -Purd openssh-1.2.2/configure openssh-1.2.2.new/configure > > > |--- openssh-1.2.2/configure Thu Jan 27 03:17:06 2000 > > > |+++ openssh-1.2.2.new/configure Mon Feb 21 23:39:17 2000 > > > -------------------------- > > > Patching file configure using Plan A... > > > Hunk #1 succeeded at 1655. > > > Hunk #2 succeeded at 1903. > > > Hunk #3 succeeded at 2010. > > > Hunk #4 succeeded at 2021. > > > Hunk #5 succeeded at 2041. > > > Hunk #6 succeeded at 2049. > > > Hunk #7 succeeded at 2060. > > > Hunk #8 succeeded at 2080. > > > Hunk #9 succeeded at 2088. > > > Hunk #10 succeeded at 2099. > > > Hunk #11 succeeded at 2119. > > > Hunk #12 succeeded at 2127. > > > Hunk #13 succeeded at 2138. > > > Hunk #14 succeeded at 2158. > > > Hunk #15 succeeded at 2166. > > > Hunk #16 succeeded at 2177. > > > Hunk #17 succeeded at 2198. > > > Hunk #18 succeeded at 2227. > > > Hunk #19 succeeded at 2259. > > > Hunk #20 succeeded at 2273. > > > Hunk #21 succeeded at 2297. > > > Hunk #22 succeeded at 2325. > > > Hunk #23 succeeded at 2337. > > > Hunk #24 succeeded at 2356. > > > Hunk #25 succeeded at 2384. > > > Hunk #26 succeeded at 2396. > > > Hunk #27 succeeded at 2415. > > > Hunk #28 succeeded at 2443. > > > Hunk #29 succeeded at 2471. > > > Hunk #30 succeeded at 2484. > > > Hunk #31 succeeded at 2520. > > > Hunk #32 succeeded at 2528. > > > Hunk #33 succeeded at 2539. > > > Hunk #34 succeeded at 2568. > > > Hunk #35 succeeded at 2580. > > > Hunk #36 succeeded at 2600. > > > Hunk #37 succeeded at 2636. > > > Hunk #38 succeeded at 2695. > > > Hunk #39 succeeded at 2716. > > > Hunk #40 succeeded at 2737. > > > Hunk #41 succeeded at 2758. > > > Hunk #42 succeeded at 2779. > > > Hunk #43 succeeded at 2800. > > > Hunk #44 succeeded at 2821. > > > Hunk #45 succeeded at 2842. > > > Hunk #46 succeeded at 2863. > > > Hunk #47 succeeded at 2884. > > > Hunk #48 succeeded at 2905. > > > Hunk #49 succeeded at 2927. > > > Hunk #50 succeeded at 2939. > > > Hunk #51 succeeded at 2957. > > > Hunk #52 succeeded at 2969. > > > Hunk #53 succeeded at 3006. > > > Hunk #54 succeeded at 3061. > > > Hunk #55 succeeded at 3069. > > > Hunk #56 succeeded at 3080. > > > Hunk #57 succeeded at 3123. > > > Hunk #58 succeeded at 3131. > > > Hunk #59 succeeded at 3142. > > > Hunk #60 succeeded at 3185. > > > Hunk #61 succeeded at 3193. > > > Hunk #62 succeeded at 3204. > > > Hunk #63 succeeded at 3261. > > > Hunk #64 succeeded at 3290. > > > Hunk #65 succeeded at 3317. > > > Hunk #66 succeeded at 3365. > > > Hunk #67 succeeded at 3402. > > > Hunk #68 succeeded at 3410. > > > Hunk #69 succeeded at 3453. > > > Hunk #70 succeeded at 3461. > > > Hunk #71 succeeded at 3472. > > > Hmm... The next patch looks like a unified diff to me... > > > The text leading up to this was: > > > -------------------------- > > > |diff -Purd openssh-1.2.2/configure.in openssh-1.2.2.new/configure.in > > > |--- openssh-1.2.2/configure.in Wed Jan 26 01:15:31 2000 > > > |+++ openssh-1.2.2.new/configure.in Mon Feb 21 23:38:09 2000 > > > -------------------------- > > > Patching file configure.in using Plan A... > > > Hunk #1 succeeded at 157. > > > Hunk #2 succeeded at 167. > > > done > > > > > > > --hostname~/open/openssh-1.2.2 -->./configure --with-tcp-wrappers --with-e > gd > > > -pool=/dev/random > > > > > > No obvoius errors or warnings here > > > > > > --hostname~/open/openssh-1.2.2 -->make > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c atomicio.c -o atomicio.o > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c authfd.c -o authfd.o > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c authfile.c -o authfile.o > > > authfile.c: In function `load_private_key': > > > authfile.c:238: warning: unsigned int format, long unsigned int arg (arg > 2) > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-bindresvport.c -o > > > bsd-bindresvport.o > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-daemon.c -o bsd-daemon.o > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-misc.c -o bsd-misc.o > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-mktemp.c -o bsd-mktemp.o > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-rresvport.c -o bsd-rresvport.o > > > bsd-rresvport.c: In function `rresvport_af': > > > bsd-rresvport.c:66: warning: implicit declaration of function `bzero' > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o > > > bsd-snprintf.c: In function `getpagesize': > > > bsd-snprintf.c:70: `NBPC' undeclared (first use this function) > > > bsd-snprintf.c:70: (Each undeclared identifier is reported only once > > > bsd-snprintf.c:70: for each function it appears in.) > > > bsd-snprintf.c:73: warning: control reaches end of non-void function > > > bsd-snprintf.c: In function `vsnprintf': > > > bsd-snprintf.c:133: warning: variable `ret' might be clobbered by > `longjmp' > > > or `vfork' > > > bsd-snprintf.c: At top level: > > > bsd-snprintf.c:52: warning: `caught' defined but not used > > > make: *** [bsd-snprintf.o] Error 1 > > > > > > I won't post the entire output in the furture. > > > > > > Thanks, > > > Jack > > From jmknoble at pobox.com Thu Feb 24 17:55:48 2000 From: jmknoble at pobox.com (Jim Knoble) Date: Thu, 24 Feb 2000 01:55:48 -0500 Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) In-Reply-To: <38B3FEE1.606E0DF3@dial.pipex.com>; from Andre Lucas on Wed, Feb 23, 2000 at 03:38:09PM +0000 References: <005e01bf7c9e$384164f0$153046c6@inx.net> <20000221234732.A780@internal.domain> <00ab01bf7d3d$c4059340$153046c6@inx.net> <38B2B64D.2AA91606@dial.pipex.com> <006901bf7dfe$81b98ed0$153046c6@inx.net> <38B3FEE1.606E0DF3@dial.pipex.com> Message-ID: <20000224015548.B690@quipu.earth> P? 2000-Feb-23 klokka 15:38:09 +0000 skrivet Andre Lucas: : All: It appears /usr/ucblib isn't in the library search path on Sol2.3, : so we want to be linking against /usr/ucblib/libucb.a instead of .so . : The only way I know to specify that I want specifically a static link is : to name the file on the command line, i.e. LIBS="$LIBS : /usr/ucblib/libucb.a". Does anyone know a better way? That's the best way i'm aware of to link with a combination of static and shared libraries. -- jim knoble jmknoble at pobox.com From nebulous at owlnet.rice.edu Thu Feb 24 18:10:59 2000 From: nebulous at owlnet.rice.edu (Sean Aaron Lisse) Date: Thu, 24 Feb 2000 01:10:59 -0600 (CST) Subject: SSL devel. model In-Reply-To: <20000224015548.B690@quipu.earth> Message-ID: As an exercise (final project) for my computer security class, I'm planning on implementing an NFS-like extension to OpenSSH that will automatically "mount" the remote machine's filesystem in a subset of the current directory (thus giving even more 'transparency' to the interface and eliminating much of the need to use scp back and forth). My partner is planning on altering OpenSSH such that it can do SSL-type third-party authentication, instead of relying on the first-contact setup that is currently in place. We were also planning on implementing some interesting things such as PAM, but (to our chagrin) we found that you folks had already gotten there first. :) My reason for posting this is threefold: A) I would like any comments that you folks have on the ideas above. (Yes, "that's a stupid idea and no-one would use it" is a valid comment as well-- it tells us that we may want to change what we're doing) B) I've been looking through the code and listening to the list for a little while now, and I've noticed mentions of RSA and SSL, but I haven't found any evidence of a trusted third-party authentication scheme. Third-party is the only version of RSA/SSL that I (in my admittedly quite limited cryptography knowledge) have heard of, but from what I can glean from the code, OpenSSH does some type of two-party RSA authentication. Any light? C) I'm trolling for volunteers that I can email when my team gets -really- stuck (and no, I don't mean that I'll email at the first sign of trouble, this will probably be limited to maybe one or two cries of 'heeeelp' during the semester). Are there any brave souls out there? Thanks for your help and support. Of course, if any of the code that I/we develop actually seems to be of use to the project, it'll happily be handed over... -Sean Lisse, Rice University Computer Science class of 2000 (Somehow I feel that I should include a public key of some sort here... :P) From bartl at ss1000.ms.mff.cuni.cz Thu Feb 24 19:06:28 2000 From: bartl at ss1000.ms.mff.cuni.cz (David Bartl) Date: Thu, 24 Feb 2000 09:06:28 +0100 (MET) Subject: A problem with PATH in sshd.c Message-ID: Dear Sirs, on my Linux (distribution Slackware 3.9), I have installed the ``openssh-1.2.2.tar.gz'' package into the /usr/local/bin directory. In the ``sshd.c'' file, the PATH variable is set up: child_set_env(&env, &envsize, "PATH", _PATH_STDPATH); (line no. 2405). I am unable to connect to my machine using scp. _PATH_STDPATH is "/usr/bin:/bin:/usr/sbin:/sbin", but the scp program dwells in /usr/local/bin. If I try to connect, enter password (etc., all OK), then the shell reports it could not find the scp command (not in PATH) and the connection is closed... IMHO, an ordinary user does not need to have "/usr/sbin:/sbin" in his/her PATH. IMHO, the PATH variable should be set to _PATH_DEFPATH, which is "/usr/local/bin:/usr/bin:/bin": child_set_env(&env, &envsize, "PATH", _PATH_DEFPATH); I have changed it, recompiled the sshd and everything works fine. Yours faithfully David Bartl From jmknoble at pobox.com Thu Feb 24 19:56:00 2000 From: jmknoble at pobox.com (Jim Knoble) Date: Thu, 24 Feb 2000 03:56:00 -0500 Subject: A problem with PATH in sshd.c In-Reply-To: ; from David Bartl on Thu, Feb 24, 2000 at 09:06:28AM +0100 References: Message-ID: <20000224035600.F690@quipu.earth> Supply --with-default-path=... when running ./configure before compiling OpenSSH (where `...' is the default path you would like sshd to use instead of your system's _PATH_STDPATH). No patch necessary. -- jim knoble jmknoble at pobox.com P? 2000-Feb-24 klokka 09:06:28 +0100 skrivet David Bartl: : on my Linux (distribution Slackware 3.9), I have installed the : ``openssh-1.2.2.tar.gz'' package into the /usr/local/bin directory. : : In the ``sshd.c'' file, the PATH variable is set up: : : child_set_env(&env, &envsize, "PATH", _PATH_STDPATH); : : (line no. 2405). I am unable to connect to my machine using scp. : _PATH_STDPATH is "/usr/bin:/bin:/usr/sbin:/sbin", but the scp program : dwells in /usr/local/bin. If I try to connect, enter password (etc., : all OK), then the shell reports it could not find the scp command (not : in PATH) and the connection is closed... From gedl at yacctas.yacc.com.au Thu Feb 24 22:20:45 2000 From: gedl at yacctas.yacc.com.au (gedl at yacctas.yacc.com.au) Date: Thu, 24 Feb 2000 22:20:45 +1100 (EDT#Tasmania) Subject: No subject Message-ID: <200002241120.WAA03947@yacctas.yacc.com.au> Hi, I have just compiled the openssh server and client utilities on HP-UX using the ANSI C compiler from HP. The following notes may help some others that wish to do the same. THe problem reported with login.c can be fixed by adding a }. You need to match them up. I run with TCB. The port did not handle it well. I disabled PAM support. I use a password longer than 8 chars. I needed to use bigcrypt() instead of crypt. Needed to compile with -lsec and needed to specify HAVE_SHADOW_H. I am not a professional programmer so I kludged the programs to make them work. Happy to share them if you want to do it properly Apologies if this is the wrong spot to post Regards Ged From jbarnett at axil.netmate.com Fri Feb 25 01:24:53 2000 From: jbarnett at axil.netmate.com (Jack Barnett) Date: Thu, 24 Feb 2000 08:24:53 -0600 Subject: Quick Fix worked!!! Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) References: <005e01bf7c9e$384164f0$153046c6@inx.net> <20000221234732.A780@internal.domain> <00ab01bf7d3d$c4059340$153046c6@inx.net> <38B2B64D.2AA91606@dial.pipex.com> <006901bf7dfe$81b98ed0$153046c6@inx.net> <38B3FEE1.606E0DF3@dial.pipex.com> Message-ID: <00da01bf7ed2$ede1e6a0$153046c6@inx.net> Hi, I tried what you said in the last email and it worked great, compiled and install cleanly without problems. It will compiles fine if the LIBS="/usr/ucblib/libucb.a" is inserted before the ./configure. I still got the output (of the working ./configure/compile/install) if you guys want it. If you guys keep a list of "'know to work on XX Platform" I can verify that it cleanly and prefectly builds on Solaris 2.5 - Sparc Solaris 2.5.1 - Sparc Solaris 7 - Sparc Solaris 2.3 - Sparc (with LIBS="/usr/ucblib/libucb.a" inserted before ./configure [options]) Thanks allot to everyone that helped with this, OpenSSH is great and the developers know their stuff. I am very surpised and gratefully for the amount of support you guys have given on this. Thanks again for walking me though each little step. I owe you guys big time. Thanks again, Jack ----- Original Message ----- From: Andre Lucas To: Jack Barnett Cc: OpenSSH Unix Dev list Sent: Wednesday, February 23, 2000 9:38 AM Subject: Re: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) > Thanks for the files. The mistake is mine, I was looking in -lbsd when > the function is in /usr/ucblib/libucb.a . Had I referred back to the nm > output you provided before, I'd have seen that. Doh. > > All: It appears /usr/ucblib isn't in the library search path on Sol2.3, > so we want to be linking against /usr/ucblib/libucb.a instead of .so . > The only way I know to specify that I want specifically a static link is > to name the file on the command line, i.e. LIBS="$LIBS > /usr/ucblib/libucb.a". Does anyone know a better way? > > In any case, I'll put up a new patch later when I get home. I hope that > will sort this out. In the meantime, you may have some luck hacking it > with this: > > make distclean > LIBS="/usr/ucblib/libucb.a" ./configure > > which should sub in the required library for you. > > Ta, > -Andr? > > Jack Barnett wrote: > > > > Do you guys have any other suggestions? I am not on the list so I may be > > missing something. > > > > Thanks, > > Jack > > > > ----- Original Message ----- > > From: Andre Lucas > > To: Jack Barnett > > Cc: Andre Lucas ; OpenSSH Unix Dev list > > > > Sent: Tuesday, February 22, 2000 10:16 AM > > Subject: Re: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) > > > > > Before I dig in further with this: You did do 'make distclean' and rerun > > > configure before retrying the make? > > > > > > -Andr? > > > > > > Jack Barnett wrote: > > > > > > > > ----- Original Message ----- > > > > From: Andre Lucas > > > > To: OpenSSH Unix Dev list > > > > Cc: Jack Barnett > > > > Sent: Monday, February 21, 2000 5:47 PM > > > > Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) > > > > > > > > > Attached is a patch that should make configure look in the bsd compat > > > > > library for getpagesize(). [list note: I'm a little worried that we > > could > > > > > potentially be adding "-lbsd" to LDFLAGS three times now :-) ] > > > > > > > > > > If you need help applying the patch: ungzip the patch file, change to > > > > > your openssh source directory and do > > > > > patch -p1 < unzipped-patch-filename > > > > > > > > > > Ta, > > > > > -Andre > > > > > > > > > > -- > > > > > Andre Lucas > > > > > http://dspace.dial.pipex.com/andre.lucas/ > > > > > > > > --hostname~/open/openssh-1.2.2 -->patch -p1 < > > > > openssh-1.2.2-getpagesize.patch > > > > Hmm... Looks like a unified diff to me... > > > > The text leading up to this was: > > > > -------------------------- > > > > |diff -Purd openssh-1.2.2/acconfig.h openssh-1.2.2.new/acconfig.h > > > > |--- openssh-1.2.2/acconfig.h Sat Jan 22 23:32:03 2000 > > > > |+++ openssh-1.2.2.new/acconfig.h Mon Feb 21 23:39:08 2000 > > > > -------------------------- > > > > Patching file acconfig.h using Plan A... > > > > Hunk #1 succeeded at 95. > > > > Hmm... The next patch looks like a unified diff to me... > > > > The text leading up to this was: > > > > -------------------------- > > > > |diff -Purd openssh-1.2.2/config.h.in openssh-1.2.2.new/config.h.in > > > > |--- openssh-1.2.2/config.h.in Thu Jan 27 03:17:05 2000 > > > > |+++ openssh-1.2.2.new/config.h.in Mon Feb 21 23:39:13 2000 > > > > -------------------------- > > > > Patching file config.h.in using Plan A... > > > > Hunk #1 succeeded at 89. > > > > Hunk #2 succeeded at 185. > > > > Hmm... The next patch looks like a unified diff to me... > > > > The text leading up to this was: > > > > -------------------------- > > > > |diff -Purd openssh-1.2.2/configure openssh-1.2.2.new/configure > > > > |--- openssh-1.2.2/configure Thu Jan 27 03:17:06 2000 > > > > |+++ openssh-1.2.2.new/configure Mon Feb 21 23:39:17 2000 > > > > -------------------------- > > > > Patching file configure using Plan A... > > > > Hunk #1 succeeded at 1655. > > > > Hunk #2 succeeded at 1903. > > > > Hunk #3 succeeded at 2010. > > > > Hunk #4 succeeded at 2021. > > > > Hunk #5 succeeded at 2041. > > > > Hunk #6 succeeded at 2049. > > > > Hunk #7 succeeded at 2060. > > > > Hunk #8 succeeded at 2080. > > > > Hunk #9 succeeded at 2088. > > > > Hunk #10 succeeded at 2099. > > > > Hunk #11 succeeded at 2119. > > > > Hunk #12 succeeded at 2127. > > > > Hunk #13 succeeded at 2138. > > > > Hunk #14 succeeded at 2158. > > > > Hunk #15 succeeded at 2166. > > > > Hunk #16 succeeded at 2177. > > > > Hunk #17 succeeded at 2198. > > > > Hunk #18 succeeded at 2227. > > > > Hunk #19 succeeded at 2259. > > > > Hunk #20 succeeded at 2273. > > > > Hunk #21 succeeded at 2297. > > > > Hunk #22 succeeded at 2325. > > > > Hunk #23 succeeded at 2337. > > > > Hunk #24 succeeded at 2356. > > > > Hunk #25 succeeded at 2384. > > > > Hunk #26 succeeded at 2396. > > > > Hunk #27 succeeded at 2415. > > > > Hunk #28 succeeded at 2443. > > > > Hunk #29 succeeded at 2471. > > > > Hunk #30 succeeded at 2484. > > > > Hunk #31 succeeded at 2520. > > > > Hunk #32 succeeded at 2528. > > > > Hunk #33 succeeded at 2539. > > > > Hunk #34 succeeded at 2568. > > > > Hunk #35 succeeded at 2580. > > > > Hunk #36 succeeded at 2600. > > > > Hunk #37 succeeded at 2636. > > > > Hunk #38 succeeded at 2695. > > > > Hunk #39 succeeded at 2716. > > > > Hunk #40 succeeded at 2737. > > > > Hunk #41 succeeded at 2758. > > > > Hunk #42 succeeded at 2779. > > > > Hunk #43 succeeded at 2800. > > > > Hunk #44 succeeded at 2821. > > > > Hunk #45 succeeded at 2842. > > > > Hunk #46 succeeded at 2863. > > > > Hunk #47 succeeded at 2884. > > > > Hunk #48 succeeded at 2905. > > > > Hunk #49 succeeded at 2927. > > > > Hunk #50 succeeded at 2939. > > > > Hunk #51 succeeded at 2957. > > > > Hunk #52 succeeded at 2969. > > > > Hunk #53 succeeded at 3006. > > > > Hunk #54 succeeded at 3061. > > > > Hunk #55 succeeded at 3069. > > > > Hunk #56 succeeded at 3080. > > > > Hunk #57 succeeded at 3123. > > > > Hunk #58 succeeded at 3131. > > > > Hunk #59 succeeded at 3142. > > > > Hunk #60 succeeded at 3185. > > > > Hunk #61 succeeded at 3193. > > > > Hunk #62 succeeded at 3204. > > > > Hunk #63 succeeded at 3261. > > > > Hunk #64 succeeded at 3290. > > > > Hunk #65 succeeded at 3317. > > > > Hunk #66 succeeded at 3365. > > > > Hunk #67 succeeded at 3402. > > > > Hunk #68 succeeded at 3410. > > > > Hunk #69 succeeded at 3453. > > > > Hunk #70 succeeded at 3461. > > > > Hunk #71 succeeded at 3472. > > > > Hmm... The next patch looks like a unified diff to me... > > > > The text leading up to this was: > > > > -------------------------- > > > > |diff -Purd openssh-1.2.2/configure.in openssh-1.2.2.new/configure.in > > > > |--- openssh-1.2.2/configure.in Wed Jan 26 01:15:31 2000 > > > > |+++ openssh-1.2.2.new/configure.in Mon Feb 21 23:38:09 2000 > > > > -------------------------- > > > > Patching file configure.in using Plan A... > > > > Hunk #1 succeeded at 157. > > > > Hunk #2 succeeded at 167. > > > > done > > > > > > > > > > --hostname~/open/openssh-1.2.2 -->./configure --with-tcp-wrappers --with-e > > gd > > > > -pool=/dev/random > > > > > > > > No obvoius errors or warnings here > > > > > > > > --hostname~/open/openssh-1.2.2 -->make > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c atomicio.c -o atomicio.o > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c authfd.c -o authfd.o > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c authfile.c -o authfile.o > > > > authfile.c: In function `load_private_key': > > > > authfile.c:238: warning: unsigned int format, long unsigned int arg (arg > > 2) > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-bindresvport.c -o > > > > bsd-bindresvport.o > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-daemon.c -o bsd-daemon.o > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-misc.c -o bsd-misc.o > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-mktemp.c -o bsd-mktemp.o > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-rresvport.c -o bsd-rresvport.o > > > > bsd-rresvport.c: In function `rresvport_af': > > > > bsd-rresvport.c:66: warning: implicit declaration of function `bzero' > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o > > > > bsd-snprintf.c: In function `getpagesize': > > > > bsd-snprintf.c:70: `NBPC' undeclared (first use this function) > > > > bsd-snprintf.c:70: (Each undeclared identifier is reported only once > > > > bsd-snprintf.c:70: for each function it appears in.) > > > > bsd-snprintf.c:73: warning: control reaches end of non-void function > > > > bsd-snprintf.c: In function `vsnprintf': > > > > bsd-snprintf.c:133: warning: variable `ret' might be clobbered by > > `longjmp' > > > > or `vfork' > > > > bsd-snprintf.c: At top level: > > > > bsd-snprintf.c:52: warning: `caught' defined but not used > > > > make: *** [bsd-snprintf.o] Error 1 > > > > > > > > I won't post the entire output in the furture. > > > > > > > > Thanks, > > > > Jack > > > > From jbarnett at axil.netmate.com Fri Feb 25 05:50:39 2000 From: jbarnett at axil.netmate.com (Jack Barnett) Date: Thu, 24 Feb 2000 12:50:39 -0600 Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) References: <005e01bf7c9e$384164f0$153046c6@inx.net> <20000221234732.A780@internal.domain> <00ab01bf7d3d$c4059340$153046c6@inx.net> <38B2B64D.2AA91606@dial.pipex.com> <006901bf7dfe$81b98ed0$153046c6@inx.net> <38B3FEE1.606E0DF3@dial.pipex.com> Message-ID: <000701bf7ef8$161aaf60$153046c6@inx.net> I am going to have to bug this list again, it compiled fine, it starts up fine, but when someone connections it crashes out. If I am annonying this list to much just drop me an email and I will stop posting. # ./sshd -d debug: sshd version OpenSSH-1.2.2 debug: Bind to port 22 on 192.168.17.2. Server listening on 192.168.17.2 port 22. Generating 768 bit RSA key. RSA key generation complete. debug: Server will not fork when running in debugging mode. Connection from 192.168.20.7 port 623 debug: Client protocol version 1.5; client software version OpenSSH-1.2.2 Segmentation Fault - core dumped I tried untaring the source from orignal tar ball, running the LIBS="/usr/ucblib/libucb.a" ./configure --with-tcp-wrappers --with-egd-pool=/dev/random make make test su make install /usr/local/sbin/sshd and also tried patch -p1 < openssh-1.2.2-getpagesize.patch LIBS="/usr/ucblib/libucb.a" ./configure --with-tcp-wrappers --with-egd-pool=/dev/random make make test su make install /usr/local/sbin/sshd Everytime I (re) build it on this machine, I delete the old directory and restore staight from the 1.2.2 tarball downloaded at openssh.org Jack ----- Original Message ----- From: Andre Lucas To: Jack Barnett Cc: OpenSSH Unix Dev list Sent: Wednesday, February 23, 2000 9:38 AM Subject: Re: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) > Thanks for the files. The mistake is mine, I was looking in -lbsd when > the function is in /usr/ucblib/libucb.a . Had I referred back to the nm > output you provided before, I'd have seen that. Doh. > > All: It appears /usr/ucblib isn't in the library search path on Sol2.3, > so we want to be linking against /usr/ucblib/libucb.a instead of .so . > The only way I know to specify that I want specifically a static link is > to name the file on the command line, i.e. LIBS="$LIBS > /usr/ucblib/libucb.a". Does anyone know a better way? > > In any case, I'll put up a new patch later when I get home. I hope that > will sort this out. In the meantime, you may have some luck hacking it > with this: > > make distclean > LIBS="/usr/ucblib/libucb.a" ./configure > > which should sub in the required library for you. > > Ta, > -Andr? > > Jack Barnett wrote: > > > > Do you guys have any other suggestions? I am not on the list so I may be > > missing something. > > > > Thanks, > > Jack > > > > ----- Original Message ----- > > From: Andre Lucas > > To: Jack Barnett > > Cc: Andre Lucas ; OpenSSH Unix Dev list > > > > Sent: Tuesday, February 22, 2000 10:16 AM > > Subject: Re: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) > > > > > Before I dig in further with this: You did do 'make distclean' and rerun > > > configure before retrying the make? > > > > > > -Andr? > > > > > > Jack Barnett wrote: > > > > > > > > ----- Original Message ----- > > > > From: Andre Lucas > > > > To: OpenSSH Unix Dev list > > > > Cc: Jack Barnett > > > > Sent: Monday, February 21, 2000 5:47 PM > > > > Subject: Patch (was: OpenSSH doesn't compile under Solaris 2.3 Sparc) > > > > > > > > > Attached is a patch that should make configure look in the bsd compat > > > > > library for getpagesize(). [list note: I'm a little worried that we > > could > > > > > potentially be adding "-lbsd" to LDFLAGS three times now :-) ] > > > > > > > > > > If you need help applying the patch: ungzip the patch file, change to > > > > > your openssh source directory and do > > > > > patch -p1 < unzipped-patch-filename > > > > > > > > > > Ta, > > > > > -Andre > > > > > > > > > > -- > > > > > Andre Lucas > > > > > http://dspace.dial.pipex.com/andre.lucas/ > > > > > > > > --hostname~/open/openssh-1.2.2 -->patch -p1 < > > > > openssh-1.2.2-getpagesize.patch > > > > Hmm... Looks like a unified diff to me... > > > > The text leading up to this was: > > > > -------------------------- > > > > |diff -Purd openssh-1.2.2/acconfig.h openssh-1.2.2.new/acconfig.h > > > > |--- openssh-1.2.2/acconfig.h Sat Jan 22 23:32:03 2000 > > > > |+++ openssh-1.2.2.new/acconfig.h Mon Feb 21 23:39:08 2000 > > > > -------------------------- > > > > Patching file acconfig.h using Plan A... > > > > Hunk #1 succeeded at 95. > > > > Hmm... The next patch looks like a unified diff to me... > > > > The text leading up to this was: > > > > -------------------------- > > > > |diff -Purd openssh-1.2.2/config.h.in openssh-1.2.2.new/config.h.in > > > > |--- openssh-1.2.2/config.h.in Thu Jan 27 03:17:05 2000 > > > > |+++ openssh-1.2.2.new/config.h.in Mon Feb 21 23:39:13 2000 > > > > -------------------------- > > > > Patching file config.h.in using Plan A... > > > > Hunk #1 succeeded at 89. > > > > Hunk #2 succeeded at 185. > > > > Hmm... The next patch looks like a unified diff to me... > > > > The text leading up to this was: > > > > -------------------------- > > > > |diff -Purd openssh-1.2.2/configure openssh-1.2.2.new/configure > > > > |--- openssh-1.2.2/configure Thu Jan 27 03:17:06 2000 > > > > |+++ openssh-1.2.2.new/configure Mon Feb 21 23:39:17 2000 > > > > -------------------------- > > > > Patching file configure using Plan A... > > > > Hunk #1 succeeded at 1655. > > > > Hunk #2 succeeded at 1903. > > > > Hunk #3 succeeded at 2010. > > > > Hunk #4 succeeded at 2021. > > > > Hunk #5 succeeded at 2041. > > > > Hunk #6 succeeded at 2049. > > > > Hunk #7 succeeded at 2060. > > > > Hunk #8 succeeded at 2080. > > > > Hunk #9 succeeded at 2088. > > > > Hunk #10 succeeded at 2099. > > > > Hunk #11 succeeded at 2119. > > > > Hunk #12 succeeded at 2127. > > > > Hunk #13 succeeded at 2138. > > > > Hunk #14 succeeded at 2158. > > > > Hunk #15 succeeded at 2166. > > > > Hunk #16 succeeded at 2177. > > > > Hunk #17 succeeded at 2198. > > > > Hunk #18 succeeded at 2227. > > > > Hunk #19 succeeded at 2259. > > > > Hunk #20 succeeded at 2273. > > > > Hunk #21 succeeded at 2297. > > > > Hunk #22 succeeded at 2325. > > > > Hunk #23 succeeded at 2337. > > > > Hunk #24 succeeded at 2356. > > > > Hunk #25 succeeded at 2384. > > > > Hunk #26 succeeded at 2396. > > > > Hunk #27 succeeded at 2415. > > > > Hunk #28 succeeded at 2443. > > > > Hunk #29 succeeded at 2471. > > > > Hunk #30 succeeded at 2484. > > > > Hunk #31 succeeded at 2520. > > > > Hunk #32 succeeded at 2528. > > > > Hunk #33 succeeded at 2539. > > > > Hunk #34 succeeded at 2568. > > > > Hunk #35 succeeded at 2580. > > > > Hunk #36 succeeded at 2600. > > > > Hunk #37 succeeded at 2636. > > > > Hunk #38 succeeded at 2695. > > > > Hunk #39 succeeded at 2716. > > > > Hunk #40 succeeded at 2737. > > > > Hunk #41 succeeded at 2758. > > > > Hunk #42 succeeded at 2779. > > > > Hunk #43 succeeded at 2800. > > > > Hunk #44 succeeded at 2821. > > > > Hunk #45 succeeded at 2842. > > > > Hunk #46 succeeded at 2863. > > > > Hunk #47 succeeded at 2884. > > > > Hunk #48 succeeded at 2905. > > > > Hunk #49 succeeded at 2927. > > > > Hunk #50 succeeded at 2939. > > > > Hunk #51 succeeded at 2957. > > > > Hunk #52 succeeded at 2969. > > > > Hunk #53 succeeded at 3006. > > > > Hunk #54 succeeded at 3061. > > > > Hunk #55 succeeded at 3069. > > > > Hunk #56 succeeded at 3080. > > > > Hunk #57 succeeded at 3123. > > > > Hunk #58 succeeded at 3131. > > > > Hunk #59 succeeded at 3142. > > > > Hunk #60 succeeded at 3185. > > > > Hunk #61 succeeded at 3193. > > > > Hunk #62 succeeded at 3204. > > > > Hunk #63 succeeded at 3261. > > > > Hunk #64 succeeded at 3290. > > > > Hunk #65 succeeded at 3317. > > > > Hunk #66 succeeded at 3365. > > > > Hunk #67 succeeded at 3402. > > > > Hunk #68 succeeded at 3410. > > > > Hunk #69 succeeded at 3453. > > > > Hunk #70 succeeded at 3461. > > > > Hunk #71 succeeded at 3472. > > > > Hmm... The next patch looks like a unified diff to me... > > > > The text leading up to this was: > > > > -------------------------- > > > > |diff -Purd openssh-1.2.2/configure.in openssh-1.2.2.new/configure.in > > > > |--- openssh-1.2.2/configure.in Wed Jan 26 01:15:31 2000 > > > > |+++ openssh-1.2.2.new/configure.in Mon Feb 21 23:38:09 2000 > > > > -------------------------- > > > > Patching file configure.in using Plan A... > > > > Hunk #1 succeeded at 157. > > > > Hunk #2 succeeded at 167. > > > > done > > > > > > > > > > --hostname~/open/openssh-1.2.2 -->./configure --with-tcp-wrappers --with-e > > gd > > > > -pool=/dev/random > > > > > > > > No obvoius errors or warnings here > > > > > > > > --hostname~/open/openssh-1.2.2 -->make > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c atomicio.c -o atomicio.o > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c authfd.c -o authfd.o > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c authfile.c -o authfile.o > > > > authfile.c: In function `load_private_key': > > > > authfile.c:238: warning: unsigned int format, long unsigned int arg (arg > > 2) > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-bindresvport.c -o > > > > bsd-bindresvport.o > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-daemon.c -o bsd-daemon.o > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-misc.c -o bsd-misc.o > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-mktemp.c -o bsd-mktemp.o > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-rresvport.c -o bsd-rresvport.o > > > > bsd-rresvport.c: In function `rresvport_af': > > > > bsd-rresvport.c:66: warning: implicit declaration of function `bzero' > > > > > > gcc -g -O2 -Wall -I/usr/local/ssl/include -DETCDIR=\"/usr/local/etc\" -DSSH_ > > > > > > PROGRAM=\"/usr/local/bin/ssh\" -DSSH_ASKPASS_DEFAULT=\"/usr/local/libexec/ss > > > > h/ssh-askpass\" -DHAVE_CONFIG_H -c bsd-snprintf.c -o bsd-snprintf.o > > > > bsd-snprintf.c: In function `getpagesize': > > > > bsd-snprintf.c:70: `NBPC' undeclared (first use this function) > > > > bsd-snprintf.c:70: (Each undeclared identifier is reported only once > > > > bsd-snprintf.c:70: for each function it appears in.) > > > > bsd-snprintf.c:73: warning: control reaches end of non-void function > > > > bsd-snprintf.c: In function `vsnprintf': > > > > bsd-snprintf.c:133: warning: variable `ret' might be clobbered by > > `longjmp' > > > > or `vfork' > > > > bsd-snprintf.c: At top level: > > > > bsd-snprintf.c:52: warning: `caught' defined but not used > > > > make: *** [bsd-snprintf.o] Error 1 > > > > > > > > I won't post the entire output in the furture. > > > > > > > > Thanks, > > > > Jack > > > > From greg at linuxpower.cx Fri Feb 25 10:22:22 2000 From: greg at linuxpower.cx (Gregory Maxwell) Date: Thu, 24 Feb 2000 18:22:22 -0500 (EST) Subject: Making password driven SSH 'immune' to MTM attacks. Message-ID: [I know this is the 'port' list, but I can't find a better place to post this, and with the garbage going on @slashdot I figured I'd get this out. This belongs on sci.crypt or a general OpenSSH mailing list] First, a quick rehash of stuff everyone here already knows, OpenSSH can use two major forms of authentication: 1. Password 2. RSA keys The RSA method is good because it doesn't rely on the (frequently non)secrecy of passwords. It's primary disadvantage is that using it correctly requires a PKI of some form (be it x.509 certs, GPG signed copies, manual key population) to be secure. Considering the complexity, cost, and lack of standardaztion, *most* orgs will are not and will not be using RSA keys anytime in the forseable future. Passwords are well understood, by both crypto/security heads and by the common man. Often passwords are not a very good form of authentication, because of their very nature. However, due to their simplicity many orgs have developed sufficently secure methods of establishing and protecting passwords. Unfortuantly, when using passwords with SSH you are fairly vulnarable to a Man-in-the-middle attack. SSH provides some basic protection against this in the form of saved host keys. Unfortunatly, this is insufficent as the network could be comprimised before inital connection, and often users will just 'okay' the WARNING message anyways because it is falsely triggered so easily. I have a proposed solution that will make MTM virtually impossible in a password authenticated SSH enviroment assuming the password is indeed a shared secret and the server is not comprimised. MTM against stored keys is not examined, presumibly the 'PKI' system is use provides sufficent security against that. For the rest of this message, we will assume a password is indeed a shared secret. This makes sence because if it's not a secret, your security is gone anyways. My scheme does not further reduce security in the situation where the password is comprimised. First go to http://srp.stanford.edu/srp/ and read up on SRP. SRP is a password authentication system with the following properties: * 'Shadowed' password data stored on server. It's computationally inplusable that an attacker could derrive the password from the 'shadow' (like MD5). * The client sends NON plain-text equivlent data across the wire. * It's infeasable for an MTM attack to occure unless the MTM knows either the 'shadow' from the server, or the plain-text password (in which case why would you bother with a MTM) SRP is currently used as a 'replacement' for SSH in enviroments that can't use encryption or are willing to use an enhanced telnet but not a whole new client. If we add SRP client code to the OpenSSH client (a small amount of code that can be easily audited), and a small modification to the server it will make it possible to use SRP to authenticate on hosts that using an SRP password file. The most difficult aspect of the implimentation is that the SRP negoiated secret should be xored into the key used for SSH channel encryption (this would be rekeying because the ssh encrypted channel is already established at authentication time). This would make passworded SSH almost entirely immune to active MTM in the common case, while not reducing security at all (with the excpetion of potential implimentation bugs). This would also provide improved compatibility for systems that are using both SSH and SRP (for other services perhaps, or clients that can't use strong encryption). This would probably require a minor change in the protocol that could still operate in a backwards compatible fashion. I think that this protection is important for the future of SSH, as there appears to be no inexpensive, standard, simple, and understabable PKI implimentation on the horizon. Because of this, people are going to continue using passwords, at least with this reletivly minor enhancement, their securiy is brought back to that of the password and not that of the network during initial connect. Any comments? (is this a new idea?) From djm at mindrot.org Fri Feb 25 11:54:14 2000 From: djm at mindrot.org (Damien Miller) Date: Fri, 25 Feb 2000 11:54:14 +1100 (EST) Subject: SSL devel. model In-Reply-To: Message-ID: On Thu, 24 Feb 2000, Sean Aaron Lisse wrote: > My partner is planning on altering OpenSSH such that it can do SSL-type > third-party authentication, instead of relying on the first-contact setup > that is currently in place. Hate to disappoint, but this is being worked on too: ftp://ftp-uk.hpl.hp.com/pub/nd/ Has patches to OpenSSH to allow it to use X.509 certificates for authentication. These certificates can be stored in DBM files or live on an LDAP server. Neil Dunbar is doing this work. I'll try to answer your other questions tomorrow. -d -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From adamb at zeroknowledge.com Fri Feb 25 12:10:38 2000 From: adamb at zeroknowledge.com (Adam Back) Date: Thu, 24 Feb 2000 20:10:38 -0500 Subject: yarrow unix source Message-ID: <38B5D68E.EE182B72@zeroknowledge.com> Hi guys We at ZKS were also interested in yarrow under unix. However the implementation that counterpane have on their web page doesn't correspond to the paper -- it is a pretty different design. Also the windows code is hairy in the extreme -- I decided to reimplement it from scratch from the paper, rather than try to look at that windows code too much (yeuch!). And in writing from the paper, this is when I found that contrary to expectations from reading their webpage, the code is completely unrelated to the paper. I asked them about this discrepency and apparently there was a previous version of the paper with a different design. However they don't reference the previous paper at all on their web page. I suggested they should mention that there is a difference as people will be using the code under false assumptions about it's design, and they've done this now. So I have some nice, clean unix source code for the new yarrow design, which we're going to release under BSD or other open license, asap. Personally I would like to see yarrow used as a replacement for /dev/urandom, plus of course for randomness drivers with hooks into the kernel made available under more OSes so that people can start to depend on the availability of a good RNG. However there is a problem with the current yarrow design which is that there is no easy way to integrate it into /dev/[u]random. You can replace /dev/urandom with yarrow, but you can't replace /dev/random, and it can be dangerous sharing entropy sources between /dev/random and yarrow -- /dev/random has different properties -- it is designed to offer information theoretic security, where as /dev/urandom and yarrow are design to offer a cryptographic PRNG, with computational security. I'm talking to the authors of the paper trying to motivate a new design which can safely be integrated to provide to interfaces: information theoretic (/dev/random) and computational (/dev/urandom). So I would suggest that you hold off on using the old yarrow design as the new design is stronger. The new design has two pools which offers slow strong reseeds, and fast intermediate strength reseeds to recover from state compromise both strongly and as soon as possible. (I first found out about the interest in a unix version of yarrow for openssh from an email Bruce Schneier forwarded me from Andre Lucas asking if Counterpane had such code. Adam From markus.friedl at informatik.uni-erlangen.de Fri Feb 25 19:26:21 2000 From: markus.friedl at informatik.uni-erlangen.de (Markus Friedl) Date: Fri, 25 Feb 2000 09:26:21 +0100 Subject: SSL devel. model In-Reply-To: ; from nebulous@owlnet.rice.edu on Thu, Feb 24, 2000 at 01:10:59AM -0600 References: <20000224015548.B690@quipu.earth> Message-ID: <20000225092621.A20078@folly.informatik.uni-erlangen.de> On Thu, Feb 24, 2000 at 01:10:59AM -0600, Sean Aaron Lisse wrote: > As an exercise (final project) for my computer security class, I'm > planning on implementing an NFS-like extension to OpenSSH that will > automatically "mount" the remote machine's filesystem in a subset of the > current directory (thus giving even more 'transparency' to the interface > and eliminating much of the need to use scp back and forth). there is some talk about integrating lsh and rync. see: http://rsync.samba.org/listproc/rsync/current/ From fredrik.liljegren at configura.com Sat Feb 26 04:01:28 2000 From: fredrik.liljegren at configura.com (Fredrik Liljegren) Date: Fri, 25 Feb 2000 18:01:28 +0100 Subject: Letting PAM add a user Message-ID: Hello. I have a linux-based system that acts as a cvs-server on an NT-domain. The cvs-repository is reached whith ssh. My comments are for version 1.2.2 (debian distribution 1.2.2-1). I made a pam-module for adding users automatically when they have been authorized by the pam_smb_auth. Problem is that sshd checks if the user exists in passwd before going to pam for authorization. I made a very nasty hack to sshd that changed the behaviour so that the pw-struct got some defaults instead of pw from getpwnam() if allowed_user() returns false. However, I would rather use a real version of sshd, so I suggest there be some changes made to allow for better PAM-usage. For that, the (or a) call to getpwnam() must be run AFTER pam has checked authorization and account (my pam_useradd is an account module). First, pw is sent by to start_pam(). start_pam() only uses pw->pw_name though, so I suggest sending in user instead of pw. Second, pw is used to compare uid if not running as root. This check I suppose could be done after auth_pam_password() ? If these changes aren't good for non-pam situations, maybe considering splitting it up more so that pam-users have a totally separate procedure? I haven't looked at it yet, but I guess RSA-authentication could be made a pam-module also? Regards, EOF PS: Please cc all replies to me, since I am not yet in the list (I subscribed another of my adresses and it had to go and ask the list administrator etc etc). DS. From dwd at bell-labs.com Sat Feb 26 06:51:26 2000 From: dwd at bell-labs.com (Dave Dykstra) Date: Fri, 25 Feb 2000 13:51:26 -0600 Subject: Making password driven SSH 'immune' to MTM attacks. In-Reply-To: ; from Gregory Maxwell on Thu, Feb 24, 2000 at 06:22:22PM -0500 References: Message-ID: <20000225135125.A4605@lucent.com> On Thu, Feb 24, 2000 at 06:22:22PM -0500, Gregory Maxwell wrote: > The RSA method is good because it doesn't rely on the (frequently > non)secrecy of passwords. It's primary disadvantage is that using it > correctly requires a PKI of some form (be it x.509 certs, GPG signed > copies, manual key population) to be secure. I think that's nonsense. If you personally exchange RSA public keys or get them from people you know personally there's no reason why it needs a PKI. RSA authentication works wonderfully in SSH. It's hardly any harder to exchange RSA public keys than to exchange a secret password, except that the former can't be transmitted over a telephone. > Unfortuantly, when using passwords with SSH you are fairly > vulnarable to a Man-in-the-middle attack. SSH provides some basic > protection against this in the form of saved host keys. Unfortunatly, this > is insufficent as the network could be comprimised before inital > connection, and often users will just 'okay' the WARNING message anyways > because it is falsely triggered so easily. If you're worried about a compromise before the initial connection then exchange the public key of the host separately at the same time you exchange the individual's key. No big deal. I rarely run into cases where there's a reason to be suspicious that early, however. ... > If we add SRP client code to the OpenSSH client (a small amount of code > that can be easily audited), and a small modification to the server it > will make it possible to use SRP to authenticate on hosts that using an > SRP password file. That's a worthwhile reason to add SRP support to OpenSSH, but I don't see much value in enabling SRP if your system doesn't already have an SRP password file. - Dave Dykstra From greg at linuxpower.cx Sat Feb 26 07:53:07 2000 From: greg at linuxpower.cx (Gregory Maxwell) Date: Fri, 25 Feb 2000 15:53:07 -0500 (EST) Subject: Making password driven SSH 'immune' to MTM attacks. In-Reply-To: <20000225135125.A4605@lucent.com> Message-ID: On Fri, 25 Feb 2000, Dave Dykstra wrote: > On Thu, Feb 24, 2000 at 06:22:22PM -0500, Gregory Maxwell wrote: > > The RSA method is good because it doesn't rely on the (frequently > > non)secrecy of passwords. It's primary disadvantage is that using it > > correctly requires a PKI of some form (be it x.509 certs, GPG signed > > copies, manual key population) to be secure. > > I think that's nonsense. If you personally exchange RSA public keys or > get them from people you know personally there's no reason why it needs > a PKI. RSA authentication works wonderfully in SSH. It's hardly any > harder to exchange RSA public keys than to exchange a secret password, > except that the former can't be transmitted over a telephone. I should have been more clear: I was defining PKI as 'some sort of key management system which provides some level of authentication of key legitimicy'. Not that bastardized system of 'trust-for-money' called normally called PKI. :) > If you're worried about a compromise before the initial connection then > exchange the public key of the host separately at the same time you > exchange the individual's key. No big deal. Since I'm not two good at accuratly rembering numbers 1024+ bits in size, and there is no widespread, standardized, and cheap 'smart card' system. I can rember several passwords, and carry them around in my mind. I can't mentally carry even a single RSA key pair. > I rarely run into cases where > there's a reason to be suspicious that early, however. Oh? You don't ever connect to a SSH host for the first time across the internet? Perhaps you always can get verified keys (using the GPG ring-of-trust by hand method of PKI). But this isn't something the computer using world at large will do, they will blissfully see WARNING and type 'YES' blissfully ignorant of the middle-man. Someday there will be a simple and well understood method for securly veryfing RSA key pairs (all hail DNSSEC!). But thats not available today. Today, most people use passwords, and they arn't willing to goto the effort of veryfing RSA keys. > That's a worthwhile reason to add SRP support to OpenSSH, but I don't see > much value in enabling SRP if your system doesn't already have an SRP > password file. I agree with that. > - Dave Dykstra From jmknoble at pobox.com Sat Feb 26 09:07:08 2000 From: jmknoble at pobox.com (Jim Knoble) Date: Fri, 25 Feb 2000 17:07:08 -0500 Subject: Making password driven SSH 'immune' to MTM attacks. In-Reply-To: ; from Gregory Maxwell on Fri, Feb 25, 2000 at 03:53:07PM -0500 References: <20000225135125.A4605@lucent.com> Message-ID: <20000225170708.B24984@ntrnet.net> P? 2000-Feb-25 klokka 15:53:07 -0500 skrivet Gregory Maxwell: : Since I'm not two good at accuratly rembering numbers 1024+ bits in : size, and there is no widespread, standardized, and cheap 'smart card' : system. 1.44 MB floppies have been around for quite some time. : I can rember several passwords, and carry them around in my mind. I : can't mentally carry even a single RSA key pair. That's actually part of the benefit of public/private keypairs protected by passphrases: while passwords are merely something you know, and ``smart'' cards (or Java jewelry, or fingerprints) are something you have, a protected private key is both something you have (the key) *and* something you know (the passphrase). -- jim knoble jmknoble at pobox.com From chip at valinux.com Sat Feb 26 16:50:19 2000 From: chip at valinux.com (Chip Salzenberg) Date: Fri, 25 Feb 2000 21:50:19 -0800 Subject: Bug#59054: New option: "PrintLastLogin" Message-ID: <20000225215019.A32483@perlsupport.com> Package: openssh Version: 1.2.2-1.1 Severity: wishlist While the PrintMotd option allows deferring that feature to PAM, there is no corresponding "PrintLastLogin" option. ... Or at least, there _was_ no such option, until now. :-) Index: servconf.h *************** *** 41,44 **** --- 41,45 ---- int ignore_user_known_hosts; /* Ignore ~/.ssh/known_hosts * for RhostsRsaAuth */ + int print_last_login; /* If true, print last login. */ int print_motd; /* If true, print /etc/motd. */ int check_mail; /* If true, check for new mail. */ Index: servconf.c *************** initialize_server_options(ServerOptions *** 38,41 **** --- 38,42 ---- options->ignore_rhosts = -1; options->ignore_user_known_hosts = -1; + options->print_last_login = -1; options->print_motd = -1; options->check_mail = -1; *************** fill_default_server_options(ServerOption *** 93,96 **** --- 94,99 ---- if (options->check_mail == -1) options->check_mail = 0; + if (options->print_last_login == -1) + options->print_last_login = 1; if (options->print_motd == -1) options->print_motd = 1; *************** typedef enum { *** 156,161 **** sSkeyAuthentication, #endif ! sPasswordAuthentication, sListenAddress, ! sPrintMotd, sIgnoreRhosts, sX11Forwarding, sX11DisplayOffset, sStrictModes, sEmptyPasswd, sRandomSeedFile, sKeepAlives, sCheckMail, sUseLogin, sAllowUsers, sDenyUsers, sAllowGroups, sDenyGroups, --- 159,164 ---- sSkeyAuthentication, #endif ! sPasswordAuthentication, sListenAddress, sPrintLastLogin, sPrintMotd, ! sIgnoreRhosts, sX11Forwarding, sX11DisplayOffset, sStrictModes, sEmptyPasswd, sRandomSeedFile, sKeepAlives, sCheckMail, sUseLogin, sAllowUsers, sDenyUsers, sAllowGroups, sDenyGroups, *************** static struct { *** 194,197 **** --- 197,201 ---- { "checkmail", sCheckMail }, { "listenaddress", sListenAddress }, + { "printlastlogin", sPrintLastLogin }, { "printmotd", sPrintMotd }, { "ignorerhosts", sIgnoreRhosts }, *************** parse_flag: *** 454,457 **** --- 458,465 ---- goto parse_flag; #endif + + case sPrintLastLogin: + intptr = &options->print_last_login; + goto parse_flag; case sPrintMotd: Index: sshd.8 *************** *** 384,387 **** --- 384,398 ---- listens on. The default is 22. Multiple options of this type are permitted. + .It Cm PrintLastLogin + Specifies whether + .Nm + should print the date and tty of last login when a user logs in + interactively. The default is + .Dq yes . + .Pp + Note: These messages can also be generated by PAM, so if you find that + you are getting the message twice, switch this one + .Dq off + and let PAM handle it. .It Cm PrintMotd Specifies whether Index: sshd.c *************** do_exec_pty(const char *command, int pty *** 2260,2264 **** */ if (command == NULL && last_login_time != 0 && !quiet_login && ! !options.use_login) { /* Convert the date to a string. */ time_string = ctime(&last_login_time); --- 2260,2264 ---- */ if (command == NULL && last_login_time != 0 && !quiet_login && ! options.print_last_login && !options.use_login) { /* Convert the date to a string. */ time_string = ctime(&last_login_time); -- Chip Salzenberg - a.k.a. - "I wanted to play hopscotch with the impenetrable mystery of existence, but he stepped in a wormhole and had to go in early." // MST3K From lodder at yacc.com.au Sat Feb 26 20:41:49 2000 From: lodder at yacc.com.au (Ged Lodder) Date: Sat, 26 Feb 2000 20:41:49 +1100 Subject: OpenSSH on HP-UX 11 with TCB Message-ID: <38B79FDD.5268FEAB@yacc.com.au> Hi, an updated and more civilized post (to my one and only previous one) on getting OpenSSH to work on HP-UX 11 using the TCB. I used the HP ANSI C compiler. Firstly, I needed to download, compile and install OpenSSL, EGD and ZLib. Specific issues: configure did not handle hpux 11 login.c did not compile makefile did not use $(CFLAGS) sshd did not compile (pam issues), I wanted to use supplied pam library I use long passwords, > 8 chars, needed bigcrypt() Solutions for configure: I added the following to the configure script: *-*-hpux11*) if test -z "$GCC"; then CFLAGS="$CFLAGS -Ae" fi CFLAGS="$CFLAGS -D_HPUX_SOURCE" cat >> confdefs.h <<\EOF #define IPADDR_IN_DISPLAY 1 EOF cat >> confdefs.h <<\EOF #define USE_UTMPX 1 EOF echo $ac_n "checking for HPUX trusted system password database""... $ac_c" 1>&6 echo "configure:1301: checking for HPUX trusted system password database" >&5 if test -f /tcb/files/auth/system/default; then echo "$ac_t""yes" 1>&6 cat >> confdefs.h <<\EOF #define HAVE_HPUX_TRUSTED_SYSTEM_PW 1 EOF LIBS="$LIBS -lsec" echo "configure: warning: This configuration is untested" 1>&2 else echo "$ac_t""no" 1>&6 cat >> confdefs.h <<\EOF #define DISABLE_SHADOW 1 EOF fi MANTYPE='$(CATMAN)' mansubdir=cat ;; Solution for login.c Missing an opening brace at line 213, added it. Code excerpt below: #if defined(HAVE_ADDR_IN_UTMPX) if (addr) { /* Added a brace here - Ged */ switch (addr->sa_family) { Solution for Makefile: Changed Makefile.in and added $(CFLAGS) to the compile lines for all the executables. Solution for sshd: HP-UX does not have a pam_getenvlist call. Changed the fetch_pam_environment function to return NULL if _HPUX_SOURCE was defined. /* Return list of PAM environment strings */ char **fetch_pam_environment(void) { #ifndef _HPUX_SOURCE /* HP-UX has not implemented this */ return(pam_getenvlist((pam_handle_t *)pamh)); #else return(NULL); #endif } Solution for long passwords: Need a couple of includes, namely and Added the following to defines.h #ifdef HAVE_HPUX_TRUSTED_SYSTEM_PW # include # include #endif Modified auth-passwd.c (not the most elegant fix, assumed HP will not use MD5 passwds if trusted). Code below: #ifdef HAVE_MD5_PASSWORDS if (is_md5_salt(salt)) encrypted_password = md5_crypt(password, salt); else encrypted_password = crypt(password, salt); #else /* HAVE_MD5_PASSWORDS */ # ifdef HAVE_HPUX_TRUSTED_SYSTEM_PW encrypted_password = bigcrypt(password, salt); # else encrypted_password = crypt(password, salt); #endif /* HAVE_HPUX_TRUSTED_SYSTEM_PW */ #endif /* HAVE_MD5_PASSWORDS */ Still some issues with man pages and warnings during compilation. Get syslog error=> error: ioctl I_PUSH ttcompat: Invalid argument Get syslog error=> Cannot delete credentials: Permission denied I had to have root permissions to run configure successfully as /tcb on my system has permissions 500 Run configure with (at least) --with-rsh=/usr/bin/remsh Thanks Ged Lodder -- lodder at yacc.com.au -- From winterlion at fsj.net Mon Feb 28 08:33:09 2000 From: winterlion at fsj.net (winterlion) Date: Sun, 27 Feb 2000 14:33:09 -0700 (MST) Subject: OpenSSH 1.2.2 and OpenSSL 0.9.4 Message-ID: I'm getting "error: Could not load host key: /usr/local/etc/ssh_host_key: Success" on two different systems (Caldera 2.3, Mandrake 6.0+a few fixes) I haven't been able to track it down any further (sshd.c; looks like it's looking for errno stuff but it's not set) Anyways, I'm not -yet- familiar with the operation of either package so any assistance would be most appreciated :) G'day, eh? :) - Winterlion Trying to bring truth from beauty is Winterlion. find at this winterlions' page From ache at nagual.pp.ru Sun Feb 27 11:01:49 2000 From: ache at nagual.pp.ru (Andrey A. Chernov) Date: Sun, 27 Feb 2000 03:01:49 +0300 Subject: [PATCH] Fix login.conf, expiration, BSD compatibility in OpenSSH Message-ID: <20000227030149.A6864@nagual.pp.ru> This patch revive almost all login.conf and password/account expiration features, makes OpenSSH more FreeBSD login compatible and fix non-critical memory leak. Please review and commit. --- sshd.c.old Fri Feb 25 08:23:45 2000 +++ sshd.c Sun Feb 27 02:53:33 2000 @@ -37,9 +37,8 @@ #endif /* LIBWRAP */ #ifdef __FreeBSD__ -#include -#include #define LOGIN_CAP +#define _PATH_CHPASS "/usr/bin/passwd" #endif /* __FreeBSD__ */ #ifdef LOGIN_CAP @@ -1246,6 +1245,7 @@ return 0; } } +#ifndef __FreeBSD__ /* FreeBSD handle it later */ /* Fail if the account's expiration time has passed. */ if (pw->pw_expire != 0) { struct timeval tv; @@ -1254,6 +1254,7 @@ if (tv.tv_sec >= pw->pw_expire) return 0; } +#endif /* !__FreeBSD__ */ /* We found no reason not to let this user try to log on... */ return 1; } @@ -1268,6 +1269,12 @@ struct passwd *pw, pwcopy; int plen, ulen; char *user; +#ifdef LOGIN_CAP + login_cap_t *lc; + char *hosts; + const char *from_host, *from_ip; + int denied; +#endif /* LOGIN_CAP */ /* Get the name of the user that we wish to log in as. */ packet_read_expect(&plen, SSH_CMSG_USER); @@ -1338,6 +1345,38 @@ packet_disconnect("ROOT LOGIN REFUSED FROM %.200s", get_canonical_hostname()); } + +#ifdef LOGIN_CAP + lc = login_getpwclass(pw); + if (lc == NULL) + lc = login_getclassbyname(NULL, pw); + from_host = get_canonical_hostname(); + from_ip = get_remote_ipaddr(); + + denied = 0; + if ((hosts = login_getcapstr(lc, "host.deny", NULL, NULL)) != NULL) { + denied = match_hostname(from_host, hosts, strlen(hosts)); + if (!denied) + denied = match_hostname(from_ip, hosts, strlen(hosts)); + } + if (!denied && + (hosts = login_getcapstr(lc, "host.allow", NULL, NULL)) != NULL) { + denied = !match_hostname(from_host, hosts, strlen(hosts)); + if (denied) + denied = !match_hostname(from_ip, hosts, strlen(hosts)); + } + login_close(lc); + if (denied) { + log("Denied connection for %.200s from %.200s [%.200s].", + pw->pw_name, from_host, from_ip); + packet_disconnect("Sorry, you are not allowed to connect."); + } +#endif /* LOGIN_CAP */ + + if (pw->pw_uid == 0) + log("ROOT LOGIN as '%.100s' from %.100s", + pw->pw_name, get_canonical_hostname()); + /* The user has been authenticated and accepted. */ packet_start(SSH_SMSG_SUCCESS); packet_send(); @@ -2086,6 +2125,11 @@ login_cap_t *lc; char *fname; #endif /* LOGIN_CAP */ +#ifdef __FreeBSD__ +#define DEFAULT_WARN (2L * 7L * 86400L) /* Two weeks */ + struct timeval tv; + time_t warntime = DEFAULT_WARN; +#endif /* __FreeBSD__ */ /* Get remote host name. */ hostname = get_canonical_hostname(); @@ -2157,6 +2201,50 @@ quiet_login = login_getcapbool(lc, "hushlogin", quiet_login); #endif /* LOGIN_CAP */ +#ifdef __FreeBSD__ + if (pw->pw_change || pw->pw_expire) + (void)gettimeofday(&tv, NULL); +#ifdef LOGIN_CAP + warntime = login_getcaptime(lc, "warnpassword", + DEFAULT_WARN, DEFAULT_WARN); +#endif /* LOGIN_CAP */ + /* + * If the password change time is set and has passed, give the + * user a password expiry notice and chance to change it. + */ + if (pw->pw_change != 0) { + if (tv.tv_sec >= pw->pw_change) { + (void)printf( + "Sorry -- your password has expired.\n"); + log("%s Password expired - forcing change", + pw->pw_name); + command = _PATH_CHPASS; + } else if (pw->pw_change - tv.tv_sec < warntime && + !quiet_login) + (void)printf( + "Warning: your password expires on %s", + ctime(&pw->pw_change)); + } +#ifdef LOGIN_CAP + warntime = login_getcaptime(lc, "warnexpire", + DEFAULT_WARN, DEFAULT_WARN); +#endif /* LOGIN_CAP */ + if (pw->pw_expire) { + if (tv.tv_sec >= pw->pw_expire) { + (void)printf( + "Sorry -- your account has expired.\n"); + log( + "LOGIN %.200s REFUSED (EXPIRED) FROM %.200s ON TTY %.200s", + pw->pw_name, hostname, ttyname); + exit(254); + } else if (pw->pw_expire - tv.tv_sec < warntime && + !quiet_login) + (void)printf( + "Warning: your account expires on %s", + ctime(&pw->pw_expire)); + } +#endif /* __FreeBSD__ */ + /* * If the user has logged in before, display the time of last * login. However, don't display anything extra if a command @@ -2203,10 +2291,9 @@ !options.use_login) { #ifdef LOGIN_CAP fname = login_getcapstr(lc, "welcome", NULL, NULL); - login_close(lc); if (fname == NULL || (f = fopen(fname, "r")) == NULL) f = fopen("/etc/motd", "r"); -#else /* LOGIN_CAP */ +#else /* !LOGIN_CAP */ f = fopen("/etc/motd", "r"); #endif /* LOGIN_CAP */ /* Print /etc/motd if it exists. */ @@ -2216,6 +2303,9 @@ fclose(f); } } +#ifdef LOGIN_CAP + login_close(lc); +#endif /* LOGIN_CAP */ /* Do common processing for the child, such as execing the command. */ do_child(command, pw, term, display, auth_proto, auth_data, ttyname); @@ -2363,7 +2453,7 @@ char buf[256]; FILE *f; unsigned int envsize, i; - char **env; + char **env = NULL; extern char **environ; struct stat st; char *argv[10]; @@ -2373,29 +2463,24 @@ lc = login_getpwclass(pw); if (lc == NULL) lc = login_getclassbyname(NULL, pw); -#endif /* LOGIN_CAP */ - + if (pw->pw_uid != 0) + auth_checknologin(lc); +#else /* !LOGIN_CAP */ f = fopen("/etc/nologin", "r"); -#ifdef __FreeBSD__ - if (f == NULL) - f = fopen("/var/run/nologin", "r"); -#endif /* __FreeBSD__ */ if (f) { /* /etc/nologin exists. Print its contents and exit. */ -#ifdef LOGIN_CAP - /* On FreeBSD, etc., allow overriding nologin via login.conf. */ - if (!login_getcapbool(lc, "ignorenologin", 0)) { -#else /* LOGIN_CAP */ - if (1) { -#endif /* LOGIN_CAP */ - while (fgets(buf, sizeof(buf), f)) - fputs(buf, stderr); - fclose(f); - if (pw->pw_uid != 0) - exit(254); - } + while (fgets(buf, sizeof(buf), f)) + fputs(buf, stderr); + fclose(f); + if (pw->pw_uid != 0) + exit(254); } +#endif /* LOGIN_CAP */ + +#ifdef LOGIN_CAP + if (options.use_login) +#endif /* LOGIN_CAP */ /* Set login name in the kernel. */ if (setlogin(pw->pw_name) < 0) error("setlogin failed: %s", strerror(errno)); @@ -2405,12 +2490,42 @@ switch, so we let login(1) to this for us. */ if (!options.use_login) { #ifdef LOGIN_CAP - if (setclasscontext(pw->pw_class, LOGIN_SETPRIORITY | - LOGIN_SETRESOURCES | LOGIN_SETUMASK) == -1) { - perror("setclasscontext"); - exit(1); - } -#endif /* LOGIN_CAP */ + char **tmpenv; + + /* Initialize temp environment */ + envsize = 64; + env = xmalloc(envsize * sizeof(char *)); + env[0] = NULL; + + child_set_env(&env, &envsize, "PATH", + (pw->pw_uid == 0) ? + _PATH_STDPATH : _PATH_DEFPATH); + + snprintf(buf, sizeof buf, "%.200s/%.50s", + _PATH_MAILDIR, pw->pw_name); + child_set_env(&env, &envsize, "MAIL", buf); + + if (getenv("TZ")) + child_set_env(&env, &envsize, "TZ", getenv("TZ")); + + /* Save parent environment */ + tmpenv = environ; + environ = env; + + if (setusercontext(lc, pw, pw->pw_uid, LOGIN_SETALL) < 0) + fatal("setusercontext failed: %s", strerror(errno)); + + /* Restore parent environment */ + env = environ; + environ = tmpenv; + + for (envsize = 0; env[envsize] != NULL; ++envsize) + ; + envsize = (envsize < 100) ? 100 : envsize + 16; + env = xrealloc(env, envsize * sizeof(char *)); + +#else /* !LOGIN_CAP */ + if (getuid() == 0 || geteuid() == 0) { if (setgid(pw->pw_gid) < 0) { perror("setgid"); @@ -2428,18 +2543,15 @@ } if (getuid() != pw->pw_uid || geteuid() != pw->pw_uid) fatal("Failed to set uids to %d.", (int) pw->pw_uid); +#endif /* LOGIN_CAP */ } /* * Get the shell from the password data. An empty shell field is * legal, and means /bin/sh. */ + shell = (pw->pw_shell[0] == '\0') ? _PATH_BSHELL : pw->pw_shell; #ifdef LOGIN_CAP - shell = pw->pw_shell; shell = login_getcapstr(lc, "shell", shell, shell); - if (shell[0] == '\0') - shell = _PATH_BSHELL; -#else /* LOGIN_CAP */ - shell = (pw->pw_shell[0] == '\0') ? _PATH_BSHELL : pw->pw_shell; #endif /* LOGIN_CAP */ #ifdef AFS @@ -2455,29 +2567,31 @@ #endif /* AFS */ /* Initialize the environment. */ - envsize = 100; - env = xmalloc(envsize * sizeof(char *)); - env[0] = NULL; + if (env == NULL) { + envsize = 100; + env = xmalloc(envsize * sizeof(char *)); + env[0] = NULL; + } if (!options.use_login) { /* Set basic environment. */ child_set_env(&env, &envsize, "USER", pw->pw_name); child_set_env(&env, &envsize, "LOGNAME", pw->pw_name); child_set_env(&env, &envsize, "HOME", pw->pw_dir); -#ifdef LOGIN_CAP - child_set_env(&env, &envsize, "PATH", - login_getpath(lc, "path", _PATH_STDPATH)); -#else /* LOGIN_CAP */ +#ifndef LOGIN_CAP child_set_env(&env, &envsize, "PATH", _PATH_STDPATH); -#endif /* LOGIN_CAP */ snprintf(buf, sizeof buf, "%.200s/%.50s", _PATH_MAILDIR, pw->pw_name); child_set_env(&env, &envsize, "MAIL", buf); +#endif /* !LOGIN_CAP */ /* Normal systems set SHELL by default. */ child_set_env(&env, &envsize, "SHELL", shell); } +#ifdef LOGIN_CAP + if (options.use_login) +#endif /* LOGIN_CAP */ if (getenv("TZ")) child_set_env(&env, &envsize, "TZ", getenv("TZ")); @@ -2559,10 +2673,6 @@ */ endpwent(); -#ifdef LOGIN_CAP - login_close(lc); -#endif /* LOGIN_CAP */ - /* * Close any extra open file descriptors so that we don\'t have them * hanging around in clients. Note that we want to do this after @@ -2573,9 +2683,46 @@ close(i); /* Change current directory to the user\'s home directory. */ - if (chdir(pw->pw_dir) < 0) + if ( +#ifdef __FreeBSD__ + !*pw->pw_dir || +#endif /* __FreeBSD__ */ + chdir(pw->pw_dir) < 0 + ) { +#ifdef __FreeBSD__ + int quiet_login = 0; +#endif /* __FreeBSD__ */ +#ifdef LOGIN_CAP + if (login_getcapbool(lc, "requirehome", 0)) { + (void)printf("Home directory not available\n"); + log("LOGIN %.200s REFUSED (HOMEDIR) ON TTY %.200s", + pw->pw_name, ttyname); + exit(254); + } +#endif /* LOGIN_CAP */ +#ifdef __FreeBSD__ + if (chdir("/") < 0) { + (void)printf("Cannot find root directory\n"); + log("LOGIN %.200s REFUSED (ROOTDIR) ON TTY %.200s", + pw->pw_name, ttyname); + exit(254); + } +#ifdef LOGIN_CAP + quiet_login = login_getcapbool(lc, "hushlogin", 0); +#endif /* LOGIN_CAP */ + if (!quiet_login || *pw->pw_dir) + (void)printf( + "No home directory.\nLogging in with home = \"/\".\n"); + +#else /* !__FreeBSD__ */ + fprintf(stderr, "Could not chdir to home directory %s: %s\n", pw->pw_dir, strerror(errno)); +#endif /* __FreeBSD__ */ + } +#ifdef LOGIN_CAP + login_close(lc); +#endif /* LOGIN_CAP */ /* * Must take new environment into use so that .ssh/rc, /etc/sshrc and @@ -2588,26 +2735,6 @@ * in this order). */ if (!options.use_login) { -#ifdef __FreeBSD__ - /* - * If the password change time is set and has passed, give the - * user a password expiry notice and chance to change it. - */ - if (pw->pw_change != 0) { - struct timeval tv; - - (void)gettimeofday(&tv, NULL); - if (tv.tv_sec >= pw->pw_change) { - (void)printf( - "Sorry -- your password has expired.\n"); - syslog(LOG_INFO, - "%s Password expired - forcing change", - pw->pw_name); - if (system("/usr/bin/passwd") != 0) - perror("/usr/bin/passwd"); - } - } -#endif /* __FreeBSD__ */ if (stat(SSH_USER_RC, &st) >= 0) { if (debug_flag) fprintf(stderr, "Running /bin/sh %s\n", SSH_USER_RC); @@ -2675,7 +2802,11 @@ mailbox = getenv("MAIL"); if (mailbox != NULL) { if (stat(mailbox, &mailstat) != 0 || mailstat.st_size == 0) +#ifdef __FreeBSD__ + ; +#else /* !__FreeBSD__ */ printf("No mail.\n"); +#endif /* __FreeBSD__ */ else if (mailstat.st_mtime < mailstat.st_atime) printf("You have mail.\n"); else -- Andrey A. Chernov http://nagual.pp.ru/~ache/ To Unsubscribe: send mail to majordomo at FreeBSD.org with "unsubscribe freebsd-current" in the body of the message From gem at rellim.com Tue Feb 29 05:56:00 2000 From: gem at rellim.com (Gary E. Miller) Date: Mon, 28 Feb 2000 10:56:00 -0800 (PST) Subject: SSH & xauth (fwd) Message-ID: YO All! Have you guys been following the SSH discussion on Bugtraq lately? I like their idea the X forwarding should be OFF by default on the client. RGDS GARY --------------------------------------------------------------------------- Gary E. Miller Rellim 20340 Empire Ave, Suite E-3, Bend, OR 97701 gem at rellim.com Tel:+1(541)382-8588 Fax: +1(541)382-8676 ---------- Forwarded message ---------- Date: Fri, 25 Feb 2000 21:52:15 -0500 From: Robert Watson Reply-To: Robert Watson To: BUGTRAQ at SECURITYFOCUS.COM Subject: Re: SSH & xauth This is a very round-about way of observing that allowing X11 forwarding from a client to any untrusted server (by any means -- sshd, xauth, common accounts, poor file permissions, compromised kernel, etc, etc) with the current SSH clients results in security problems (which you observe). What's more curious is that in OpenSSH, which I observed some time ago, the default configuration is to enable X11 forwarding in the client and disable it in the server. This is, of course, backwards, as the client is the one accepting risk by forwarding X11, not the server. :-) If you search back a few years in the bugtraq archives, you'll see that one suggestion for dealing with this, and still allowing X11 forwarding from untrusted clients, is to use the Xnest server, limiting access by the ssh client to that DISPLAY. As I observed at the time, Xnest was probably not designed with this use in mind, and as such is probably ``breakable,'' meaning that a pursuaded party might be able to gain access to the proper display through exploiting weaknesses in the Xnest server. I have not audited the Xnest code to verify that this is or is not the case. I believe at the time, Alan Cox responded with information about using the Broadway extensions to limit access by specific applications to other X11 applications, the X event queue, etc. These messages were circa 1997, and should appear in bugtraq archives. Presumably the correct configuration is for clients to disable X11 by default, and only have it enabled specifically by the user via appropriate flags to ssh, or via the config file. You could imagine a more comprehensive interface to new host key adoption that also inquired as to a trust level for X11 forwarding using Broadway, etc. In this manner, the user could specify ``limited'' access that would be sandboxed, not allowing access to screen data, X event queue access, etc, ``full,'' or ``none.'' With a little imagination, you could even imagine it spawning an Xnest to generate a sandbox for remote access. I would conclude by observing that this is *very* old news--the only new news is that it has not yet been ``fixed.'' Of course, there's a decent argument that many consumers of SSH are the kind of people who also blindly accept new hostkeys without verifying fingerprints or using a PKI, so this kind of default won't help them at all, just causing frustration. :-) If you want another puzzling OpenSSH tidbit, it's that the CheckIP option is enabled by default in the base implementation. It has recently been turned off in the FreeBSD version for the following reason (which was rejected by OpenSSH developers shortly after OpenSSH was released). The CheckHostIP feature introduces automatic modification of the known hosts key file to include the IP address of the host after connecting by name. This option introduces unnecessary modifications of keying material entries, and can cause spurious keying errors following IP address changes, especially in a dynamic DNS/IP allocation environment. When a user requests a connection by-name, the key storage should be by-name, as SSH is not aware of whether or not the name/key binding is persistent. Presumably, just as the user is responsible for performing by-name key verification and management, the user should also be responsible for managing by-number key verification and management. This also causes management problems for hosts employing centralized ssh_known_hosts entries--SSH replicates the key from the central file into the user's personal key file using the IP address to index the key. If the IP of the host is a variable IP, putting the IP into the centralized file makes no sense, but SSH will take the liberty of?replicating the keying material unnecessarily. If a host key now changes, and the centralized file is updated to reflect it, SSH will now generate warnings as its spuriously replicated key no longer matches up. You can even imagine DNS-based spoofing causing some problems, if combined with IP spoofing, as ssh-by-ip to a spoofed host would not generate an unknown key warning, instead, it would connect with full trust. This attack is a little of a stretch on convenience for the attacker, but is feasible. The end conclusion is really that key introduction for key indexes (names, IPs) should only occur when specifically authorized by the user and following a fingerprint display, never automatically. Robert N M Watson robert at fledge.watson.org http://www.watson.org/~robert/ PGP key fingerprint: AF B5 5F FF A6 4A 79 37 ED 5F 55 E9 58 04 6A B1 TIS Labs at Network Associates, Safeport Network Services On Thu, 24 Feb 2000, Brian Caswell wrote: > The default SSH configuration for SSH1 and SSH2 allow for remote > controlling of X sessions through X forwarding. > > All children of the SSH connection are able to tunnel X11 sessions > through the X tunnel to the client X11 session. This is accomplished > by running xauth upon logging in. > > If xauth is replaced on the server by a malicious program that does > both of the following: > - runs xauth, adding in the "correct" information allowing the > children of the session to tunnel X11 programs through the SSH > session > - runs xauth, adding in the "malicious" information, allowing a > malicious source to tunnel X11 programs through the SSH session. > > With the added data in .Xauthority, a malicious source can fully control > the client X session. The malicious source can then do most anything to > the X session, from logging keystrokes of the X session, to taking > screen captures, to typing in commands to open terminals. > > The only thing that is required for the client system to be compromised > is for the client to remotely log via ssh (with X11 forwarding enabled) > into a compromised server. > > Allowing X forwarding seems to be turned on by default in SSH1, SSH2, > and OpenSSH. > > To fix this "issue" add the following lines to the SSH client > configuration. ($HOME/.ssh/config or ssh_config) > > > Host * > ForwardX11 no > > > Discussions of security flaws within X11 have been going on for years. > The "issue" in SSH X11 forwarding is not new. SSH has added to the > security of X11, but by no means does the use of SSH secure X11. > > -- > Brian Caswell > If I could load the world into vi, the first command I would use is: > %s/Windows NT//gi From djm at mindrot.org Tue Feb 29 08:17:52 2000 From: djm at mindrot.org (Damien Miller) Date: Tue, 29 Feb 2000 08:17:52 +1100 (EST) Subject: SSH & xauth (fwd) In-Reply-To: Message-ID: On Mon, 28 Feb 2000, Gary E. Miller wrote: > YO All! > > Have you guys been following the SSH discussion on Bugtraq lately? > > I like their idea the X forwarding should be OFF by default on the > client. In the default config which ships with 1.2.2 it is. -d -- | "Bombay is 250ms from New York in the new world order" - Alan Cox | Damien Miller - http://www.mindrot.org/ | Email: djm at mindrot.org (home) -or- djm at ibs.com.au (work) From chrismcc at netus.com Tue Feb 29 12:58:16 2000 From: chrismcc at netus.com (Christopher McCrory) Date: Mon, 28 Feb 2000 17:58:16 -0800 Subject: openssh-1.2.2 with openssl-0.9.5 rsa problem Message-ID: <38BB27B8.40627717@netus.com> Hello... to openssh-unix-dev at mindrot.org cc djm at ibs.com.au devel platform: linux intel redhat 6.2beta http://violet.ibs.com.au/openssh/files/openssh-1.2.2.tar.gz from rpm at same. I am NOT subscribed to the openssh-unix-dev list. I ran into a problem using openssh-1.2.2 with openssl-0.9.5. With openssl 0.9.5 you can now compile shared libraries without idea, rc5 and rsa. openssl compiled with: ./config no-rc5 no-idea -DRSA_NULL results in libraries without rc5 and idea and (AFAIK) with the patented parts of rsa removed. compiled and installed this way openssh compiles and installs fine. When run there are errors though. specifically: rsa_public_encrypt() failed on the client side or rsa_private_decrypt() failed on the server side ------------------actual sample------------- ( squid is known working version from violet rpms, wednesday is new test version) [squid at chrismcc]$ slogin -v wednesday SSH Version OpenSSH-1.2.2, protocol version 1.5. Compiled with SSL. debug: Reading configuration data /etc/ssh/ssh_config debug: ssh_connect: getuid 114 geteuid 0 anon 0 debug: Connecting to wednesday.netus.com [209.95.208.9] port 22. debug: Allocated local port 621. debug: Connection established. debug: Remote protocol version 1.5, remote software version OpenSSH-1.2.2 debug: Waiting for server public key. debug: Received server public key (768 bits) and host key (1024 bits). debug: Host 'wednesday.netus.com' is known and matches the host key. debug: Encryption type: 3des debug: Sent encrypted session key. Connection closed by 209.95.208.9 debug: Calling cleanup 0x80560b0(0x0) user chrismcc Mon Feb 28 on squid in ~ ------------------------ server syslog says: Feb 28 17:02:04 wednesday sshd[15363]: fatal: rsa_private_decrypt() failed [squid at chrismcc]$ rpm -qa | grep openss openssh-1.2.2-1 openssh-askpass-1.2.2-1 openssh-clients-1.2.2-1 openssh-server-1.2.2-1 openssl-0.9.4-3 ( rpms are from violet ) ----another [wednesday at chrismcc]$ slogin wednesday rsa_public_encrypt() failed user chrismcc Mon Feb 28 on wednesday in ~ [wednesday at chrismcc]$ server says: Feb 28 17:05:19 wednesday sshd[17036]: Connection closed by 209.95.208.9 after looking at the openssh source code (I am not a programer though) it seems that an the keyexchange point if rsa fails it should, IMHO, fall through to dsa(?) or something else. -- Christopher McCrory Lead Bithead, Netus Inc. chrismcc at netus.com admin at netus.com "Linux: Because rebooting is for adding new hardware" From markus.friedl at informatik.uni-erlangen.de Tue Feb 29 19:22:48 2000 From: markus.friedl at informatik.uni-erlangen.de (Markus Friedl) Date: Tue, 29 Feb 2000 09:22:48 +0100 Subject: openssh-1.2.2 with openssl-0.9.5 rsa problem In-Reply-To: <38BB27B8.40627717@netus.com>; from chrismcc@netus.com on Mon, Feb 28, 2000 at 05:58:16PM -0800 References: <38BB27B8.40627717@netus.com> Message-ID: <20000229092248.A15550@folly.informatik.uni-erlangen.de> On Mon, Feb 28, 2000 at 05:58:16PM -0800, Christopher McCrory wrote: > after looking at the openssh source code (I am not a programer though) > it seems that an the keyexchange point if rsa fails it should, IMHO, > fall through to dsa(?) or something else. no. for OpenSSH-1.2.2 you need RSA in openssl. version 2 of the SSH protocol supports DSA, but OpenSSH-1.2.2 implements SSH1 only.