public final class X500 extends Object
Modifier and Type | Method and Description |
---|---|
static X509Certificate[] |
asOrderedX509CertificateChain(PublicKey firstPublicKey,
Certificate[] certificates)
Convert an unordered array of certificates into an ordered X.509 certificate chain.
|
static X509Certificate[] |
asX509CertificateArray(Object[] certificates)
Convert an array into a
X509Certificate[] . |
static X509Certificate[] |
createX509CertificateChain(X509Certificate firstCertificate,
HashMap<Principal,HashSet<X509Certificate>> certificatesMap)
Create an X.509 certificate chain given the first certificate that should be in the chain and a map of certificates.
|
public static final X509Certificate[] NO_CERTIFICATES
public static final String OID_AT
public static final String OID_AT_COMMON_NAME
public static final String OID_AT_SURNAME
public static final String OID_AT_SERIAL_NUMBER
public static final String OID_AT_COUNTRY_NAME
public static final String OID_AT_LOCALITY_NAME
public static final String OID_AT_STATE_OR_PROVINCE_NAME
public static final String OID_AT_STREET_ADDRESS
public static final String OID_AT_ORGANIZATION_NAME
public static final String OID_AT_ORGANIZATIONAL_UNIT_NAME
public static final String OID_AT_TITLE
public static final String OID_AT_DESCRIPTION
public static final String OID_AT_BUSINESS_CATEGORY
public static final String OID_AT_TELEPHONE_NUMBER
public static final String OID_AT_FAX_NUMBER
public static final String OID_AT_NAME
public static final String OID_AT_GIVEN_NAME
public static final String OID_AT_INITIALS
public static final String OID_AT_GENERATION_QUALIFIER
public static final String OID_AT_DN_QUALIFIER
public static final String OID_AT_HOUSE_IDENTIFIER
public static final String OID_AT_PSEUDONYM
public static final String OID_UID
public static final String OID_DC
public static final String OID_CE
public static final String OID_CE_SUBJECT_DIRECTORY_ATTRIBUTES
public static final String OID_CE_SUBJECT_KEY_IDENTIFIER
public static final String OID_CE_KEY_USAGE
public static final String OID_CE_PRIVATE_KEY_USAGE_PERIOD
public static final String OID_CE_SUBJECT_ALT_NAME
public static final String OID_CE_ISSUER_ALT_NAME
public static final String OID_CE_BASIC_CONSTRAINTS
public static final String OID_CE_CRL_NUMBER
public static final String OID_CE_CRL_REASONS
public static final String OID_CE_HOLD_INSTRUCTION_CODE
public static final String OID_CE_INVALIDITY_DATE
public static final String OID_CE_DELTA_CLR_INDICATOR
public static final String OID_CE_ISSUING_DISTRIBUTION_POINT
public static final String OID_CE_CERTIFICATE_ISSUER
public static final String OID_CE_NAME_CONSTRAINTS
public static final String OID_CE_CRL_DISTRIBUTION_POINTS
public static final String OID_CE_CERTIFICATE_POLICIES
public static final String OID_CE_POLICY_MAPPINGS
public static final String OID_CE_AUTHORITY_KEY_IDENTIFIER
public static final String OID_CE_POLICY_CONSTRAINTS
public static final String OID_CE_EXT_KEY_USAGE
public static final String OID_CE_FRESHEST_CRL
public static final String OID_CE_INHIBIT_ANY_POLICY
public static final String OID_PKIX
public static final String OID_PE
public static final String OID_QT
public static final String OID_KP
public static final String OID_AD
public static final String OID_PE_AUTHORITY_INFO_ACCESS
public static final String OID_PE_SUBJECT_INFO_ACCESS
public static final String OID_QT_CPS
public static final String OID_QT_UNOTICE
public static final String OID_KP_SERVER_AUTH
public static final String OID_KP_CLIENT_AUTH
public static final String OID_KP_CODE_SIGNING
public static final String OID_KP_EMAIL_PROTECTION
public static final String OID_KP_TIME_STAMPING
public static final String OID_KP_OCSP_SIGNING
public static final String OID_AD_OCSP
public static final String OID_AD_CA_ISSUERS
public static final String OID_AD_TIME_STAMPING
public static final String OID_AD_CA_REPOSITORY
public static final String OID_HOLD_INSTRUCTION
@Deprecated public static final String OID_HOLD_INSTRUCTION_NONE
public static final String OID_HOLD_INSTRUCTION_CALL_ISSUER
public static final String OID_HOLD_INSTRUCTION_REJECT
public static X509Certificate[] asX509CertificateArray(Object[] certificates) throws ArrayStoreException
X509Certificate[]
.certificates
- the certificates (may not be null
)null
)ArrayStoreException
- if one of the certificates in the array is not an X509Certificate
public static X509Certificate[] asOrderedX509CertificateChain(PublicKey firstPublicKey, Certificate[] certificates) throws IllegalArgumentException
firstPublicKey
- the public key that should be in the first certificate in the ordered X.509 certificate
chain (may not be null
)certificates
- the unordered array of certificates (may not be null
)IllegalArgumentException
- if the given unordered array of certificates cannot be converted into an ordered X.509 certificate chainpublic static X509Certificate[] createX509CertificateChain(X509Certificate firstCertificate, HashMap<Principal,HashSet<X509Certificate>> certificatesMap) throws IllegalArgumentException
firstCertificate
- the certificate that should be first in the newly created X.509 certificate chaincertificatesMap
- a map of distinguished names to certificates to use to create the X.509 certificate chainIllegalArgumentException
- if the X.509 certificate chain could not be createdCopyright © 2020 JBoss by Red Hat. All rights reserved.