Skip to content

Resolve RequestMatcher at request-time #13850

Closed
Listed in
Closed
@jzheaux

Description

@jzheaux
Contributor

In circumstances where Spring MVC is deployed only to the root servlet (/), then there is no information lost when a path is specified in request matchers:

http
    .authorizeHttpRequests((authorize) -> authorize
        .requestMatchers("/path").hasAuthority("path:read")
    )
    // ...

Whether the above /path points to Spring MVC or not can be determined at request time by inspecting which servlet the request resolves to.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Relationships

None yet

    Development

    No branches or pull requests

      Participants

      @jzheaux@marcusdacoregio

      Issue actions

        Resolve RequestMatcher at request-time · Issue #13850 · spring-projects/spring-security