Skip to content

Support resolution of AuthenticatedPrincipal in RSocket handler methods #28444

@joshlong

Description

@joshlong

It would be mighty convenient to be able to inject the current authenticated user in an RSocket controller handler method

@MessageMapping ("test") 
Mono<String> hello (@Authenticated Principal p){ 
  return Mono.just ("Hello, "  + p.getName()) ;
} 

Per a discussion with @rwinch it looks like the autoconfiguration needs an RSocketMessageHandlerCustomizer that adds AuthenticationPrincipalArgumentResolver in RSocketSecurityAutoConfiguration.java

Metadata

Metadata

Assignees

No one assigned

    Labels

    status: supersededAn issue that has been superseded by another

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions