From f15629682c5682f173c3932f43c5a5ad09160cf1 Mon Sep 17 00:00:00 2001 From: Bryan Ashby Date: Tue, 29 Jan 2019 20:36:45 -0700 Subject: [PATCH] Fix outstanding SSH bug seen with NetRunner and SyncTERM with ugly hack: Disable keep-alives --- core/servers/login/ssh.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/core/servers/login/ssh.js b/core/servers/login/ssh.js index c94267c4..d13acf4b 100644 --- a/core/servers/login/ssh.js +++ b/core/servers/login/ssh.js @@ -321,6 +321,13 @@ exports.getModule = class SSHServerModule extends LoginServerModule { algorithms : config.loginServers.ssh.algorithms, }; + // + // This is a terrible hack, and we should not have to do it; + // However, as of this writing, NetRunner and SyncTERM both + // fail to respond to OpenSSH keep-alive pings (keepalive@openssh.com) + // + ssh2.Server.KEEPALIVE_INTERVAL = 0; + this.server = ssh2.Server(serverConf); this.server.on('connection', (conn, info) => { Log.info(info, 'New SSH connection');