public class SecretManager extends org.apache.hadoop.security.token.delegation.ZKDelegationTokenSecretManager<LlapTokenIdentifier> implements SigningSecretManager
org.apache.hadoop.security.token.delegation.ZKDelegationTokenSecretManager.JaasConfiguration
ZK_DTSM_ZK_AUTH_TYPE, ZK_DTSM_ZK_CONNECTION_STRING, ZK_DTSM_ZK_CONNECTION_TIMEOUT, ZK_DTSM_ZK_CONNECTION_TIMEOUT_DEFAULT, ZK_DTSM_ZK_KERBEROS_KEYTAB, ZK_DTSM_ZK_KERBEROS_PRINCIPAL, ZK_DTSM_ZK_NUM_RETRIES, ZK_DTSM_ZK_NUM_RETRIES_DEFAULT, ZK_DTSM_ZK_SESSION_TIMEOUT, ZK_DTSM_ZK_SESSION_TIMEOUT_DEFAULT, ZK_DTSM_ZK_SHUTDOWN_TIMEOUT, ZK_DTSM_ZK_SHUTDOWN_TIMEOUT_DEFAULT, ZK_DTSM_ZNODE_WORKING_PATH, ZK_DTSM_ZNODE_WORKING_PATH_DEAFULT
Constructor and Description |
---|
SecretManager(org.apache.hadoop.conf.Configuration conf,
String clusterId) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
LlapTokenIdentifier |
createIdentifier() |
org.apache.hadoop.security.token.Token<LlapTokenIdentifier> |
createLlapToken(String appId,
String user,
boolean isSignatureRequired) |
static SecretManager |
createSecretManager(org.apache.hadoop.conf.Configuration conf,
String clusterId) |
static SecretManager |
createSecretManager(org.apache.hadoop.conf.Configuration conf,
String llapPrincipal,
String llapKeytab,
String clusterId) |
LlapTokenIdentifier |
decodeTokenIdentifier(org.apache.hadoop.security.token.Token<LlapTokenIdentifier> token) |
org.apache.hadoop.security.token.delegation.DelegationKey |
getCurrentKey() |
byte[] |
signWithKey(byte[] message,
org.apache.hadoop.security.token.delegation.DelegationKey key) |
byte[] |
signWithKey(byte[] message,
int keyId) |
void |
startThreads() |
void |
verifyToken(byte[] tokenBytes)
Verifies the token available as serialized bytes.
|
cancelToken, getCurrentKeyId, getDelegationKey, getDelegationTokenSeqNum, getListenerThreadPool, getTokenInfo, incrementCurrentKeyId, incrementDelegationTokenSeqNum, removeStoredMasterKey, removeStoredToken, setCurator, setDelegationTokenSeqNum, stopThreads, storeDelegationKey, storeToken, updateDelegationKey, updateToken
addKey, addPersistedDelegationToken, checkToken, createPassword, createSecretKey, getAllKeys, getTokenTrackingId, getTrackingIdIfEnabled, isRunning, logExpireToken, logUpdateMasterKey, renewToken, reset, retrievePassword, setCurrentKeyId, storeNewMasterKey, storeNewToken, updateStoredToken, verifyToken
public SecretManager(org.apache.hadoop.conf.Configuration conf, String clusterId)
public void startThreads() throws IOException
startThreads
in class org.apache.hadoop.security.token.delegation.ZKDelegationTokenSecretManager<LlapTokenIdentifier>
IOException
public LlapTokenIdentifier createIdentifier()
createIdentifier
in class org.apache.hadoop.security.token.SecretManager<LlapTokenIdentifier>
public LlapTokenIdentifier decodeTokenIdentifier(org.apache.hadoop.security.token.Token<LlapTokenIdentifier> token) throws IOException
decodeTokenIdentifier
in class org.apache.hadoop.security.token.delegation.AbstractDelegationTokenSecretManager<LlapTokenIdentifier>
IOException
public org.apache.hadoop.security.token.delegation.DelegationKey getCurrentKey() throws IOException
getCurrentKey
in interface SigningSecretManager
IOException
public byte[] signWithKey(byte[] message, org.apache.hadoop.security.token.delegation.DelegationKey key)
signWithKey
in interface SigningSecretManager
public byte[] signWithKey(byte[] message, int keyId) throws SecurityException
signWithKey
in interface SigningSecretManager
SecurityException
public static SecretManager createSecretManager(org.apache.hadoop.conf.Configuration conf, String clusterId)
public static SecretManager createSecretManager(org.apache.hadoop.conf.Configuration conf, String llapPrincipal, String llapKeytab, String clusterId)
public org.apache.hadoop.security.token.Token<LlapTokenIdentifier> createLlapToken(String appId, String user, boolean isSignatureRequired) throws IOException
IOException
public void close()
close
in interface SigningSecretManager
public void verifyToken(byte[] tokenBytes) throws IOException
IOException
Copyright © 2021 The Apache Software Foundation. All rights reserved.