|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.abstracthorizon.danube.auth.jaas.memory.PropertiesModuleService
public class PropertiesModuleService
This is keystore login module service. This class sets up keystore login module
| Field Summary | |
|---|---|
protected org.slf4j.Logger |
logger
|
| Constructor Summary | |
|---|---|
PropertiesModuleService()
Default constructor |
|
| Method Summary | |
|---|---|
void |
addUser(String user,
String passwd)
Adds new user to the store |
void |
changePassword(String user,
String oldPassword,
String newPassword)
Changes the password of the user |
static String |
generateHash(String algorithm,
String password)
|
static String |
generateMD5Hash(String password)
|
Configuration |
getConfiguration()
Returns configuration |
String |
getControlFlag()
Returns control flag |
String |
getLoginContext()
Returns login context name |
Properties |
getProperties()
|
String |
getPropertiesURI()
Returns properties uri |
Set<String> |
getUserRoles(String user)
|
String[] |
getUserRolesAsArray(String user)
|
List<String> |
listUsers()
Returns a list of all users in the keystore |
String |
listUsersString()
Lists certificates (users) from the keystore |
void |
loadProperties()
|
void |
removeUser(String user)
Removes certificate - user |
void |
setConfiguration(Configuration configuration)
Sets configuration |
void |
setControlFlag(String controlFlag)
Sets control flag |
void |
setLoginContext(String loginContext)
Sets login context name |
void |
setPropertesURI(String uri)
Sets properties URI |
void |
setProperties(Properties properties)
|
void |
start()
Starts the service - adding keystore login module to system application configuration entry |
void |
stop()
|
void |
storeProperties()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected org.slf4j.Logger logger
| Constructor Detail |
|---|
public PropertiesModuleService()
| Method Detail |
|---|
public void start()
throws Exception
Exception
public void stop()
throws Exception
Exception
public String listUsersString()
throws Exception
Exception
public List<String> listUsers()
throws Exception
Exception
public void changePassword(String user,
String oldPassword,
String newPassword)
throws Exception
user - useroldPassword - old passwordnewPassword - new password
Exception
public void addUser(String user,
String passwd)
throws Exception
user - userpasswd - password
Exception
public void removeUser(String user)
throws Exception
user - username
Exceptionpublic Set<String> getUserRoles(String user)
public String[] getUserRolesAsArray(String user)
public void loadProperties()
throws CertificateException,
IOException,
URISyntaxException
CertificateException
IOException
URISyntaxException
public void storeProperties()
throws IOException,
URISyntaxException
IOException
URISyntaxExceptionpublic String getPropertiesURI()
public void setPropertesURI(String uri)
uri - properties URIpublic void setLoginContext(String loginContext)
loginContext - login context namepublic String getLoginContext()
public void setControlFlag(String controlFlag)
controlFlag - control flagpublic String getControlFlag()
public Configuration getConfiguration()
public void setConfiguration(Configuration configuration)
configuration - configurationpublic Properties getProperties()
public void setProperties(Properties properties)
public static String generateMD5Hash(String password)
throws NoSuchAlgorithmException
NoSuchAlgorithmException
public static String generateHash(String algorithm,
String password)
throws NoSuchAlgorithmException
NoSuchAlgorithmException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||