public final class DelegationPermission extends BasicPermissionimplements Serializable
The target name of this Permission specifies a pair of kerberos service principals. The first is the subordinate service principal being entrusted to use the TGT. The second service principal designates the target service the subordinate service principal is to interact with on behalf of the initiating KerberosPrincipal. This latter service principal is specified to restrict the use of a proxiable ticket.
For example, to specify the "host" service use of a forwardable TGT the target permission is specified as follows:
DelegationPermission("\"host/foo.example.com@EXAMPLE.COM\" \"krbtgt/EXAMPLE.COM@EXAMPLE.COM\"");
To give the "backup" service a proxiable nfs service ticket the target permission might be specified:
DelegationPermission("\"backup/bar.example.com@EXAMPLE.COM\" \"nfs/home.EXAMPLE.COM@EXAMPLE.COM\"");
| Constructor and Description |
|---|
DelegationPermission(String
Create a new
DelegationPermission with the specified subordinate and target principals.
|
DelegationPermission(String
Create a new
DelegationPermission with the specified subordinate and target principals.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object
Checks two DelegationPermission objects for equality.
|
int |
hashCode()
Returns the hash code value for this object.
|
boolean |
implies(Permission
Checks if this Kerberos delegation permission object "implies" the specified permission.
|
PermissionCollection |
newPermissionCollection()
Returns a PermissionCollection object for storing DelegationPermission objects.
|
getActionscheckGuard, getName, toStringpublic DelegationPermission(Stringprincipals)
DelegationPermission with the specified subordinate and target principals.
principals - the name of the subordinate and target principals
NullPointerException - if
principals is
null.
IllegalArgumentException - if
principals is empty.
public DelegationPermission(Stringprincipals, String actions)
DelegationPermission with the specified subordinate and target principals.
principals - the name of the subordinate and target principals
actions - should be null.
NullPointerException - if
principals is
null.
IllegalArgumentException - if
principals is empty.
public boolean implies(Permissionp)
If none of the above are true, implies returns false.
implies in class
BasicPermission
p - the permission to check against.
public boolean equals(Objectobj)
equals in class
BasicPermission
obj - the object to test for equality with this object.
Object.hashCode() ,
HashMap
public int hashCode()
hashCode in class
BasicPermission
Object.equals(java.lang.Object) ,
System.identityHashCode(java.lang.Object)
public PermissionCollectionnewPermissionCollection()
newPermissionCollection in class
BasicPermission