mirror of
https://github.com/drakkan/sftpgo.git
synced 2025-12-07 06:40:54 +03:00
add support for anonymous users
Fixes #935 Signed-off-by: Nicola Murino <nicola.murino@gmail.com>
This commit is contained in:
@@ -232,6 +232,8 @@ func (s *Server) PreAuthUser(cc ftpserver.ClientContext, username string) error
|
||||
return nil
|
||||
}
|
||||
if _, ok := err.(*util.RecordNotFoundError); !ok {
|
||||
logger.Error(logSender, fmt.Sprintf("%v_%v_%v", common.ProtocolFTP, s.ID, cc.ID()),
|
||||
"unable to get user on pre auth: %v", err)
|
||||
return common.ErrInternalFailure
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user