Package org.wildfly.security.x500
Class TrustedAuthority
java.lang.Object
org.wildfly.security.x500.TrustedAuthority
- All Implemented Interfaces:
ASN1Encodable
- Direct Known Subclasses:
TrustedAuthority.CertificateTrustedAuthority,TrustedAuthority.HashTrustedAuthority,TrustedAuthority.NameTrustedAuthority
A representation of a trusted certificate authority.
- Author:
- Farah Juma
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA trusted authority that is identified by its certificate.static classA trusted authority that is identified by a hash.static final classA trusted authority that is identified by the hash of its public key.static final classA trusted authority that is identified by the hash of its name.static final classA trusted authority that is identified by its name.static final classA trusted authority that is identified by the PKCS #15 key hash. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intstatic final int -
Method Summary
Modifier and TypeMethodDescriptionabstract voidencodeTo(ASN1Encoder encoder) Encode thisTrustedAuthelement using the given trusted authority and DER encoder, whereTrustedAuthis defined as:abstract ObjectGet the identifier for this trusted authority.intgetType()Get the type of this trusted authority.
-
Field Details
-
AUTHORITY_NAME
public static final int AUTHORITY_NAME- See Also:
-
ISSUER_NAME_HASH
public static final int ISSUER_NAME_HASH- See Also:
-
ISSUER_KEY_HASH
public static final int ISSUER_KEY_HASH- See Also:
-
AUTHORITY_CERTIFICATE
public static final int AUTHORITY_CERTIFICATE- See Also:
-
PKCS_15_KEY_HASH
public static final int PKCS_15_KEY_HASH- See Also:
-
-
Method Details
-
getType
public int getType()Get the type of this trusted authority.- Returns:
- the type of this trusted authority
-
getIdentifier
Get the identifier for this trusted authority.- Returns:
- the identifier for this trusted authority
-
encodeTo
Encode this
TrustedAuthelement using the given trusted authority and DER encoder, whereTrustedAuthis defined as:TrustedAuth ::= CHOICE { authorityName [0] Name, -- SubjectName from CA certificate issuerNameHash [1] OCTET STRING, -- SHA-1 hash of Authority's DN issuerKeyHash [2] OCTET STRING, -- SHA-1 hash of Authority's public key authorityCertificate [3] Certificate, -- CA certificate pkcs15KeyHash [4] OCTET STRING -- PKCS #15 key hash }- Specified by:
encodeToin interfaceASN1Encodable- Parameters:
encoder- the DER encoder (must not benull)- Throws:
ASN1Exception- if any of the trusted authorities are invalid
-