|
@@ -112,6 +112,8 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter
|
|
|
.authorizeRequests()
|
|
|
// 对于登录login 注册register 验证码captchaImage 允许匿名访问
|
|
|
.antMatchers("/login", "/register", "/captchaImage").permitAll()
|
|
|
+ // api暂时开放访问
|
|
|
+ .antMatchers("/api/**").permitAll()
|
|
|
// 静态资源,可匿名访问
|
|
|
.antMatchers(HttpMethod.GET, "/", "/*.html", "/**/*.html", "/**/*.css", "/**/*.js", "/profile/**").permitAll()
|
|
|
.antMatchers("/swagger-ui.html", "/swagger-resources/**", "/webjars/**", "/*/api-docs", "/druid/**").permitAll()
|