public interface CertIDV2 extends XMLStructure
CertIDV2 type as defined in ETSI ETSI EN 319 132-1.
The XML Schema Definition is defined as:
<xsd:complexType name="CertIDTypeV2">
<xsd:sequence>
<xsd:element name="CertDigest" type="DigestAlgAndValueType"/>
<xsd:element name="IssuerSerialV2" type="xsd:base64Binary" minOccurs="0"/>
</xsd:sequence>
<xsd:attribute name="URI" type="xsd:anyURI" use="optional"/>
</xsd:complexType>
A CertID may be created by invoking one of the
newCertID methods of the
QualifyingPropertiesFactory class; for example
XMLSignatureFactory sfac = XMLSignatureFactory.getInstance("DOM");
QualifyingPropertiesFactory qfac = QualifyingPropertiesFactory.getInstance("DOM");
CertificateFactory cfac = CertificateFactory.getInstance("X509");
X509Certificate cert = (X509Certificate) cfac.generateCertificate(certIS);
CertID certId = qfac.newCertID(null, cert, sfac.newDigestMethod(DigestMethod.SHA1, null));
DigestAlgAndValue,
CertIDV2,
QualifyingPropertiesFactory.newSigningCertificateV2(List),
QualifyingPropertiesFactory.newCertIDV2(String, X509Certificate, DigestMethod, boolean),
QualifyingPropertiesFactory.newCertIDV2(String, DigestMethod, byte[]),
QualifyingPropertiesFactory.newCertIDV2(String, DigestMethod, InputStream),
QualifyingPropertiesFactory.newCertIDV2(String, DigestMethod, byte[], IssuerSerialV2),
QualifyingPropertiesFactory.newCertIDV2(String, IssuerSerialV2, DigestMethod, InputStream)| Modifier and Type | Field and Description |
|---|---|
static String |
LOCAL_NAME
The local name of this element.
|
static String |
REGISTER_NAME
The name this class is registered with.
|
| Modifier and Type | Method and Description |
|---|---|
DigestAlgAndValue |
getCertDigest()
Returns the
CertDigest. |
IssuerSerialV2 |
getIssuerSerialV2()
Returns the
IssuerSerialV2. |
String |
getURI()
Returns the URI reference.
|
boolean |
validate(XMLCryptoContext context,
Data digestInput)
Validates the digest value.
|
isFeatureSupportedstatic final String LOCAL_NAME
static final String REGISTER_NAME
String getURI()
IssuerSerialV2 getIssuerSerialV2()
IssuerSerialV2.IssuerSerialV2. Maybe null.DigestAlgAndValue getCertDigest()
CertDigest.CertDigestboolean validate(XMLCryptoContext context, Data digestInput) throws XMLSignatureException
The input for the digest computation is obtained from the given
digestInput if present, or alternatively from the dereferenced
URI reference of the CertID. If no digestInput is
given or no URI reference is present or could be dereferenced successfully
an XMLSignatureException is thrown. If no digestInput
is given the method only validates the reference the first time it is
invoked. On subsequent invocations, it returns a cached result unless a
digestinput is provided.
context - the validation contextdigestInput - the input for the digest computationtrue if the digest value validated successfully;
false otherwiseNullPointerException - if context is nullXMLSignatureException - if an unexpected exception occurs while validating the digest value© 2002-2005 IAIK, © 2004, 2006 - 2017 Stiftung SIC