public class SubjectAttributeField extends IssuerAttributeField
The policy value of this field is returned as a string containing the value of a specific attribute in the subject relative distinguished name (RDN).
If the requested attribute does not exist in the issue RDN, the policy value returned by this class
evaluates to an empty string.
| Constructor and Description |
|---|
SubjectAttributeField(boolean required,
RDNAttributeIdentifier rdnAttributeId)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
TBSFieldName |
getFieldName()
Gets the TBS field name of the attribute extracted from the certificate.
|
void |
injectReferenceValue(X509Certificate value)
Injects the referenced value into the expressions.
|
getRDNAttributeFieldIdgetX509FieldType, toStringgetExpressionType, getPolicyExpressionReferenceType, getPolicyValue, isRequired, setRequiredequals, getClass, hashCode, notify, notifyAll, wait, wait, waitisRequired, setRequiredgetPolicyExpressionReferenceTypegetPolicyValuegetExpressionTypepublic SubjectAttributeField(boolean required,
RDNAttributeIdentifier rdnAttributeId)
required - Indicates if the field is required to be present in the certificate to be compliant with the policy.rdnAttributeId - Id of the attribute to extract from the subject RDNpublic void injectReferenceValue(X509Certificate value) throws PolicyProcessException
LiteralPolicyExpression.getPolicyValue() method.injectReferenceValue in interface ReferencePolicyExpression<X509Certificate,Collection<String>>injectReferenceValue in class IssuerAttributeFieldvalue - The reference value.PolicyProcessException - Thrown if the reference value cannot be successfully processed or the relevant accessible attribute cannot be
retrieved from the value. For example, the X509 reference expressions may require an X509 attribute to be present in a certificate. If the required
certificate attribute is not present, the this exception would be thrown.public TBSFieldName getFieldName()
getFieldName in interface TBSField<Collection<String>>getFieldName in class IssuerAttributeFieldCopyright © 2010–2020 The Direct Project. All rights reserved.