public interface CredentialsStore
A storage for Credentials
Note: Implementation of this interface must be thread-safe.
Modifier and Type | Method and Description |
---|---|
Credentials |
add(InetSocketAddress address,
byte[] passphrase)
Adds a valid
Credentials to the registry |
void |
clear()
Clear all registered
Credentials |
boolean |
exists(InetSocketAddress address)
Checks if a
Credentials is registered for the specified address. |
Credentials |
get(InetSocketAddress address)
Gets a
Credentials from the storage. |
void |
remove(InetSocketAddress address)
Clear
Credentials for a specific address |
Credentials get(InetSocketAddress address)
Credentials
from the storage.address
- The InetSocketAddress
to be used for lookupCredentials
associated with the InetSocketAddress
. null
if no Credentials
is present.Credentials add(InetSocketAddress address, byte[] passphrase)
Credentials
to the registryaddress
- The InetSocketAddress
to registerpassphrase
- The byte array containing the passphrase to be used for authenticationCredentials
registered for the specified addressvoid remove(InetSocketAddress address)
Credentials
for a specific addressaddress
- The InetSocketAddress
to clearvoid clear()
Credentials
boolean exists(InetSocketAddress address)
Credentials
is registered for the specified address. Note: This only checks for the existence of a Credentials
not the validity.address
- The InetSocketAddress
to checktrue
if a Credentials
is registered for the specified address.Copyright © 2016–2024. All rights reserved.