Class AnonymousUserSecurityContext

All Implemented Interfaces:

@NonNullByDefault public class AnonymousUserSecurityContext extends Object implements
This SecurityContext can be used to give anonymous users (i.e. unauthenticated requests) the "user" role.
Yannick Schaus - initial contribution
  • Constructor Details

    • AnonymousUserSecurityContext

      public AnonymousUserSecurityContext()
  • Method Details

    • getUserPrincipal

      public @Nullable Principal getUserPrincipal()
      Specified by:
      getUserPrincipal in interface
    • isUserInRole

      public boolean isUserInRole(@Nullable String role)
      Specified by:
      isUserInRole in interface
    • isSecure

      public boolean isSecure()
      Specified by:
      isSecure in interface
    • getAuthenticationScheme

      public @Nullable String getAuthenticationScheme()
      Specified by:
      getAuthenticationScheme in interface