修复一些安全性问题
This commit is contained in:
@@ -42,6 +42,7 @@ public class LoginController {
|
|||||||
tbUser.setColpassword(new BigInteger(CodingUtil.encryptSHA(tbUser.getColpassword().getBytes())).toString(32));
|
tbUser.setColpassword(new BigInteger(CodingUtil.encryptSHA(tbUser.getColpassword().getBytes())).toString(32));
|
||||||
TbUser user = userService.doLoginService(tbUser.getColname(),tbUser.getColpassword());
|
TbUser user = userService.doLoginService(tbUser.getColname(),tbUser.getColpassword());
|
||||||
if (user!=null){
|
if (user!=null){
|
||||||
|
user.setColpassword(null);
|
||||||
request.getSession().setAttribute(USER_SESSION_KEY,user);
|
request.getSession().setAttribute(USER_SESSION_KEY,user);
|
||||||
//写入日志信息
|
//写入日志信息
|
||||||
Date date = new Date();
|
Date date = new Date();
|
||||||
|
|||||||
Reference in New Issue
Block a user