Commit Graph

117 Commits

Author SHA1 Message Date
Darren Tucker c7a6fc41bf - avsm@cvs.openbsd.org 2004/08/11 21:43:05
[channels.c channels.h clientloop.c misc.c misc.h serverloop.c ssh-agent.c]
     some signed/unsigned int comparison cleanups; markus@ ok
2004-08-13 21:18:00 +10:00
Darren Tucker e7066dfde3 - djm@cvs.openbsd.org 2004/05/21 11:33:11
[channels.c channels.h clientloop.c serverloop.c ssh.1]
     bz #756: add support for the cancel-tcpip-forward request for the server and
     the client (through the ~C commandline). reported by z3p AT twistedmatrix.com;
     ok markus@
2004-05-24 10:18:05 +10:00
Damien Miller fb1310eded - markus@cvs.openbsd.org 2004/01/19 21:25:15
[auth2-hostbased.c auth2-pubkey.c serverloop.c ssh-keysign.c sshconnect2.c]
     fix mem leaks; some fixes from Pete Flugstad; tested dtucker@
2004-01-21 11:02:50 +11:00
Damien Miller b5820f40bf 20031217
- (djm) OpenBSD CVS Sync
   - markus@cvs.openbsd.org 2003/12/09 15:28:43
     [serverloop.c]
     make ClientKeepAlive work for ssh -N, too (no login shell requested).
     1) send a bogus channel request if we find a channel
     2) send a bogus global request if we don't have a channel
     ok + test beck@
2003-12-17 16:27:32 +11:00
Damien Miller 4bb1dd3166 - (djm) OpenBSD CVS Sync
- dtucker@cvs.openbsd.org 2003/11/18 00:40:05
     [serverloop.c]
     Correct check for authctxt->valid.  ok djm@
2003-11-18 22:01:25 +11:00
Damien Miller 3e3b5145e5 - djm@cvs.openbsd.org 2003/11/04 08:54:09
[auth1.c auth2.c auth2-pubkey.c auth.h auth-krb5.c auth-passwd.c]
     [auth-rhosts.c auth-rh-rsa.c auth-rsa.c monitor.c serverloop.c]
     [session.c]
     standardise arguments to auth methods - they should all take authctxt.
     check authctxt->valid rather then pw != NULL; ok markus@
2003-11-17 21:13:40 +11:00
Darren Tucker 3e33cecf71 - markus@cvs.openbsd.org 2003/09/23 20:17:11
[Makefile.in auth1.c auth2.c auth.c auth.h auth-krb5.c canohost.c
     cleanup.c clientloop.c fatal.c gss-serv.c log.c log.h monitor.c monitor.h
     monitor_wrap.c monitor_wrap.h packet.c serverloop.c session.c session.h
     ssh-agent.c sshd.c]
     replace fatal_cleanup() and linked list of fatal callbacks with static
     cleanup_exit() function.  re-refine cleanup_exit() where appropriate,
     allocate sshd's authctxt eary to allow simpler cleanup in sshd.
     tested by many, ok deraadt@
2003-10-02 16:12:36 +10:00
Darren Tucker 502d384b74 - markus@cvs.openbsd.org 2003/06/24 08:23:46
[auth2-hostbased.c auth2-pubkey.c auth2.c channels.c key.c key.h
      monitor.c packet.c packet.h serverloop.c sshconnect2.c sshd.c]
     int -> u_int; ok djm@, deraadt@, mouring@
2003-06-28 12:38:01 +10:00
Damien Miller 9fc7c699af - djm@cvs.openbsd.org 2003/06/04 12:03:59
[serverloop.c]
     remove bitrotten commet; ok markus@
2003-06-04 22:50:54 +10:00
Damien Miller b1ca8bb159 - markus@cvs.openbsd.org 2003/05/11 20:30:25
[channels.c clientloop.c serverloop.c session.c ssh.c]
     make channel_new() strdup the 'remote_name' (not the caller); ok theo
2003-05-14 13:45:42 +10:00
Damien Miller a5539d2698 - (djm) OpenBSD CVS Sync
- markus@cvs.openbsd.org 2003/04/02 09:48:07
     [clientloop.c monitor.c monitor_wrap.c packet.c packet.h readconf.c]
     [readconf.h serverloop.c sshconnect2.c]
     reapply rekeying chage, tested by henning@, ok djm@
2003-04-09 20:50:06 +10:00
Damien Miller 2dc074ef4b - markus@cvs.openbsd.org 2003/04/01 10:10:23
[clientloop.c monitor.c monitor_wrap.c packet.c packet.h readconf.c]
     [readconf.h serverloop.c sshconnect2.c]
     rekeying bugfixes and automatic rekeying:
     * both client and server rekey _automatically_
           (a) after 2^31 packets, because after 2^32 packets
               the sequence number for packets wraps
           (b) after 2^(blocksize_in_bits/4) blocks
       (see: draft-ietf-secsh-newmodes-00.txt)
       (a) and (b) are _enabled_ by default, and only disabled for known
       openssh versions, that don't support rekeying properly.
     * client option 'RekeyLimit'
     * do not reply to requests during rekeying
   - markus@cvs.openbsd.org 2003/04/01 10:22:21
     [clientloop.c monitor.c monitor_wrap.c packet.c packet.h readconf.c]
     [readconf.h serverloop.c sshconnect2.c]
     backout rekeying changes (for 3.6.1)
2003-04-01 21:43:39 +10:00
Tim Rice 81ed518b9b Cray fixes (bug 367) based on patch from Wendy Palm @ cray.
This does not include the deattack.c fixes.
2002-09-25 17:38:46 -07:00
Damien Miller 16aed05578 - stevesk@cvs.openbsd.org 2002/09/19 16:03:15
[serverloop.c]
     log IP address also; ok markus@
2002-09-22 01:26:27 +10:00
Ben Lindstrom 99a4e14fe0 - (bal) NO_IPPORT_RESERVED_CONCEPT used instead of CYGWIN so other platforms
lacking that concept can share it. Patch by vinschen@redhat.com
2002-07-09 14:06:40 +00:00
Ben Lindstrom 4fed2be856 - markus@cvs.openbsd.org 2002/06/24 14:33:27
[channels.c channels.h clientloop.c serverloop.c]
     move channel counter to u_int
2002-06-25 23:17:36 +00:00
Ben Lindstrom ce0f634270 - mpech@cvs.openbsd.org 2002/06/11 05:46:20
[auth-krb4.c monitor.h serverloop.c session.c ssh-agent.c sshd.c]
     pid_t cleanup. Markus need this now to keep hacking.
     markus@, millert@ ok
2002-06-11 16:42:49 +00:00
Ben Lindstrom 47fd8112b5 - markus@cvs.openbsd.org 2002/03/30 18:51:15
[monitor.c serverloop.c sftp-int.c sftp.c sshd.c]
     check waitpid for EINTR; based on patch from peter@ifm.liu.se
2002-04-02 20:48:19 +00:00
Ben Lindstrom 3dc40f997b - markus@cvs.openbsd.org 2002/03/24 16:00:27
[serverloop.c]
     remove unused debug
2002-03-26 02:01:30 +00:00
Ben Lindstrom 7a2073c50b - provos@cvs.openbsd.org 2002/03/18 17:50:31
[auth-bsdauth.c auth-options.c auth-rh-rsa.c auth-rsa.c auth-skey.c auth.h
      auth1.c auth2-chall.c auth2.c kex.c kex.h kexdh.c kexgex.c servconf.c
      session.h servconf.h serverloop.c session.c sshd.c]
     integrate privilege separated openssh; its turned off by default for now.
     work done by me and markus@

applied, but outside of ensure that smaller code bits migrated with
their owners.. no work was tried to 'fix' it to work. =)  Later project!
2002-03-22 02:30:41 +00:00
Damien Miller 699d003e3a - markus@cvs.openbsd.org 2002/02/06 14:55:16
[channels.c clientloop.c serverloop.c ssh.c]
     channel_new never returns NULL, mouring@; ok djm@
2002-02-08 22:07:16 +11:00
Damien Miller c7ef63dd41 - markus@cvs.openbsd.org 2002/02/03 17:53:25
[auth1.c serverloop.c session.c session.h]
     don't use channel_input_channel_request and callback
     use new server_input_channel_req() instead:
     	server_input_channel_req does generic request parsing on server side
     	session_input_channel_req handles just session specific things now
     ok djm@
2002-02-05 12:21:42 +11:00
Damien Miller 664d6b9a8e - markus@cvs.openbsd.org 2002/01/31 15:00:05
[serverloop.c]
     no need for WNOHANG; ok stevesk@
2002-02-05 12:20:16 +11:00
Damien Miller b16461ce45 - markus@cvs.openbsd.org 2002/01/16 13:17:51
[channels.c channels.h serverloop.c ssh.c]
     wrapper for channel_setup_fwd_listener
2002-01-22 23:29:22 +11:00
Damien Miller 056cf73d35 - markus@cvs.openbsd.org 2002/01/10 11:13:29
[serverloop.c]
     skip client_alive_check until there are channels; ok beck@
2002-01-22 23:21:39 +11:00
Damien Miller 630d6f4479 - markus@cvs.openbsd.org 2001/12/28 15:06:00
[auth2.c auth2-chall.c channels.c channels.h clientloop.c dispatch.c dispatch.h kex.c kex.h serverloop.c ssh.c sshconnect2.c]
     remove plen from the dispatch fn. it's no longer used.
2002-01-22 23:17:30 +11:00
Damien Miller dff5099f13 - markus@cvs.openbsd.org 2001/12/28 14:50:54
[auth1.c auth-rsa.c channels.c dispatch.c kex.c kexdh.c kexgex.c packet.c packet.h serverloop.c session.c ssh.c sshconnect1.c sshconnect2.c sshd.c]
     packet_read* no longer return the packet length, since it's not used.
2002-01-22 23:16:32 +11:00
Damien Miller 48b03fc546 - markus@cvs.openbsd.org 2001/12/27 20:39:58
[auth1.c auth-rsa.c channels.c clientloop.c packet.c packet.h serverloop.c session.c ssh.c sshconnect1.c sshd.c ttymodes.c]
     get rid of packet_integrity_check, use packet_done() instead.
2002-01-22 23:11:40 +11:00
Damien Miller 66823cddbe - markus@cvs.openbsd.org 2001/12/27 20:39:58
[auth1.c auth-rsa.c channels.c clientloop.c packet.c packet.h serverloop.c session.c ssh.c sshconnect1.c sshd.c ttymodes.c]
     get rid of packet_integrity_check, use packet_done() instead.
2002-01-22 23:11:38 +11:00
Damien Miller 7c31809c4a - markus@cvs.openbsd.org 2001/12/21 12:17:33
[serverloop.c]
     remove ifdef for USE_PIPES since fdin != fdout; ok djm@
2002-01-22 23:06:22 +11:00
Damien Miller 278f907a2d - djm@cvs.openbsd.org 2001/12/20 22:50:24
[auth2.c auth2-chall.c channels.c channels.h clientloop.c dispatch.c]
     [dispatch.h kex.c kex.h packet.c packet.h serverloop.c ssh.c]
     [sshconnect2.c]
     Conformance fix: we should send failing packet sequence number when
     responding with a SSH_MSG_UNIMPLEMENTED message. Spotted by
     yakk@yakk.dot.net; ok markus@
2001-12-21 15:00:19 +11:00
Damien Miller f6681a3a96 - markus@cvs.openbsd.org 2001/12/19 16:09:39
[serverloop.c]
     fix race between SIGCHLD and select with an additional pipe.  writing
     to the pipe on SIGCHLD wakes up select(). using pselect() is not
     portable and siglongjmp() ugly. W. R. Stevens suggests similar solution.
     initial idea by pmenage@ensim.com; ok deraadt@, djm@
2001-12-21 14:53:11 +11:00
Damien Miller 9f0f5c64bc - deraadt@cvs.openbsd.org 2001/12/19 07:18:56
[auth1.c auth2.c auth2-chall.c auth-bsdauth.c auth.c authfile.c auth.h]
     [auth-krb4.c auth-rhosts.c auth-skey.c bufaux.c canohost.c channels.c]
     [cipher.c clientloop.c compat.c compress.c deattack.c key.c log.c mac.c]
     [match.c misc.c nchan.c packet.c readconf.c rijndael.c rijndael.h scard.c]
     [servconf.c servconf.h serverloop.c session.c sftp.c sftp-client.c]
     [sftp-glob.c sftp-int.c sftp-server.c ssh-add.c ssh-agent.c ssh.c]
     [sshconnect1.c sshconnect2.c sshconnect.c sshd.8 sshd.c sshd_config]
     [ssh-keygen.c sshlogin.c sshpty.c sshtty.c ttymodes.c uidswap.c]
     basic KNF done while i was looking for something else
2001-12-21 14:45:46 +11:00
Ben Lindstrom f8f065bc75 - itojun@cvs.openbsd.org 2001/12/05 03:50:01
[clientloop.c serverloop.c sshd.c]
     deal with LP64 printf issue with sig_atomic_t.  from thorpej
2001-12-06 17:52:16 +00:00
Ben Lindstrom 5e71c54b8c - markus@cvs.openbsd.org 2001/11/22 12:34:22
[clientloop.c serverloop.c sshd.c]
     volatile sig_atomic_t
2001-12-06 16:48:14 +00:00
Damien Miller 79faeff2c1 - markus@cvs.openbsd.org 2001/11/09 18:59:23
[clientloop.c serverloop.c]
     don't memset too much memory, ok millert@
     original patch from jlk@kamens.brookline.ma.us via nalin@redhat.com
2001-11-12 11:06:32 +11:00
Damien Miller 3ec2759ad4 - (djm) OpenBSD CVS Sync
- markus@cvs.openbsd.org 2001/10/10 22:18:47
     [channels.c channels.h clientloop.c nchan.c serverloop.c]
     [session.c session.h]
     try to keep channels open until an exit-status message is sent.
     don't kill the login shells if the shells stdin/out/err is closed.
     this should now work:
     ssh -2n localhost 'exec > /dev/null 2>&1; sleep 10; exit 5'; echo ?
2001-10-12 11:35:04 +10:00
Damien Miller 52b77beb65 - markus@cvs.openbsd.org 2001/10/09 21:59:41
[channels.c channels.h serverloop.c session.c session.h]
     simplify session close: no more delayed session_close, no more blocking wait() calls.
2001-10-10 15:14:37 +10:00
Damien Miller c71f4e40b6 - markus@cvs.openbsd.org 2001/10/09 19:51:18
[serverloop.c]
     close all channels if the connection to the remote host has been closed,
     should fix sshd's hanging with WCHAN==wait
2001-10-10 15:08:36 +10:00
Damien Miller 8c3902afde - markus@cvs.openbsd.org 2001/10/04 15:12:37
[serverloop.c]
     client_alive_check cleanup
2001-10-10 15:01:40 +10:00
Damien Miller af5f2e641c - markus@cvs.openbsd.org 2001/10/04 15:05:40
[channels.c serverloop.c]
     comment out bogus conditions for selecting on connection_in
2001-10-10 15:01:16 +10:00
Ben Lindstrom 6d218f404f - markus@cvs.openbsd.org 2001/09/17 21:04:02
[channels.c serverloop.c]
     don't send fake dummy packets on CR (\r)
     bugreport from yyua@cs.sfu.ca via solar@@openwall.com
2001-09-18 05:53:12 +00:00
Kevin Steves e26a155415 - (stevesk) use mysignal() in protocol 1 loop now that the SIGCHLD
handler has converged.
2001-07-26 17:51:49 +00:00
Ben Lindstrom 16d29d57e8 - markus@cvs.openbsd.org 2001/07/17 21:04:58
[channels.c channels.h clientloop.c nchan.c serverloop.c]
     keep track of both maxfd and the size of the malloc'ed fdsets.
     update maxfd if maxfd gets closed.
2001-07-18 16:01:46 +00:00
Ben Lindstrom 36857f6b8b - markus@cvs.openbsd.org 2001/07/15 16:17:08
[serverloop.c]
     schedule client alive for ssh2 only, greg@cheers.bungi.com
2001-07-18 15:48:57 +00:00
Ben Lindstrom 809744e912 - markus@cvs.openbsd.org 2001/07/02 22:52:57
[channels.c channels.h serverloop.c]
     improve cleanup/exit logic in ssh2:
     stop listening to channels, detach channel users (e.g. sessions).
     wait for children (i.e. dying sessions), send exit messages,
     cleanup all channels.
2001-07-04 05:26:06 +00:00
Ben Lindstrom 4983d5ebd5 - markus@cvs.openbsd.org 2001/07/02 13:59:15
[serverloop.c session.c session.h]
     wait until !session_have_children(); bugreport from
     Lutz.Jaenicke@aet.TU-Cottbus.DE
2001-07-04 05:17:40 +00:00
Ben Lindstrom bddd551e11 - markus@cvs.openbsd.org 2001/06/27 02:12:54
[serverloop.c serverloop.h session.c session.h]
     quick hack to make ssh2 work again.
2001-07-04 04:53:53 +00:00
Ben Lindstrom 4469723325 - markus@cvs.openbsd.org 2001/06/25 08:25:41
[channels.c channels.h cipher.c clientloop.c compat.c compat.h
      hostfile.c kex.c kex.h key.c key.h nchan.c packet.c serverloop.c
      session.c session.h sftp-server.c ssh-add.c ssh-agent.c uuencode.h]
     update copyright for 2001
2001-07-04 03:32:30 +00:00
Ben Lindstrom bba81213b9 - itojun@cvs.openbsd.org 2001/06/23 15:12:20
[auth1.c auth2.c auth2-chall.c authfd.c authfile.c auth-rhosts.c
      canohost.c channels.c cipher.c clientloop.c deattack.c dh.c
      hostfile.c kex.c kexdh.c kexgex.c key.c nchan.c packet.c radix.c
      readpass.c scp.c servconf.c serverloop.c session.c sftp.c
      sftp-client.c sftp-glob.c sftp-int.c sftp-server.c ssh-add.c
      ssh-agent.c ssh.c sshconnect1.c sshconnect2.c sshconnect.c sshd.c
      ssh-keygen.c ssh-keyscan.c]
     more strict prototypes.  raise warning level in Makefile.inc.
     markus ok'ed
     TODO; cleanup headers
2001-06-25 05:01:22 +00:00