public class ActiveMQBasicSecurityManager extends Object implements ActiveMQSecurityManager5, UserManagement
| Modifier and Type | Field and Description |
|---|---|
static String |
BOOTSTRAP_PASSWORD |
static String |
BOOTSTRAP_ROLE |
static String |
BOOTSTRAP_USER |
| Constructor and Description |
|---|
ActiveMQBasicSecurityManager() |
| Modifier and Type | Method and Description |
|---|---|
void |
addNewUser(String user,
String password,
String... roles) |
Subject |
authenticate(String userToAuthenticate,
String passwordToAuthenticate,
RemotingConnection remotingConnection,
String securityDomain)
is this a valid user.
|
boolean |
authorize(Subject subject,
Set<org.apache.activemq.artemis.core.security.Role> roles,
org.apache.activemq.artemis.core.security.CheckType checkType,
String address)
Determine whether the given user has the correct role for the given check type.
|
void |
completeInit(org.apache.activemq.artemis.core.persistence.StorageManager storageManager) |
ActiveMQBasicSecurityManager |
init(Map<String,String> properties)
Initialize the manager with the given configuration properties.
|
Map<String,Set<String>> |
listUser(String user) |
void |
removeUser(String user) |
void |
updateUser(String user,
String password,
String... roles) |
boolean |
validateUser(String user,
String password)
is this a valid user.
|
boolean |
validateUserAndRole(String user,
String password,
Set<org.apache.activemq.artemis.core.security.Role> roles,
org.apache.activemq.artemis.core.security.CheckType checkType)
is this a valid user and do they have the correct role
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetDomainpublic static final String BOOTSTRAP_USER
public static final String BOOTSTRAP_PASSWORD
public static final String BOOTSTRAP_ROLE
public ActiveMQBasicSecurityManager init(Map<String,String> properties)
ActiveMQSecurityManagerinit in interface ActiveMQSecurityManagerproperties - name/value pairs used to configure the ActiveMQSecurityManager instancethis instancepublic boolean validateUser(String user, String password)
ActiveMQSecurityManagervalidateUser in interface ActiveMQSecurityManageruser - the userpassword - the users passwordpublic Subject authenticate(String userToAuthenticate, String passwordToAuthenticate, RemotingConnection remotingConnection, String securityDomain)
ActiveMQSecurityManager5ActiveMQSecurityManager.validateUser(String, String).authenticate in interface ActiveMQSecurityManager5userToAuthenticate - the userpasswordToAuthenticate - the user's passwordremotingConnection - the user's connection which contains any corresponding SSL certssecurityDomain - the name of the JAAS security domain to use (can be null)public boolean validateUserAndRole(String user, String password, Set<org.apache.activemq.artemis.core.security.Role> roles, org.apache.activemq.artemis.core.security.CheckType checkType)
ActiveMQSecurityManagervalidateUserAndRole in interface ActiveMQSecurityManageruser - the userpassword - the users passwordroles - the roles the user hascheckType - the type of check to performpublic boolean authorize(Subject subject, Set<org.apache.activemq.artemis.core.security.Role> roles, org.apache.activemq.artemis.core.security.CheckType checkType, String address)
ActiveMQSecurityManager5ActiveMQSecurityManager.validateUserAndRole(String, String, Set, CheckType).authorize in interface ActiveMQSecurityManager5subject - the Subject to authorizeroles - the roles configured in the security-settingscheckType - which permission to validateaddress - the address (or FQQN) to grant access topublic void addNewUser(String user, String password, String... roles) throws Exception
addNewUser in interface UserManagementExceptionpublic void removeUser(String user) throws Exception
removeUser in interface UserManagementExceptionpublic Map<String,Set<String>> listUser(String user)
listUser in interface UserManagementpublic void updateUser(String user, String password, String... roles) throws Exception
updateUser in interface UserManagementExceptionpublic void completeInit(org.apache.activemq.artemis.core.persistence.StorageManager storageManager)
Copyright © 2020 The Apache Software Foundation. All rights reserved.