From b2242780c6994327c105e97a2240e282ee52f90c Mon Sep 17 00:00:00 2001 From: xiaoyong931011 <15274802129@163.com> Date: Fri, 24 Jun 2022 16:14:31 +0800 Subject: [PATCH] 20220606 --- src/main/java/com/xcong/farmer/cms/configurations/security/WebSecurityConfig.java | 5 +++++ 1 files changed, 5 insertions(+), 0 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 9456823..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,12 +40,15 @@ .authorizeRequests() .antMatchers(HttpMethod.OPTIONS, "/**").permitAll() .antMatchers("/login").permitAll() + .antMatchers("/html").permitAll() .antMatchers("/swagger**/**").permitAll() .antMatchers("/webjars/**").permitAll() .antMatchers("/v2/**").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()); @@ -71,6 +75,7 @@ } public TokenConfigurer securityConfiguereAdapter() { + System.out.println(33333333); return new TokenConfigurer(); } } -- Gitblit v1.9.1