Realm ::= KerberosString
PrincipalName ::= SEQUENCE {
name-type [0] Int32,
name-string [1] SEQUENCE OF KerberosString
}
This class is immutable.
Realm
| Modifier and Type | Field and Description |
|---|---|
| public static final int | KRB_NT_ENTERPRISE
Enterprise name (alias) |
| public static final int | KRB_NT_PRINCIPAL
Just the name of the principal as in DCE, or for users |
| public static final int | KRB_NT_SRV_HST
Service with host name as instance (telnet, rcommands) |
| public static final int | KRB_NT_SRV_INST
Service and other unique instance (krbtgt) |
| public static final int | KRB_NT_SRV_XHST
Service with host as remaining components |
| public static final int | KRB_NT_UID
Unique ID |
| public static final int | KRB_NT_UNKNOWN
Name type not known |
| private static final boolean | |
| public static final char | |
| public static final String | |
| public static final char | |
| public static final String | |
| private static final long | |
| private final Realm | nameRealm
The realm this principal belongs to. |
| private final String[] | nameStrings
The name strings, from PrincipalName's name-strings field. |
| private final int | nameType
The name type, from PrincipalName's name-type field. |
| public static final char | |
| private transient String | |
| public static final String | TGS_DEFAULT_SRV_NAME
TGS Name |
| private static final Unsafe |
| Access | Constructor and Description |
|---|---|
| public | |
| public | |
| public | PrincipalName(DerValue
DER-encoded PrincipalName (without Realm) encoding, Realm the realm for this name realm)Returns the ASN.1 encoding of the
|
| public | PrincipalName(String
the name name, int the type type, String the realm, null if not known. Note that when realm is not
null, it will be always used even if there is a realm part in name. When
realm is null, will read realm part from name, or try to map a realm
(for KRB_NT_SRV_HST), or use the default realm, or fail realm)Constructs a PrincipalName from a string. |
| public | |
| public | |
| public |
| Modifier and Type | Method and Description |
|---|---|
| public byte[] | Returns: the byte array of the encoded PrncipalName object.Encodes a |
| public Object | |
| public boolean | equals(Object o)
Overrides java. Indicates whether some other object is "equal to" this one. |
| public String | Returns: instance component of a multi-component name.Returns the instance component of a name. |
| public String | |
| public String | |
| public String[] | |
| public int | |
| public String | |
| public Realm | |
| public String | |
| public String | |
| public String | |
| public int | |
| pack-priv static String | |
| public boolean | Returns: true if two have identical values, otherwise, return false.the other pname)PrincipalName object.Checks if two |
| public static PrincipalName | Returns: an instance ofPrincipalName, or null if the
field is optional and missing.the Der input stream value, which contains one or
more marshaled value. data, byte tag number. explicitTag, boolean indicate if this data field is optional optional, Realm the realm for the name realm)Parse (unmarshal) a |
| private static String[] | |
| public static PrincipalName | |
| public byte[][] | |
| public String | |
| private static void | |
| public void | writePrincipal(CCacheOutputStream
a cos)CCacheOutputStream for writing data.Writes data field values of |
| KRB_NT_ENTERPRISE | back to summary |
|---|---|
| public static final int KRB_NT_ENTERPRISE Enterprise name (alias) | |
| KRB_NT_PRINCIPAL | back to summary |
|---|---|
| public static final int KRB_NT_PRINCIPAL Just the name of the principal as in DCE, or for users | |
| KRB_NT_SRV_HST | back to summary |
|---|---|
| public static final int KRB_NT_SRV_HST Service with host name as instance (telnet, rcommands) | |
| KRB_NT_SRV_INST | back to summary |
|---|---|
| public static final int KRB_NT_SRV_INST Service and other unique instance (krbtgt) | |
| KRB_NT_SRV_XHST | back to summary |
|---|---|
| public static final int KRB_NT_SRV_XHST Service with host as remaining components | |
| KRB_NT_UID | back to summary |
|---|---|
| public static final int KRB_NT_UID Unique ID | |
| KRB_NT_UNKNOWN | back to summary |
|---|---|
| public static final int KRB_NT_UNKNOWN Name type not known | |
| NAME_CASE_SENSITIVE_IN_MATCH | back to summary |
|---|---|
| private static final boolean NAME_CASE_SENSITIVE_IN_MATCH | |
| NAME_COMPONENT_SEPARATOR | back to summary |
|---|---|
| public static final char NAME_COMPONENT_SEPARATOR | |
| NAME_COMPONENT_SEPARATOR_STR | back to summary |
|---|---|
| public static final String NAME_COMPONENT_SEPARATOR_STR | |
| NAME_REALM_SEPARATOR | back to summary |
|---|---|
| public static final char NAME_REALM_SEPARATOR | |
| NAME_REALM_SEPARATOR_STR | back to summary |
|---|---|
| public static final String NAME_REALM_SEPARATOR_STR | |
| NAME_STRINGS_OFFSET | back to summary |
|---|---|
| private static final long NAME_STRINGS_OFFSET | |
| nameRealm | back to summary |
|---|---|
| private final Realm nameRealm The realm this principal belongs to. | |
| nameStrings | back to summary |
|---|---|
| private final String[] nameStrings The name strings, from PrincipalName's name-strings field. This field must be neither null nor empty. Each entry of it must also be neither null nor empty. Make sure to clone the field when it's passed in or out. | |
| nameType | back to summary |
|---|---|
| private final int nameType The name type, from PrincipalName's name-type field. | |
| REALM_COMPONENT_SEPARATOR | back to summary |
|---|---|
| public static final char REALM_COMPONENT_SEPARATOR | |
| salt | back to summary |
|---|---|
| private transient String salt | |
| TGS_DEFAULT_SRV_NAME | back to summary |
|---|---|
| public static final String TGS_DEFAULT_SRV_NAME TGS Name | |
| UNSAFE | back to summary |
|---|---|
| private static final Unsafe UNSAFE | |
| PrincipalName | back to summary |
|---|---|
| public PrincipalName(int nameType, String[] nameStrings, Realm nameRealm) Creates a PrincipalName. | |
| PrincipalName | back to summary |
|---|---|
| public PrincipalName(String[] nameParts, String realm) throws RealmException | |
| PrincipalName | back to summary |
|---|---|
| public PrincipalName(DerValue encoding, Realm realm) throws Asn1Exception, IOException Returns the ASN.1 encoding of the
This definition reflects the Network Working Group RFC 4120 specification available at http://www.ietf.org/rfc/rfc4120.txt.
| |
| PrincipalName | back to summary |
|---|---|
| public PrincipalName(String name, int type, String realm) throws RealmException Constructs a PrincipalName from a string.
| |
| PrincipalName | back to summary |
|---|---|
| public PrincipalName(String name, int type) throws RealmException | |
| PrincipalName | back to summary |
|---|---|
| public PrincipalName(String name) throws RealmException | |
| PrincipalName | back to summary |
|---|---|
| public PrincipalName(String name, String realm) throws RealmException | |
| asn1Encode | back to summary |
|---|---|
| public byte[] asn1Encode() throws Asn1Exception, IOException Encodes a
| |
| clone | back to summary |
|---|---|
| public Object clone() Overrides java. Doc from java. Creates and returns a copy of this object. The precise meaning
of "copy" may depend on the class of the object. The general
intent is that, for any object will be true, and that the expression:x.clone() != x will bex.clone().getClass() == x.getClass() true, but these are not absolute requirements.
While it is typically the case that:
will bex.clone().equals(x) true, this is not an absolute requirement.
By convention, the returned object should be obtained by calling
By convention, the object returned by this method should be independent
of this object (which is being cloned). To achieve this independence,
it may be necessary to modify one or more fields of the object returned
by | |
| equals | back to summary |
|---|---|
| public boolean equals(Object o) Overrides java. Doc from java. Indicates whether some other object is "equal to" this one.
The
An equivalence relation partitions the elements it operates on into equivalence classes; all the members of an equivalence class are equal to each other. Members of an equivalence class are substitutable for each other, at least for some purposes.
| |
| getInstanceComponent | back to summary |
|---|---|
| public String getInstanceComponent() Returns the instance component of a name. In a multi-component name such as a KRB_NT_SRV_INST name, the second component is returned. Null is returned if there are not two or more components in the name.
| |
| getName | back to summary |
|---|---|
| public String getName() | |
| getNameString | back to summary |
|---|---|
| public String getNameString() | |
| getNameStrings | back to summary |
|---|---|
| public String[] getNameStrings() | |
| getNameType | back to summary |
|---|---|
| public int getNameType() | |
| getPrincipalNameAsString | back to summary |
|---|---|
| public String getPrincipalNameAsString() | |
| getRealm | back to summary |
|---|---|
| public Realm getRealm() | |
| getRealmAsString | back to summary |
|---|---|
| public String getRealmAsString() | |
| getRealmString | back to summary |
|---|---|
| public String getRealmString() | |
| getSalt | back to summary |
|---|---|
| public String getSalt() | |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Doc from java. Returns a hash code value for this object. This method is
supported for the benefit of hash tables such as those provided by
The general contract of
| |
| mapHostToRealm | back to summary |
|---|---|
| pack-priv static String mapHostToRealm(String name) | |
| match | back to summary |
|---|---|
| public boolean match(PrincipalName pname) Checks if two
If
It is used in
| |
| parse | back to summary |
|---|---|
| public static PrincipalName parse(DerInputStream data, byte explicitTag, boolean optional, Realm realm) throws Asn1Exception, IOException, RealmException Parse (unmarshal) a
| |
| parseName | back to summary |
|---|---|
| private static String[] parseName(String name) | |
| tgsService | back to summary |
|---|---|
| public static PrincipalName tgsService(String r1, String r2) throws KrbException | |
| toByteArray | back to summary |
|---|---|
| public byte[][] toByteArray() | |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Doc from java. Returns a string representation of the object.
Satisfying this method's contract implies a non- | |
| validateNameStrings | back to summary |
|---|---|
| private static void validateNameStrings(String[] ns) | |
| writePrincipal | back to summary |
|---|---|
| public void writePrincipal(CCacheOutputStream cos) throws IOException Writes data field values of
| |