Class OAuth2AuthorizationRequestCustomizers

java.lang.Object
org.springframework.security.oauth2.client.web.OAuth2AuthorizationRequestCustomizers

public final class OAuth2AuthorizationRequestCustomizers extends Object
A factory of customizers that customize the OAuth 2.0 Authorization Request via the OAuth2AuthorizationRequest.Builder.
Since:
5.7
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    static Consumer<org.springframework.security.oauth2.core.endpoint.OAuth2AuthorizationRequest.Builder>
    Returns a Consumer to be provided the OAuth2AuthorizationRequest.Builder that adds the code_challenge and, usually, code_challenge_method parameters to the OAuth 2.0 Authorization Request.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • withPkce

      public static Consumer<org.springframework.security.oauth2.core.endpoint.OAuth2AuthorizationRequest.Builder> withPkce()
      Returns a Consumer to be provided the OAuth2AuthorizationRequest.Builder that adds the code_challenge and, usually, code_challenge_method parameters to the OAuth 2.0 Authorization Request. The code_verifier is stored in OAuth2AuthorizationRequest.getAttribute(String) under the key code_verifier for subsequent use in the OAuth 2.0 Access Token Request.
      Returns:
      a Consumer to be provided the OAuth2AuthorizationRequest.Builder that adds the PKCE parameters
      See Also: