Change EncodePasswd to HashPassword (#3329)

* Change EncodePasswd to HashPassword

* Create test+benchmark for HashPassword
This commit is contained in:
Morgan Bazalgette authored and Kim "BKC" Carlbäcker committed 2018-01-08 23:28:18 +01:00
1 parent f2b841d0ec
commit 674cfb7cac
7 files changed
+48 -9

No files matched your search

+1 -1
View File
@@ -111,7 +111,7 @@ func runChangePassword(c *cli.Context) error {
if user.Salt, err = models.GetUserSalt(); err != nil {
return fmt.Errorf("%v", err)
}
user.EncodePasswd()
user.HashPassword()
if err := models.UpdateUserCols(user, "passwd", "salt"); err != nil {
return fmt.Errorf("%v", err)
}