diff --git a/jero-boot-module-system/src/main/java/com/jero/modules/system/controller/SysUserController.java b/jero-boot-module-system/src/main/java/com/jero/modules/system/controller/SysUserController.java index bfd3c3ef..468b5546 100644 --- a/jero-boot-module-system/src/main/java/com/jero/modules/system/controller/SysUserController.java +++ b/jero-boot-module-system/src/main/java/com/jero/modules/system/controller/SysUserController.java @@ -873,6 +873,15 @@ public class SysUserController { String oldPassword = json.getString("oldpassword"); String password = json.getString("password"); String confirmPassword = json.getString("confirmpassword"); + String RSAPublicKey = json.getString("rsaPublicKey"); + String RSAPrivateKey = String.valueOf(redisUtil.get(RSAPublicKey)); + try { + oldPassword = CommonUtils.decryptBtRsaPriKey(oldPassword, RSAPrivateKey); + password = CommonUtils.decryptBtRsaPriKey(password, RSAPrivateKey); + confirmPassword = CommonUtils.decryptBtRsaPriKey(confirmPassword, RSAPrivateKey); + }catch (Exception e){ + log.error(e.getMessage(),e); + } SysUser user = this.sysUserService.getOne(new LambdaQueryWrapper().eq(SysUser::getUsername, username)); if(user==null) { return Result.error("用户不存在!");