|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectissrg.ac.Util
This class contains various utility routines for converting things from one representation into another.
Field Summary | |
static java.lang.String |
SN_ATTRIBUTE_TYPE
This variable sets the attribute type for the serial number in the DN, when constructing it for the IssuerSerial case. |
Constructor Summary | |
Util()
|
Method Summary | |
static iaik.asn1.structures.GeneralNames |
buildGeneralNames(java.lang.String DN)
This method builds a General Names construct out of the string representation of an LDAP DN that should be RFC2253 compliant. |
static java.lang.String |
generalNamesToString(iaik.asn1.structures.GeneralNames gns)
Converts the given general Name in iaik representation into a String. |
static byte[] |
hashDN(java.lang.String name)
This method converts the given string to a canonical DN, then calculates its hash using hashString. |
static byte[] |
hashName(GeneralNames gn)
This is a utility method that returns the hash of the DN contained in the GeneralNames. |
static byte[] |
hashString(java.lang.String s)
Returns MD5 hash of the given string. |
static java.lang.String |
hashToString(byte[] hash)
This method converts the hash byte array to string. |
static java.lang.String |
issuerSerialToDN(java.lang.String issuerDN,
java.math.BigInteger serialNumber)
This is the universal way for constructing the LDAP DN for the entry, whose name is constructed out of the PKC Issuer DN and PKC SN. |
static java.lang.String |
issuerToString(AttCertIssuer aci)
Returns the string representation of the Issuer General Name, if V1Form or IssuerName of the V2Form is present. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final java.lang.String SN_ATTRIBUTE_TYPE
Constructor Detail |
public Util()
Method Detail |
public static java.lang.String generalNamesToString(iaik.asn1.structures.GeneralNames gns)
gns
- the GeneralNames construct to convert; must be an X.500
directory name.
public static java.lang.String issuerSerialToDN(java.lang.String issuerDN, java.math.BigInteger serialNumber)
issuerDN
- - the DN of the issuerserialNumber
- - the serial number of the PKC issued by that issuer
public static java.lang.String issuerToString(AttCertIssuer aci)
aci
- - the AttCertIssuer structure
public static iaik.asn1.structures.GeneralNames buildGeneralNames(java.lang.String DN)
DN
- is the String with LDAP DN; if a parse error occures, a
GeneralNames
corresponding to the null DN will be constructed
public static java.lang.String hashToString(byte[] hash)
hash
- - the byte array of the hash
public static byte[] hashString(java.lang.String s)
s
- - the string of which the hash has to be calculated.
public static byte[] hashDN(java.lang.String name)
name
- - the DN to canonicalise and hash
public static byte[] hashName(GeneralNames gn)
gn
- - the GeneralNames of which the directoryName will be converted
to a canonical RFC2253-compliant LDAP distinguished name and then hashed
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |