我已经尝试了所有的方法,但我似乎不能在spring boot 2.1.10中禁用Spring安全的自动配置-我认为自动配置似乎是由执行器触发的,但我尝试排除了几乎所有可能的类,但似乎仍然引入了过滤器链。当我通过属性文件进行配置时,它会短暂地工作,但再次停止工作。
我试过了
@SpringBootApplication (exclude = { ManagementContextAutoConfiguration.class, UserDetailsServiceAutoConfiguration.class, ManagementContextAutoConfiguration.class})
我还尝试了属性-
spring.autoconfigure.exclude=org.springframework.boot.actuate.autoconfigure.web.server.ManagementContextAutoConfiguration
有人能帮帮忙吗。
发布于 2019-11-16 02:47:27
试试这个,这就是我们在Spring Boot 2.X中禁用Spring Security的方法
@SpringBootApplication(exclude={SecurityAutoConfiguration.class})https://stackoverflow.com/questions/58882791
复制相似问题