public class KerberosIdentity extends Object
| Modifier and Type | Field and Description |
|---|---|
static org.apache.commons.logging.Log |
LOG |
| Constructor and Description |
|---|
KerberosIdentity() |
KerberosIdentity(long reloginTime) |
| Modifier and Type | Method and Description |
|---|---|
<T> T |
doAs(PrivilegedAction<T> action) |
<T> T |
doAs(PrivilegedExceptionAction<T> action) |
<T> T |
doAsPriviledged(PrivilegedExceptionAction<T> action) |
<T> T |
doAsPrivileged(PrivilegedAction<T> action) |
Date |
getLastLogin() |
Principal |
getPrincipal() |
String |
getPrincipalName() |
String |
getPrincipalShortName() |
String |
getRealm() |
Subject |
getSubject() |
Collection<org.apache.hadoop.security.token.Token<? extends org.apache.hadoop.security.token.TokenIdentifier>> |
getTokens() |
boolean |
isLoginNecessary() |
void |
login(String kerberosPrincipal,
String kerberosKeytab,
String kerberosRealm)
Returns a cached subject for the principal.
|
void |
relogin() |
void |
reloginIfNecessary() |
String |
toString() |
public KerberosIdentity(long reloginTime)
public KerberosIdentity()
public Subject getSubject()
public String getRealm()
public void login(String kerberosPrincipal, String kerberosKeytab, String kerberosRealm) throws IOException
kerberosPrincipal - IOExceptionpublic Date getLastLogin()
public boolean isLoginNecessary()
public void relogin()
throws IOException
IOExceptionpublic void reloginIfNecessary()
throws IOException
IOExceptionpublic <T> T doAsPrivileged(PrivilegedAction<T> action)
public <T> T doAsPriviledged(PrivilegedExceptionAction<T> action) throws PrivilegedActionException
PrivilegedActionExceptionpublic <T> T doAs(PrivilegedAction<T> action)
public <T> T doAs(PrivilegedExceptionAction<T> action) throws PrivilegedActionException
PrivilegedActionExceptionpublic Principal getPrincipal()
public String getPrincipalShortName()
public String getPrincipalName()
public Collection<org.apache.hadoop.security.token.Token<? extends org.apache.hadoop.security.token.TokenIdentifier>> getTokens()
Copyright © 2017. All rights reserved.