Package io.hawt.web.auth
Class AuthenticationConfiguration
- java.lang.Object
-
- io.hawt.web.auth.AuthenticationConfiguration
-
public class AuthenticationConfiguration extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static StringAUTHShorthand forAUTHENTICATION_ENABLED.static StringAUTHENTICATION_CONFIGURATIONstatic StringAUTHENTICATION_CONTAINER_DISCOVERY_CLASSESAuthenticationContainerDiscovery classes divided by comma, which are used to discover container environments.static StringAUTHENTICATION_ENABLEDEnable or disable Hawtio's authentication.static StringDEFAULT_KARAF_ROLE_PRINCIPAL_CLASSESstatic StringDEFAULT_REALMstatic StringHAWTIO_AUTHstatic StringHAWTIO_AUTH_CONTAINER_DISCOVERY_CLASSESstatic StringHAWTIO_AUTHENTICATION_ENABLEDstatic StringHAWTIO_KEYCLOAK_ENABLEDstatic StringHAWTIO_NO_CREDENTIALS_401static StringHAWTIO_REALMstatic StringHAWTIO_ROLE_PRINCIPAL_CLASSESstatic StringHAWTIO_ROLESstatic StringKEYCLOAK_ENABLEDEnable or disable Keycloak integration.static StringLOGIN_URLstatic StringNO_CREDENTIALS_401Whether to return 401 on No Credentials authentication error.static StringREALMJAAS realm used to authenticate users.static StringROLE_PRINCIPAL_CLASSESJAAS class name that would contain the role principal.static StringROLESAuthorized user roles.static StringTOMCAT_AUTH_CONTAINER_DISCOVERYstatic String[]UNSECURED_PATHS
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ConfigurationgetConfiguration()static AuthenticationConfigurationgetConfiguration(javax.servlet.ServletContext servletContext)StringgetRealm()StringgetRolePrincipalClasses()StringgetRoles()booleanisEnabled()booleanisKeycloakEnabled()booleanisNoCredentials401()voidsetConfiguration(Configuration configuration)voidsetRolePrincipalClasses(String rolePrincipalClasses)StringtoString()
-
-
-
Field Detail
-
LOGIN_URL
public static final String LOGIN_URL
- See Also:
- Constant Field Values
-
UNSECURED_PATHS
public static final String[] UNSECURED_PATHS
-
AUTHENTICATION_ENABLED
public static final String AUTHENTICATION_ENABLED
Enable or disable Hawtio's authentication. Value should be boolean.- See Also:
- Constant Field Values
-
AUTH
public static final String AUTH
Shorthand forAUTHENTICATION_ENABLED.- See Also:
- Constant Field Values
-
REALM
public static final String REALM
JAAS realm used to authenticate users.- See Also:
- Constant Field Values
-
ROLES
public static final String ROLES
Authorized user roles. Empty string disables authorization.- See Also:
- Constant Field Values
-
ROLE_PRINCIPAL_CLASSES
public static final String ROLE_PRINCIPAL_CLASSES
JAAS class name that would contain the role principal. Empty string disables authorization.- See Also:
- Constant Field Values
-
NO_CREDENTIALS_401
public static final String NO_CREDENTIALS_401
Whether to return 401 on No Credentials authentication error. Value should be boolean.- See Also:
- Constant Field Values
-
AUTHENTICATION_CONTAINER_DISCOVERY_CLASSES
public static final String AUTHENTICATION_CONTAINER_DISCOVERY_CLASSES
AuthenticationContainerDiscovery classes divided by comma, which are used to discover container environments.- See Also:
- Constant Field Values
-
KEYCLOAK_ENABLED
public static final String KEYCLOAK_ENABLED
Enable or disable Keycloak integration. Value should be boolean.- See Also:
- Constant Field Values
-
HAWTIO_AUTHENTICATION_ENABLED
public static final String HAWTIO_AUTHENTICATION_ENABLED
- See Also:
- Constant Field Values
-
HAWTIO_AUTH
public static final String HAWTIO_AUTH
- See Also:
- Constant Field Values
-
HAWTIO_REALM
public static final String HAWTIO_REALM
- See Also:
- Constant Field Values
-
HAWTIO_ROLES
public static final String HAWTIO_ROLES
- See Also:
- Constant Field Values
-
HAWTIO_ROLE_PRINCIPAL_CLASSES
public static final String HAWTIO_ROLE_PRINCIPAL_CLASSES
- See Also:
- Constant Field Values
-
HAWTIO_NO_CREDENTIALS_401
public static final String HAWTIO_NO_CREDENTIALS_401
- See Also:
- Constant Field Values
-
HAWTIO_AUTH_CONTAINER_DISCOVERY_CLASSES
public static final String HAWTIO_AUTH_CONTAINER_DISCOVERY_CLASSES
- See Also:
- Constant Field Values
-
HAWTIO_KEYCLOAK_ENABLED
public static final String HAWTIO_KEYCLOAK_ENABLED
- See Also:
- Constant Field Values
-
AUTHENTICATION_CONFIGURATION
public static final String AUTHENTICATION_CONFIGURATION
- See Also:
- Constant Field Values
-
DEFAULT_REALM
public static final String DEFAULT_REALM
- See Also:
- Constant Field Values
-
DEFAULT_KARAF_ROLE_PRINCIPAL_CLASSES
public static final String DEFAULT_KARAF_ROLE_PRINCIPAL_CLASSES
- See Also:
- Constant Field Values
-
TOMCAT_AUTH_CONTAINER_DISCOVERY
public static final String TOMCAT_AUTH_CONTAINER_DISCOVERY
- See Also:
- Constant Field Values
-
-
Method Detail
-
getConfiguration
public static AuthenticationConfiguration getConfiguration(javax.servlet.ServletContext servletContext)
-
isEnabled
public boolean isEnabled()
-
isNoCredentials401
public boolean isNoCredentials401()
-
getRealm
public String getRealm()
-
getRoles
public String getRoles()
-
getRolePrincipalClasses
public String getRolePrincipalClasses()
-
setRolePrincipalClasses
public void setRolePrincipalClasses(String rolePrincipalClasses)
-
getConfiguration
public Configuration getConfiguration()
-
setConfiguration
public void setConfiguration(Configuration configuration)
-
isKeycloakEnabled
public boolean isKeycloakEnabled()
-
-