From e9d2f3581cb14475a325ca7c64779c7eba41437d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torjus=20H=C3=A5kestad?= Date: Wed, 28 Sep 2022 12:36:16 +0200 Subject: [PATCH] Add debug log to ssh connection init --- honeypot/ssh/server.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/honeypot/ssh/server.go b/honeypot/ssh/server.go index a3bade8..d948645 100644 --- a/honeypot/ssh/server.go +++ b/honeypot/ssh/server.go @@ -115,6 +115,9 @@ func (hs *HoneypotServer) passwordHandler(ctx sshlib.Context, password string) b } func (s *HoneypotServer) connCallback(ctx sshlib.Context, conn net.Conn) net.Conn { + s.Logger.Debugw("Connection received.", "remote_addr", conn.RemoteAddr()) + conn.RemoteAddr() + throttledConn := newThrottledConn(conn) throttledConn.SetSpeed(s.throttleSpeed) ctx.SetValue("uuid", throttledConn.ID)