summaryrefslogtreecommitdiffstats
path: root/models/user/user.go
diff options
context:
space:
mode:
Diffstat (limited to 'models/user/user.go')
-rw-r--r--models/user/user.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/models/user/user.go b/models/user/user.go
index 7e3ae388fb..915e4243cf 100644
--- a/models/user/user.go
+++ b/models/user/user.go
@@ -401,7 +401,7 @@ func hashPassword(passwd, salt, algo string) (string, error) {
tempPasswd = pbkdf2.Key([]byte(passwd), saltBytes, 10000, 50, sha256.New)
}
- return fmt.Sprintf("%x", tempPasswd), nil
+ return hex.EncodeToString(tempPasswd), nil
}
// SetPassword hashes a password using the algorithm defined in the config value of PASSWORD_HASH_ALGO