@InterfaceAudience.Public @InterfaceStability.Unstable public abstract class CredentialProvider extends Object
CredentialProvider
implementations must be thread safe.Modifier and Type | Field and Description |
---|---|
static String |
CLEAR_TEXT_FALLBACK |
Constructor and Description |
---|
CredentialProvider() |
Modifier and Type | Method and Description |
---|---|
abstract org.apache.hadoop.security.alias.CredentialProvider.CredentialEntry |
createCredentialEntry(String name,
char[] credential)
Create a new credential.
|
abstract void |
deleteCredentialEntry(String name)
Delete the given credential.
|
abstract void |
flush()
Ensures that any changes to the credentials are written to persistent
store.
|
abstract List<String> |
getAliases()
Get the aliases for all credentials.
|
abstract org.apache.hadoop.security.alias.CredentialProvider.CredentialEntry |
getCredentialEntry(String alias)
Get the credential entry for a specific alias.
|
boolean |
isTransient()
Indicates whether this provider represents a store
that is intended for transient use - such as the UserProvider
is.
|
boolean |
needsPassword()
Does this provider require a password? This means that a password is
required for normal operation, and it has not been found through normal
means.
|
String |
noPasswordError()
If a password for the provider is needed, but is not provided, this will
return an error message and instructions for supplying said password to
the provider.
|
String |
noPasswordWarning()
If a password for the provider is needed, but is not provided, this will
return a warning and instructions for supplying said password to the
provider.
|
public static final String CLEAR_TEXT_FALLBACK
public boolean isTransient()
public abstract void flush() throws IOException
IOException
public abstract org.apache.hadoop.security.alias.CredentialProvider.CredentialEntry getCredentialEntry(String alias) throws IOException
alias
- the name of a specific credentialIOException
public abstract List<String> getAliases() throws IOException
IOException
public abstract org.apache.hadoop.security.alias.CredentialProvider.CredentialEntry createCredentialEntry(String name, char[] credential) throws IOException
name
- the alias of the credentialcredential
- the credential value for the alias.IOException
public abstract void deleteCredentialEntry(String name) throws IOException
name
- the alias of the credential to deleteIOException
public boolean needsPassword() throws IOException
IOException
public String noPasswordWarning()
public String noPasswordError()
Copyright © 2022 Apache Software Foundation. All rights reserved.