[Bug 1338] New: Idletimeout for both client and server

bugzilla-daemon at bugzilla.mindrot.org bugzilla-daemon at bugzilla.mindrot.org
Wed Jul 11 03:09:38 EST 2007


http://bugzilla.mindrot.org/show_bug.cgi?id=1338

           Summary: Idletimeout for both client and server
           Product: Portable OpenSSH
           Version: 4.6p1
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: ssh
        AssignedTo: bitbucket at mindrot.org
        ReportedBy: wmertens at cisco.com


Created an attachment (id=1323)
 --> (http://bugzilla.mindrot.org/attachment.cgi?id=1323)
IdleTimeout option for ssh & sshd

Hi,

I took the idletimeout patch for sshd that Jani Jaakkola
<jjaakkol at cs.helsinki.fi> made in 2001
(http://marc.info/?l=openssh-unix-dev&m=99838019319356&w=2) and updated
it to work with 4.6p1. Then I added support for ssh as well.

With this patch, an IdleTimeout option is added to both ssh and sshd,
which disconnects when no traffic has passed for a predefined time.
Time can be specified in seconds, minutes, hours, etc using character
modifiers.

The idea is to combine this patch with the ControlPersist patch (#1330)
and create an easy way to have persistent ssh connections that clean up
automatically. This speeds up scripts and generic admin work.

Some comments:

   * In 2001 the code in packet.c was not organized like it is now with
wrapper functions calling ssh1/ssh2 versions. I think I put calls to
idletimeout_check() in the right places but I could have missed one or
added too much.

   * For the writing case, I added an idletimeout_check() in
packet_start instead of in the packet_send, assuming that packet_send
will be called soon after packet_start.

   * If this patch is combined with the ControlPersist patch, it should
be possible request that ssh only performs the timeout when ssh is
daemonized as a master. This could be done by making ControlPersist
take the same time value that IdleTimeout does. I'd be happy to code
that?


-- 
Configure bugmail: http://bugzilla.mindrot.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.


More information about the openssh-bugs mailing list