Class JCEKSPasswordAliasStore
- All Implemented Interfaces:
org.glassfish.api.admin.PasswordAliasStore
- Direct Known Subclasses:
JCEKSDomainPasswordAliasStore
The keystore is actually managed by the PasswordAdapter, to which this implementation currently delegates its work.
Note that this service is currently per-lookup. This is so that each use of the alias store gets the current on-disk information. Ideally we can change this when we can use Java 7 features, including the WatchService feature.
This class's methods are not synchronized because the PasswordAdapter's methods are. If this implementation changes so that it no longer delegates to those synchronized PasswordAdapter methods, then make sure that the implementation is thread-safe.
Note that the domain-scoped password alias store service class extends this class. As a service, that class will be instantiated using the no-args constructor. So the actual initialization of the class occurs in the init method. The domain-scoped service class invokes the init method itself. Any code that needs to create some other alias store can use the newInstance method to provide the location of the alias store file and the password.
- Author:
- tjquinn
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
clear()
boolean
containsKey
(String alias) char[]
protected final void
boolean
isEmpty()
keys()
static JCEKSPasswordAliasStore
newInstance
(String pathToAliasStore, char[] storePassword) void
void
void
putAll
(org.glassfish.api.admin.PasswordAliasStore otherStore) void
int
size()
-
Constructor Details
-
JCEKSPasswordAliasStore
public JCEKSPasswordAliasStore()
-
-
Method Details
-
init
-
newInstance
-
clear
public void clear()- Specified by:
clear
in interfaceorg.glassfish.api.admin.PasswordAliasStore
-
put
- Specified by:
put
in interfaceorg.glassfish.api.admin.PasswordAliasStore
-
putAll
public void putAll(org.glassfish.api.admin.PasswordAliasStore otherStore) - Specified by:
putAll
in interfaceorg.glassfish.api.admin.PasswordAliasStore
-
putAll
- Specified by:
putAll
in interfaceorg.glassfish.api.admin.PasswordAliasStore
-
remove
- Specified by:
remove
in interfaceorg.glassfish.api.admin.PasswordAliasStore
-
containsKey
- Specified by:
containsKey
in interfaceorg.glassfish.api.admin.PasswordAliasStore
-
get
- Specified by:
get
in interfaceorg.glassfish.api.admin.PasswordAliasStore
-
isEmpty
public boolean isEmpty()- Specified by:
isEmpty
in interfaceorg.glassfish.api.admin.PasswordAliasStore
-
keys
- Specified by:
keys
in interfaceorg.glassfish.api.admin.PasswordAliasStore
-
size
public int size()- Specified by:
size
in interfaceorg.glassfish.api.admin.PasswordAliasStore
-