Class SpnegoPrincipal
- java.lang.Object
-
- org.silverpeas.sso.kerberos.spnego.SpnegoPrincipal
-
- All Implemented Interfaces:
Principal
public final class SpnegoPrincipal extends Object implements Principal
This class encapsulates a KerberosPrincipal.This class also has a reference to the client's/requester's delegated credential (if any). See the
DelegateServletRequestdocumentation for more details.Also, see the delegation examples at http://spnego.sourceforge.net
- Author:
- Darwin V. Felix
-
-
Constructor Summary
Constructors Constructor Description SpnegoPrincipal(String name, int nameType)Constructs a SpnegoPrincipal from the provided String input and name type input.SpnegoPrincipal(String name, int nameType, GSSCredential delegCred)Constructs a SpnegoPrincipal from the provided String input and name type input.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)GSSCredentialgetDelegatedCredential()Returns this Principal's delegated credential or null.StringgetName()intgetNameType()Returns the name type of the KerberosPrincipal.StringgetRealm()Returns the realm component of this Kerberos principal.inthashCode()StringtoString()
-
-
-
Constructor Detail
-
SpnegoPrincipal
public SpnegoPrincipal(String name, int nameType)
Constructs a SpnegoPrincipal from the provided String input and name type input.- Parameters:
name- the principal namenameType- the name type of the principal
-
SpnegoPrincipal
public SpnegoPrincipal(String name, int nameType, GSSCredential delegCred)
Constructs a SpnegoPrincipal from the provided String input and name type input.- Parameters:
name- the principal namenameType- the name type of the principaldelegCred- this principal's delegated credential (if any)
-
-
Method Detail
-
getDelegatedCredential
public GSSCredential getDelegatedCredential()
Returns this Principal's delegated credential or null.- Returns:
- Principal's delegated credential or null.
-
getNameType
public int getNameType()
Returns the name type of the KerberosPrincipal.- Returns:
- name type of the KerberosPrincipal
-
getRealm
public String getRealm()
Returns the realm component of this Kerberos principal.- Returns:
- realm component of this Kerberos principal
-
hashCode
public int hashCode()
-
equals
public boolean equals(Object o)
-
-