|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectanon.crypto.X509DistinguishedName
public final class X509DistinguishedName
Objects of this class represent an X509 distinguished name. The name consists of attributes, that are pairs of identifiers and values. Each attribute may have exactly one value. For each identifier, there also exists a string representation.
Nested Class Summary | |
---|---|
class |
X509DistinguishedName.IllegalCharacterException
Represents an error that is thrown when an illegal character is used in a distinguished name attribute. |
Field Summary | |
---|---|
static java.lang.String |
IDENTIFIER_C
Country code : X509 identifier for the string "C" |
static java.lang.String |
IDENTIFIER_CN
Common name : X509 identifier for the string "CN" |
static java.lang.String |
IDENTIFIER_E
E-Mail : X509 identifier for the string "E" |
static java.lang.String |
IDENTIFIER_EmailAddress
E-Mail 2: X509 identifier for the string "EmailAddress" |
static java.lang.String |
IDENTIFIER_GIVENNAME
Given name : Identifier for the string "GIVENNAME" |
static java.lang.String |
IDENTIFIER_L
locality name : X509 identifier for the string "L" |
static java.lang.String |
IDENTIFIER_O
Organisation : X509 identifier for the string "O" |
static java.lang.String |
IDENTIFIER_OU
Organisational Unit : X509 identifier for the string "OU" |
static java.lang.String |
IDENTIFIER_ST
State or province : X509 identifier for the string "CN" |
static java.lang.String |
IDENTIFIER_SURNAME
Surname : Identifier for the string "SURNAME" |
static java.lang.String |
LABEL_COMMON_NAME
|
static java.lang.String |
LABEL_COUNTRY
|
static java.lang.String |
LABEL_EMAIL
|
static java.lang.String |
LABEL_EMAIL_ADDRESS
|
static java.lang.String |
LABEL_GIVENNAME
|
static java.lang.String |
LABEL_LOCALITY
|
static java.lang.String |
LABEL_ORGANISATION
|
static java.lang.String |
LABEL_ORGANISATIONAL_UNIT
|
static java.lang.String |
LABEL_STATE_OR_PROVINCE
|
static java.lang.String |
LABEL_SURNAME
|
private org.bouncycastle.asn1.x509.X509Name |
m_bcX509Name
|
private static java.util.Vector |
m_sortedIdentifiers
|
Constructor Summary | |
---|---|
X509DistinguishedName(java.util.Hashtable a_attributes)
Constructs a distinguished name from a Hashtable of attributes. |
|
X509DistinguishedName(java.lang.String a_x509distinguishedName)
Constructs a distinguished name from a String of the form "C=DE, ST=Bavaria, ..." |
|
X509DistinguishedName(org.bouncycastle.asn1.x509.X509Name a_bcX509Name)
Constructs a distinguished name from a BouncyCastle X509Name object. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object a_object)
|
java.util.Vector |
getAttributeIdentifiers()
Returns the identifiers of attributes in this X509 name. |
static java.lang.String |
getAttributeNameFromAttributeIdentifier(java.lang.String a_identifier)
Returns the X509 attribute label corresponding to a given attribute identifier. |
java.lang.String |
getAttributeValue(java.lang.String a_identifier)
Returns the attribute value corresponding to a given identifier. |
java.util.Vector |
getAttributeValues()
Returns the values of attributes in this X509 name. |
java.lang.String |
getCommonName()
Returns the common name. |
java.lang.String |
getCountryCode()
Returns the country code; |
java.util.Hashtable |
getDistinguishedName()
Returns the distinguished name as Hashtable (identifier-attribute). |
java.lang.String |
getE_EmailAddress()
Returns the email address specified by the identifier "E". |
java.lang.String |
getEmailAddress()
Returns the email address specified by the identifier "EmailAddress". |
java.lang.String |
getGivenName()
Returns the given name. |
java.lang.String |
getLocalityName()
Returns the locality name. |
java.lang.String |
getOrganisation()
Returns the organisation. |
java.lang.String |
getOrganisationalUnit()
Returns the organisational unit. |
private static java.util.Enumeration |
getSortedIdentifiers()
Returns the most important BC object identifiers sorted in a reasonable way. |
java.lang.String |
getStateOrProvince()
Returns the state or province. |
java.lang.String |
getSurname()
Returns the surname. |
(package private) org.bouncycastle.asn1.x509.X509Name |
getX509Name()
Returns the BouncyCastle X509Name representation of this object. |
int |
hashCode()
|
java.lang.String |
toString()
Writes the distinguished name as a single String. |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String IDENTIFIER_CN
public static final java.lang.String IDENTIFIER_C
public static final java.lang.String IDENTIFIER_ST
public static final java.lang.String IDENTIFIER_L
public static final java.lang.String IDENTIFIER_O
public static final java.lang.String IDENTIFIER_OU
public static final java.lang.String IDENTIFIER_E
public static final java.lang.String IDENTIFIER_EmailAddress
public static final java.lang.String IDENTIFIER_SURNAME
public static final java.lang.String IDENTIFIER_GIVENNAME
public static final java.lang.String LABEL_COMMON_NAME
public static final java.lang.String LABEL_COUNTRY
public static final java.lang.String LABEL_STATE_OR_PROVINCE
public static final java.lang.String LABEL_LOCALITY
public static final java.lang.String LABEL_ORGANISATION
public static final java.lang.String LABEL_ORGANISATIONAL_UNIT
public static final java.lang.String LABEL_EMAIL
public static final java.lang.String LABEL_EMAIL_ADDRESS
public static final java.lang.String LABEL_SURNAME
public static final java.lang.String LABEL_GIVENNAME
private static java.util.Vector m_sortedIdentifiers
private org.bouncycastle.asn1.x509.X509Name m_bcX509Name
Constructor Detail |
---|
public X509DistinguishedName(java.lang.String a_x509distinguishedName)
a_x509distinguishedName
- Stringpublic X509DistinguishedName(java.util.Hashtable a_attributes) throws X509DistinguishedName.IllegalCharacterException
a_attributes
- a Hashtable of attributes
X509DistinguishedName.IllegalCharacterException
- if an illegal character is contained in the DNpublic X509DistinguishedName(org.bouncycastle.asn1.x509.X509Name a_bcX509Name)
a_bcX509Name
- a BouncyCastle X509Name object.Method Detail |
---|
public static java.lang.String getAttributeNameFromAttributeIdentifier(java.lang.String a_identifier)
a_identifier
- an X509 attribute identifier
public java.lang.String getCommonName()
public java.lang.String getSurname()
public java.lang.String getGivenName()
public java.lang.String getCountryCode()
public java.lang.String getStateOrProvince()
public java.lang.String getLocalityName()
public java.lang.String getOrganisation()
public java.lang.String getOrganisationalUnit()
public java.lang.String getE_EmailAddress()
public java.lang.String getEmailAddress()
public java.lang.String getAttributeValue(java.lang.String a_identifier)
a_identifier
- an attribute identifier
public java.util.Vector getAttributeIdentifiers()
public java.util.Vector getAttributeValues()
public java.util.Hashtable getDistinguishedName()
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object a_object)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
org.bouncycastle.asn1.x509.X509Name getX509Name()
private static java.util.Enumeration getSortedIdentifiers()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |