Class DelegationTokenIdentifier

java.lang.Object
org.apache.hadoop.security.token.TokenIdentifier
org.apache.hadoop.security.token.delegation.AbstractDelegationTokenIdentifier
org.apache.hadoop.hdfs.security.token.delegation.DelegationTokenIdentifier
All Implemented Interfaces:
org.apache.hadoop.io.Writable
Direct Known Subclasses:
DelegationTokenIdentifier.WebHdfsDelegationTokenIdentifier

@Private public class DelegationTokenIdentifier extends org.apache.hadoop.security.token.delegation.AbstractDelegationTokenIdentifier
A delegation token identifier that is specific to HDFS.
  • Field Details

    • HDFS_DELEGATION_KIND

      public static final org.apache.hadoop.io.Text HDFS_DELEGATION_KIND
  • Constructor Details

    • DelegationTokenIdentifier

      public DelegationTokenIdentifier()
      Create an empty delegation token identifier for reading into.
    • DelegationTokenIdentifier

      public DelegationTokenIdentifier(org.apache.hadoop.io.Text owner, org.apache.hadoop.io.Text renewer, org.apache.hadoop.io.Text realUser)
      Create a new delegation token identifier
      Parameters:
      owner - the effective username of the token owner
      renewer - the username of the renewer
      realUser - the real username of the token owner
  • Method Details

    • clearCache

      @VisibleForTesting public void clearCache()
    • getKind

      public org.apache.hadoop.io.Text getKind()
      Specified by:
      getKind in class org.apache.hadoop.security.token.delegation.AbstractDelegationTokenIdentifier
    • getUser

      public org.apache.hadoop.security.UserGroupInformation getUser()
      Overrides:
      getUser in class org.apache.hadoop.security.token.delegation.AbstractDelegationTokenIdentifier
    • toString

      public String toString()
      Overrides:
      toString in class org.apache.hadoop.security.token.delegation.AbstractDelegationTokenIdentifier
    • toStringStable

      public String toStringStable()
      Overrides:
      toStringStable in class org.apache.hadoop.security.token.delegation.AbstractDelegationTokenIdentifier
    • stringifyToken

      public static String stringifyToken(org.apache.hadoop.security.token.Token<?> token) throws IOException
      Returns:
      a string representation of the token
      Throws:
      IOException