Class X509IdParser


  • public class X509IdParser
    extends java.lang.Object
    Utility methods to parse a (handle) identity from an X509 certificate. The identity will be taken from the subject's distinguished name; it will use the first available UID attribute if present, otherwise the first available CN attribute if present, otherwise the first available O attribute if present.
    • Constructor Summary

      Constructors 
      Constructor Description
      X509IdParser()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.lang.String parseIdentityHandle​(java.security.cert.X509Certificate cert)
      Parses the identity handle from the certificate.
      static java.lang.String parseIdentityHandle​(java.security.cert.X509Certificate[] cert)
      Parses the identity handle from the first certificate in a chain.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • X509IdParser

        public X509IdParser()
    • Method Detail

      • parseIdentityHandle

        public static java.lang.String parseIdentityHandle​(java.security.cert.X509Certificate cert)
        Parses the identity handle from the certificate.
        Parameters:
        cert - the certificate
        Returns:
        the identity handle
      • parseIdentityHandle

        public static java.lang.String parseIdentityHandle​(java.security.cert.X509Certificate[] cert)
        Parses the identity handle from the first certificate in a chain.
        Parameters:
        cert - the certificate chain
        Returns:
        the identity handle