generated from root/miduo_server
自动封禁优化
parent
228c6063d3
commit
cd36f11f07
|
|
@ -4,6 +4,7 @@ package com.jmfy;
|
|||
* Created by huangds on 2017/10/24.
|
||||
*/
|
||||
|
||||
import com.jmfy.utils.JsonUtil;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.web.servlet.config.annotation.InterceptorRegistration;
|
||||
|
|
@ -15,6 +16,7 @@ import javax.servlet.http.HttpServletRequest;
|
|||
import javax.servlet.http.HttpServletResponse;
|
||||
import javax.servlet.http.HttpSession;
|
||||
import java.io.IOException;
|
||||
import java.util.HashMap;
|
||||
|
||||
/**
|
||||
* 登录配置
|
||||
|
|
@ -47,6 +49,11 @@ public class WebSecurityConfig extends WebMvcConfigurerAdapter{
|
|||
// 判断是否已有该用户登录的session
|
||||
if (request.getParameterMap().size() == 0){
|
||||
|
||||
}
|
||||
HashMap<String, String> parameterMap = JsonUtil.getInstence().getParameterMap(request);
|
||||
String source = parameterMap.get("source");
|
||||
if(source!=null && source.equals("skyeye")){
|
||||
return true;
|
||||
}
|
||||
if(session.getAttribute(SESSION_KEY) != null){
|
||||
return true;
|
||||
|
|
|
|||
Loading…
Reference in New Issue