mirror of
https://github.com/drakkan/sftpgo.git
synced 2025-12-08 23:28:39 +03:00
feat: make MFA status visible in WebAdmin (#844)
Signed-off-by: Tim Birkett <tim.birkett@sainsburys.co.uk>
This commit is contained in:
@@ -1331,6 +1331,15 @@ func (u *User) GetBandwidthAsString() string {
|
||||
return result
|
||||
}
|
||||
|
||||
// GetMFAStatusAsString returns MFA status
|
||||
func (u *User) GetMFAStatusAsString() string {
|
||||
result := "-"
|
||||
if u.Filters.TOTPConfig.Enabled {
|
||||
result = strings.Join(u.Filters.TOTPConfig.Protocols, ", ")
|
||||
}
|
||||
return result
|
||||
}
|
||||
|
||||
// GetInfoString returns user's info as string.
|
||||
// Storage provider, number of public keys, max sessions, uid,
|
||||
// gid, denied and allowed IP/Mask are returned
|
||||
|
||||
Reference in New Issue
Block a user