Skip to content

Commit

Permalink
sftp: log ip on inbound connection failure
Browse files Browse the repository at this point in the history
  • Loading branch information
matthewpi committed Dec 3, 2023
1 parent d30ab7b commit 579278b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sftp/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ func (c *SFTPServer) Run() error {
go func(conn net.Conn) {
defer conn.Close()
if err := c.AcceptInbound(conn, conf); err != nil {
log.WithField("error", err).Error("sftp: failed to accept inbound connection")
log.WithField("error", err).WithField("ip", conn.RemoteAddr().String()).Error("sftp: failed to accept inbound connection")
}
}(conn)
}
Expand Down

0 comments on commit 579278b

Please sign in to comment.