Skip to content

Commit 5fa2ddf

Browse files
authored
Lower parse error log level to debug (#8)
1 parent b79aae8 commit 5fa2ddf

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

internal/sshproxy/server.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -429,6 +429,11 @@ func handleConnectionError(ctx context.Context, err error) {
429429
"unmarshal error",
430430
// https://github.com/golang/crypto/blob/982eaa62dfb7273603b97fc1835561450096f3bd/ssh/common.go#L382
431431
"unexpected message type",
432+
// https://github.com/golang/crypto/blob/982eaa62dfb7273603b97fc1835561450096f3bd/ssh/common.go#L387
433+
// All errors collected in the wild are about `SSH_MSG_USERAUTH_REQUEST` (50), see `serverAuthenticate()`:
434+
// https://github.com/golang/crypto/blob/982eaa62dfb7273603b97fc1835561450096f3bd/ssh/server.go#L530
435+
// but we suppress all such errors as any malformed message is suspicious, esp. during authentication
436+
"parse error in message type",
432437
} {
433438
if strings.Contains(errMsg, msg) {
434439
logger.WithError(err).Debug("suspicious client")

0 commit comments

Comments
 (0)