From ec87210310ecdde93e69c4823b9571735934b7dc Mon Sep 17 00:00:00 2001 From: Argo-Cloud Date: Mon, 26 Oct 2020 17:33:03 +0800 Subject: [PATCH] =?UTF-8?q?fix(#I22OG7):=20=E4=BF=AE=E5=A4=8D=20MongoDB=20?= =?UTF-8?q?=E6=97=A0=E6=B3=95=E6=9B=B4=E6=94=B9=E7=94=A8=E6=88=B7=E5=AF=86?= =?UTF-8?q?=E7=A0=81=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit #Issue https://gitee.com/LongbowEnterprise/BootstrapAdmin/issues/I22OG7 --- src/admin/Bootstrap.DataAccess.MongoDB/User.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/admin/Bootstrap.DataAccess.MongoDB/User.cs b/src/admin/Bootstrap.DataAccess.MongoDB/User.cs index 1e2cc64b..be5762c7 100644 --- a/src/admin/Bootstrap.DataAccess.MongoDB/User.cs +++ b/src/admin/Bootstrap.DataAccess.MongoDB/User.cs @@ -154,7 +154,7 @@ namespace Bootstrap.DataAccess.MongoDB if (Authenticate(userName, password)) { var passSalt = LgbCryptography.GenerateSalt(); - var newPassword = LgbCryptography.ComputeHash(password, passSalt); + var newPassword = LgbCryptography.ComputeHash(newPass, passSalt); var update = Builders.Update.Set(u => u.Password, newPassword).Set(u => u.PassSalt, passSalt); DbManager.Users.FindOneAndUpdate(u => u.UserName == UserName, update); ret = true;