【发布时间】:2016-06-19 18:26:20
【问题描述】:
我使用了具有不同端口的 spring-boot-actuator,如下所示
server.port=8080
management.port=8989
在应用程序中,我想使用enable-csrf=true,但我不想在执行器端口中使用csrf。因为我想对 jolokia 使用批量 POST 请求。
只排除/actuator 不聪明。
http.csrf().ignoringAntMatchers("/actuator/**");
喜欢以下属性对我有好处(bt management.security.enable-csrf 不存在)。
security.enable-csrf=true
management.security.enable-csrf=false
有什么好的解决办法吗?
【问题讨论】:
-
我知道你想做什么,但有点棘手...Possible workaround
标签: spring-security csrf spring-boot-actuator