Skip to content

SEC-3036: Allow using Spring Security's WebSocket XML Configuration with Spring MVC Java Configuration #3243

Open
@spring-projects-issues

Description

@spring-projects-issues

Juan David Ortiz (Migrated from SEC-3036) said:

This is the relevant part of the stacktrace I'm getting after upgrading to Spring Security 4.0.1 and trying to use the new Websocket Security feature:

Caused by: java.lang.NullPointerException: null
at org.springframework.security.config.websocket.WebSocketMessageBrokerSecurityBeanDefinitionParser$MessageSecurityPostProcessor.postProcessBeanDefinitionRegistry(WebSocketMessageBrokerSecurityBeanDefinitionParser.java:233) ~[spring-security-config-4.0.1.RELEASE.jar:4.0.1.RELEASE]

This won't allow the application context to start.

I don't know if a BeanDefinition object can return null for its getBeanClassName method and still be valid. If yes, a null check is needed to ignore those beans and continue with the processing of the relevant ones.

Please verify and thanks in advance.

Metadata

Metadata

Assignees

No one assigned

    Labels

    in: messagingAn issue in spring-security-messagingtype: enhancementA general enhancementtype: jiraAn issue that was migrated from JIRA

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions