Class PowerAuthHttpHeader
java.lang.Object
io.getlime.security.powerauth.http.PowerAuthHttpHeader
- Direct Known Subclasses:
PowerAuthEncryptionHttpHeader,PowerAuthSignatureHttpHeader,PowerAuthTokenHttpHeader
Base class for processing any PowerAuth related HTTP headers.
- Author:
- Petr Dvorak, petr@wultra.com
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract StringReturn a string with the HTTP header value.abstract PowerAuthHttpHeaderReturn the instance of the current header type based on provided String value.protected StringheaderField(String key, String value) Helper method to build key-value pair.parseHttpHeader(String header) Parse the PowerAuth authorization header and return map with values.
-
Field Details
-
POWERAUTH_PREFIX
PowerAuth HTTP header prefix.- See Also:
-
-
Constructor Details
-
PowerAuthHttpHeader
public PowerAuthHttpHeader()
-
-
Method Details
-
parseHttpHeader
Parse the PowerAuth authorization header and return map with values.- Parameters:
header- HTTP header with PowerAuth authorization.- Returns:
- Map with parsed header values.
-
headerField
Helper method to build key-value pair.- Parameters:
key- Key.value- Value.- Returns:
- Key-value pair, constructed as: {key}="{value}".
-
fromValue
Return the instance of the current header type based on provided String value.- Parameters:
headerValue- Value of the HTTP header.- Returns:
- Instance of the header representation.
-
buildHttpHeader
Return a string with the HTTP header value.- Returns:
- HTTP header value.
-