Eugeny / russh

Rust SSH client & server library
https://docs.rs/russh
945 stars 103 forks source link

Unclear interaction between inactivity timer and server keepalive #316

Open gleason-m opened 3 months ago

gleason-m commented 3 months ago

I'll preface this by saying that I do not know SSH well enough to know if this is a feature or a bug.

I have a russh client configured with an inactivity timeout of 60s. The server we're communicating with sends keepalives every 15s. My expectation is the session would be dropped after 60s, but this does not happen as the client is responding to the keepalives and this response resets the inactivity timer.

I see that sending a keepalive request does not reset the inactivity timer, so should it be true that responding to a keepalive does reset the timer?