要更改我在下面的弹簧安全过滤器
<http auto-config="false" entry-point-ref="authenticationEntryPoint">
<custom-filter before="FORM_LOGIN_FILTER" ref="customPasswordAuthenticationFilter"/>
</http>
但我想更改FORM_LOGIN_FILTER
所以我更喜欢使用position="FORM_LOGIN_FILTER"
,但我收到错误:
Configuration problem:
Filter beans '<customUsernamePasswordAuthenticationFilter>' and '<org.springframework.security.web.authentication.UsernamePasswordAuthenticationFilter#0>' have the same 'order' value.
When using custom filters, please make sure the positions do not conflict with default filters. Alternatively you can disable the default filters by removing the corresponding child elements from <http> and avoiding the use of <http auto-config='true'>.
该文件提到:
属性:position自定义过滤器的显式位置 应放在链中。如果要更换标准,请使用。