Package io.continual.iam.impl.common
Class BasicAuthHelper
- java.lang.Object
-
- io.continual.iam.impl.common.BasicAuthHelper
-
public class BasicAuthHelper extends Object
Web systems implementing RESTful APIs with basic auth can use this helper class to get credentials from the inbound request.
-
-
Field Summary
Fields Modifier and Type Field Description static StringkSetting_AuthHeader
-
Constructor Summary
Constructors Constructor Description BasicAuthHelper()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static UsernamePasswordCredentialreadUsernamePasswordCredential(NvReadable settings, HeaderReader hr)Build an UsernamePasswordCredential from an inbound HTTP header.
-
-
-
Field Detail
-
kSetting_AuthHeader
public static final String kSetting_AuthHeader
- See Also:
- Constant Field Values
-
-
Method Detail
-
readUsernamePasswordCredential
public static UsernamePasswordCredential readUsernamePasswordCredential(NvReadable settings, HeaderReader hr)
Build an UsernamePasswordCredential from an inbound HTTP header.- Parameters:
settings- a settings sourcehr- a header reader to isolate this code from the web technology- Returns:
- username password credential or null if the header is malformed, etc.
-
-