mirror of
https://github.com/drakkan/sftpgo.git
synced 2025-12-07 23:00:55 +03:00
redact credentials within hooks
go-retryablehttp does not redact credentials, so we still log them when we use it https://github.com/hashicorp/go-retryablehttp/pull/133
This commit is contained in:
@@ -145,7 +145,9 @@ func (s *Service) startServices() {
|
||||
|
||||
if sftpdConf.ShouldBind() {
|
||||
go func() {
|
||||
logger.Debug(logSender, "", "initializing SFTP server with config %+v", sftpdConf)
|
||||
redactedConf := sftpdConf
|
||||
redactedConf.KeyboardInteractiveHook = utils.GetRedactedURL(sftpdConf.KeyboardInteractiveHook)
|
||||
logger.Debug(logSender, "", "initializing SFTP server with config %+v", redactedConf)
|
||||
if err := sftpdConf.Initialize(s.ConfigDir); err != nil {
|
||||
logger.Error(logSender, "", "could not start SFTP server: %v", err)
|
||||
logger.ErrorToConsole("could not start SFTP server: %v", err)
|
||||
|
||||
Reference in New Issue
Block a user