From c56cd3330feb66fcd8c089d44c8dc863a6b2c639 Mon Sep 17 00:00:00 2001
From: xiaoyong931011 <15274802129@163.com>
Date: Fri, 24 Jun 2022 16:23:26 +0800
Subject: [PATCH] 20220606

---
 src/main/java/com/xcong/farmer/cms/configurations/security/WebSecurityConfig.java |   10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)

diff --git a/src/main/java/com/xcong/farmer/cms/configurations/security/WebSecurityConfig.java b/src/main/java/com/xcong/farmer/cms/configurations/security/WebSecurityConfig.java
index 0fe9e94..ac5fa0b 100644
--- a/src/main/java/com/xcong/farmer/cms/configurations/security/WebSecurityConfig.java
+++ b/src/main/java/com/xcong/farmer/cms/configurations/security/WebSecurityConfig.java
@@ -32,6 +32,7 @@
 
     @Override
     protected void configure(HttpSecurity http) throws Exception {
+        System.out.println(444444);
         http.httpBasic().and().
                 cors().and().csrf().disable()
                 .exceptionHandling().authenticationEntryPoint(authenticationEntryPoint())
@@ -39,10 +40,16 @@
                 .authorizeRequests()
                 .antMatchers(HttpMethod.OPTIONS, "/**").permitAll()
                 .antMatchers("/login").permitAll()
+                .antMatchers("/html").permitAll()
                 .antMatchers("/swagger**/**").permitAll()
                 .antMatchers("/webjars/**").permitAll()
                 .antMatchers("/v2/**").permitAll()
-                .antMatchers("/api/common/**").permitAll()
+                .antMatchers("/api/common/login").permitAll()
+                .antMatchers("/api/common/captcha").permitAll()
+                .antMatchers("/api/common/doUpload").permitAll()
+                .antMatchers("/api/common/uploadFile").permitAll()
+                .antMatchers("/api/messageBoard/addMessage").permitAll()
+                .antMatchers("/image/**").permitAll()
                 .anyRequest().authenticated()
                 .and().apply(securityConfiguereAdapter());
     }
@@ -68,6 +75,7 @@
     }
 
     public TokenConfigurer securityConfiguereAdapter() {
+        System.out.println(33333333);
         return new TokenConfigurer();
     }
 }

--
Gitblit v1.9.1