Class TokenAuthenticationConverter

java.lang.Object
ai.yda.framework.channel.rest.spring.security.TokenAuthenticationConverter
All Implemented Interfaces:
org.springframework.security.web.authentication.AuthenticationConverter

public class TokenAuthenticationConverter extends Object implements org.springframework.security.web.authentication.AuthenticationConverter
Provides strategy used for converting from a HttpServletRequest to an TokenAuthentication. Used to authenticate with TokenAuthenticationManager. If the result is null, then it signals that no authentication attempt should be made.
Since:
0.1.0
See Also:
  • TokenAuthentication
  • Constructor Details

  • Method Details

    • convert

      public org.springframework.security.core.Authentication convert(jakarta.servlet.http.HttpServletRequest request)
      Converts the given HttpServletRequest to an TokenAuthentication. If the result is null, then it signals that no authentication attempt should be made.
      Specified by:
      convert in interface org.springframework.security.web.authentication.AuthenticationConverter
      Parameters:
      request - the HttpServletRequest to be converted.
      Returns:
      the Authentication that is a result of conversion or null if there is no authentication.