Class Challenge

  • public final class Challenge
    extends Object
    This class represents an RFC 7235 authentication challenge.
    • Constructor Detail

      • Challenge

        public Challenge​(String scheme,
                         Map<String,String> authParams)
        Creates a new challenge.
        scheme - The authentication scheme for this challenge.
        authParams - The auth params for this challenge.
    • Method Detail

      • getScheme

        public String getScheme​()
        Gets the authentication scheme in lowercase, like basic.
        The authentication scheme.
      • getAuthParams

        public Map<String,String> getAuthParams​()
        Gets the auth params, including realm if present, but as Strings. The keys are all lowercase, as the auth param names are to be treated case insensitively anyway. If a challenge uses the token68 form instead of the auth params form, there is exactly one entry in the result where the key is null and the the value is the token.
        The auth params.
      • getRealm

        public Optional<String> getRealm​()
        Returns the protection space.
        The protection space.
      • hashCode

        public int hashCode​()
        hashCode in class Object