Class CMSSignedContentDocument
java.lang.Object
eu.europa.esig.dss.cms.stream.CMSSignedContentDocument
- All Implemented Interfaces:
Serializable
This class is used to extract a wrapped signed content from a CMS document.
The class allows providing digest in order to avoid reading the document.
- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionCMSSignedContentDocument(eu.europa.esig.dss.model.DSSDocument cmsDocument) Constructor with a null signed content typeCMSSignedContentDocument(eu.europa.esig.dss.model.DSSDocument cmsDocument, org.bouncycastle.asn1.ASN1ObjectIdentifier signedContentType) Constructor with a provided signed content type -
Method Summary
Modifier and TypeMethodDescriptionvoidaddDigest(eu.europa.esig.dss.model.Digest digest) This method allows to add aDigestwith a new digest algorithm to the current DigestDocument.booleaneu.europa.esig.dss.model.DigestgetDigest(eu.europa.esig.dss.enumerations.DigestAlgorithm arg0) byte[]getDigestValue(eu.europa.esig.dss.enumerations.DigestAlgorithm arg0) eu.europa.esig.dss.enumerations.MimeTypegetName()inthashCode()voidvoidsetMimeType(eu.europa.esig.dss.enumerations.MimeType arg0) voidorg.bouncycastle.cms.CMSTypedDataReturns aCMSTypedDatafor a signature creationtoString()voidwriteTo(OutputStream arg0)
-
Field Details
-
digestMap
-
mimeType
protected eu.europa.esig.dss.enumerations.MimeType mimeType -
name
-
-
Constructor Details
-
CMSSignedContentDocument
public CMSSignedContentDocument(eu.europa.esig.dss.model.DSSDocument cmsDocument) Constructor with a null signed content type- Parameters:
cmsDocument-DSSDocumentrepresenting the CMS document
-
CMSSignedContentDocument
public CMSSignedContentDocument(eu.europa.esig.dss.model.DSSDocument cmsDocument, org.bouncycastle.asn1.ASN1ObjectIdentifier signedContentType) Constructor with a provided signed content type- Parameters:
cmsDocument-DSSDocumentrepresenting the CMS documentsignedContentType-ASN1ObjectIdentifier
-
-
Method Details
-
openStream
-
toCMSTypedData
public org.bouncycastle.cms.CMSTypedData toCMSTypedData()Returns aCMSTypedDatafor a signature creation- Returns:
CMSTypedData
-
addDigest
public void addDigest(eu.europa.esig.dss.model.Digest digest) This method allows to add aDigestwith a new digest algorithm to the current DigestDocument. Overwrites the previous digest if the same DigestAlgorithm is provided.- Parameters:
digest-Digestfor the current document
-
save
- Throws:
IOException
-
equals
-
hashCode
public int hashCode() -
writeTo
- Throws:
IOException
-
getMimeType
public eu.europa.esig.dss.enumerations.MimeType getMimeType() -
setMimeType
public void setMimeType(eu.europa.esig.dss.enumerations.MimeType arg0) -
getName
-
setName
-
getDigest
public eu.europa.esig.dss.model.Digest getDigest(eu.europa.esig.dss.enumerations.DigestAlgorithm arg0) -
getDigestValue
public byte[] getDigestValue(eu.europa.esig.dss.enumerations.DigestAlgorithm arg0) -
toString
-