Skip to content

Documentation for ServletBearerExchangeFilterFunction incomplete or incorrect #15425

@jpmsilva

Description

@jpmsilva

Documentation for ServletBearerExchangeFilterFunction is incomplete or incorrect, as it mentions this regarding locating a bearer token:

To locate the bearer token, this looks in the Reactor Context for a key of type Authentication. Registering , as a @bean will take care of this automatically

It does not specify what to register exactly.

Looking at the source code we see:

Registering {@see org.springframework.security.config.annotation.web.configuration.OAuth2ResourceServerConfiguration.OAuth2ResourceServerWebFluxSecurityConfiguration.BearerRequestContextSubscriberRegistrar}, as a {@code @bean} will take care of this automatically

The class mentioned does not appear to exist, which explains why the Javadoc appears incomplete, and as an API user it is unclear what needs to be done for ServletBearerExchangeFilterFunction to work as expected.

(Edited to remove some remarks that turned out to be unrelated - this appears to be simply a documentation issue).

Metadata

Metadata

Assignees

Labels

in: oauth2An issue in OAuth2 modules (oauth2-core, oauth2-client, oauth2-resource-server, oauth2-jose)

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions