diff --git a/src/main/java/com/qiwenshare/file/controller/UserController.java b/src/main/java/com/qiwenshare/file/controller/UserController.java index a5f4692..30cd6c3 100644 --- a/src/main/java/com/qiwenshare/file/controller/UserController.java +++ b/src/main/java/com/qiwenshare/file/controller/UserController.java @@ -69,12 +69,7 @@ public class UserController { @Parameter(description = "登录密码") String password){ RestResult restResult = new RestResult(); String salt = userService.getSaltByTelephone(telephone); -// String hashPassword = new SimpleHash("MD5", password, salt, 1024).toHex(); - String hashPassword = password + salt; - for (int i = 0; i < 1024; i++) { - hashPassword = DigestUtils.md5Hex(hashPassword); - } - + String hashPassword = new SimpleHash("MD5", password, salt, 1024).toHex(); UserBean result = userService.selectUserByTelephoneAndPassword(telephone, hashPassword); if (result == null) { return RestResult.fail().message("手机号或密码错误!");