Java Code Examples for org.apache.hadoop.security.token.SecretManager#createSecretKey()

The following examples show how to use org.apache.hadoop.security.token.SecretManager#createSecretKey() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: ClientToAMTokenSecretManager.java    From hadoop with Apache License 2.0 5 votes vote down vote up
public ClientToAMTokenSecretManager(
    ApplicationAttemptId applicationAttemptID, byte[] key) {
  super();
  if (key !=  null) {
    this.masterKey = SecretManager.createSecretKey(key);
  } else {
    this.masterKey = null;
  }
  
}
 
Example 2
Source File: ClientToAMTokenSecretManager.java    From big-c with Apache License 2.0 5 votes vote down vote up
public ClientToAMTokenSecretManager(
    ApplicationAttemptId applicationAttemptID, byte[] key) {
  super();
  if (key !=  null) {
    this.masterKey = SecretManager.createSecretKey(key);
  } else {
    this.masterKey = null;
  }
  
}
 
Example 3
Source File: ClientToAMTokenSecretManager.java    From hadoop with Apache License 2.0 4 votes vote down vote up
public void setMasterKey(byte[] key) {
  synchronized (this) {
    this.masterKey = SecretManager.createSecretKey(key);
    notifyAll();
  }
}
 
Example 4
Source File: ClientToAMTokenSecretManager.java    From big-c with Apache License 2.0 4 votes vote down vote up
public void setMasterKey(byte[] key) {
  synchronized (this) {
    this.masterKey = SecretManager.createSecretKey(key);
    notifyAll();
  }
}
 
Example 5
Source File: AuthenticationTokenSecretManager.java    From hbase with Apache License 2.0 4 votes vote down vote up
public static SecretKey createSecretKey(byte[] raw) {
  return SecretManager.createSecretKey(raw);
}
 
Example 6
Source File: JobTokenSecretManager.java    From hadoop with Apache License 2.0 2 votes vote down vote up
/**
 * Convert the byte[] to a secret key
 * @param key the byte[] to create the secret key from
 * @return the secret key
 */
public static SecretKey createSecretKey(byte[] key) {
  return SecretManager.createSecretKey(key);
}
 
Example 7
Source File: AbstractDelegationTokenSecretManager.java    From hadoop with Apache License 2.0 2 votes vote down vote up
/**
 * Convert the byte[] to a secret key
 * @param key the byte[] to create the secret key from
 * @return the secret key
 */
public static SecretKey createSecretKey(byte[] key) {
  return SecretManager.createSecretKey(key);
}
 
Example 8
Source File: JobTokenSecretManager.java    From big-c with Apache License 2.0 2 votes vote down vote up
/**
 * Convert the byte[] to a secret key
 * @param key the byte[] to create the secret key from
 * @return the secret key
 */
public static SecretKey createSecretKey(byte[] key) {
  return SecretManager.createSecretKey(key);
}
 
Example 9
Source File: AbstractDelegationTokenSecretManager.java    From big-c with Apache License 2.0 2 votes vote down vote up
/**
 * Convert the byte[] to a secret key
 * @param key the byte[] to create the secret key from
 * @return the secret key
 */
public static SecretKey createSecretKey(byte[] key) {
  return SecretManager.createSecretKey(key);
}
 
Example 10
Source File: JobTokenSecretManager.java    From incubator-tez with Apache License 2.0 2 votes vote down vote up
/**
 * Convert the byte[] to a secret key
 * @param key the byte[] to create the secret key from
 * @return the secret key
 */
public static SecretKey createSecretKey(byte[] key) {
  return SecretManager.createSecretKey(key);
}
 
Example 11
Source File: JobTokenSecretManager.java    From tez with Apache License 2.0 2 votes vote down vote up
/**
 * Convert the byte[] to a secret key
 * @param key the byte[] to create the secret key from
 * @return the secret key
 */
public static SecretKey createSecretKey(byte[] key) {
  return SecretManager.createSecretKey(key);
}