Commit ffd6e8d7 authored by Andy Wilkinson's avatar Andy Wilkinson

Handle null security filter dispatcher types gracefully

See gh-4505
parent f47449c8
......@@ -42,6 +42,7 @@ import org.springframework.security.web.context.AbstractSecurityWebApplicationIn
*
* @author Rob Winch
* @author Phillip Webb
* @author Andy Wilkinson
* @since 1.3
*/
@Configuration
......@@ -66,6 +67,9 @@ public class SecurityFilterAutoConfiguration {
private EnumSet<DispatcherType> getDispatcherTypes(
SecurityProperties securityProperties) {
if (securityProperties.getFilterDispatcherTypes() == null) {
return null;
}
Set<DispatcherType> dispatcherTypes = new HashSet<DispatcherType>();
for (String dispatcherType : securityProperties.getFilterDispatcherTypes()) {
dispatcherTypes.add(DispatcherType.valueOf(dispatcherType));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment