zhangf
2024-05-08 0414ddb0b2b3a7199ae6181a770f97ac140dbd73
safePlatfrom-out-web/src/main/java/com/gkhy/safePlatform/config/security/WebSecurityConfig.java
@@ -1,6 +1,5 @@
package com.gkhy.safePlatform.config.security;
import com.gkhy.safePlatform.account.rpc.apimodel.UserAccountService;
import com.gkhy.safePlatform.config.security.customzie.CustomizeAccessDeniedHandler;
import com.gkhy.safePlatform.config.security.customzie.CustomizeAuthenticationEntryPoint;
import org.apache.dubbo.config.annotation.DubboReference;
@@ -50,8 +49,6 @@
        http.headers().cacheControl();
        // jwt过滤器
        http.addFilterBefore(tokenAuthenticationFilter, UsernamePasswordAuthenticationFilter.class);
        // 没有登录,没有权限 => 自定义返回
        http.exceptionHandling().authenticationEntryPoint(authenticationEntryPoint).accessDeniedHandler(accessDeniedHandler);
        // 请求认证访问
        http.authorizeRequests().anyRequest().authenticated();
        // 允许跨域访问