Commit cfa1e5e8 by chenzx

tbsso,添加session日志打印

parent 969f2a0e
......@@ -20,13 +20,10 @@ public class LoginManagement {
@RequestMapping(value = "/sessionInfo", method = RequestMethod.POST)
public @ResponseBody Map<String,Object> verifyLogin(HttpServletRequest request, HttpServletResponse response) {
Cookie[] cookies = request.getCookies();
if(null == cookies){
System.out.println("sessionInfo--cookie-->null");
if(null == request.getSession()){
System.out.println("sessionInfo--SessionID-->null");
}else{
for (Cookie cookie : cookies) {
System.out.println("sessionInfo--cookie-->"+cookie.getName()+":"+cookie.getValue());
}
System.out.println("sessionInfo--SessionID-->"+request.getSession().getId());
}
UserDetails userDetails = (UserDetails) SecurityContextHolder.getContext().getAuthentication().getPrincipal();
Map<String,Object> rs = new HashMap<>();
......
......@@ -36,13 +36,11 @@ public class RESTAuthenticationSuccessHandler extends SimpleUrlAuthenticationSuc
}
String returnStatus = data;
//check if allow root login
Cookie[] cookies = request.getCookies();
if(null == cookies){
System.out.println("RESTAuthenticationSuccessHandler--cookie-->null");
if(null == request.getSession()){
System.out.println("RESTAuthenticationSuccessHandler--SessionID-->null");
}else{
for (Cookie cookie : cookies) {
System.out.println("RESTAuthenticationSuccessHandler--cookie-->"+cookie.getName()+":"+cookie.getValue());
}
System.out.println("RESTAuthenticationSuccessHandler--SessionID-->"+request.getSession().getId());
}
UserDetails userDetails = (UserDetails) authentication.getPrincipal();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment