Class JAdESLevelBaselineLT
java.lang.Object
eu.europa.esig.dss.jades.signature.JAdESExtensionBuilder
eu.europa.esig.dss.jades.signature.JAdESLevelBaselineT
eu.europa.esig.dss.jades.signature.JAdESLevelBaselineLT
- All Implemented Interfaces:
JAdESLevelBaselineExtension
,SignatureExtension<JAdESSignatureParameters>
- Direct Known Subclasses:
JAdESLevelBaselineLTA
Creates an LT-level of a JAdES signature
-
Field Summary
Fields inherited from class eu.europa.esig.dss.jades.signature.JAdESLevelBaselineT
certificateVerifier, documentValidator, tspSource
-
Constructor Summary
ConstructorsConstructorDescriptionJAdESLevelBaselineLT
(CertificateVerifier certificateVerifier) The default constructor -
Method Summary
Modifier and TypeMethodDescriptionprotected void
extendSignatures
(List<AdvancedSignature> signatures, JAdESSignatureParameters params) Extends the signaturesprotected JsonObject
Builds and returns 'rVals' JsonObjectprotected org.jose4j.json.internal.json_simple.JSONArray
getXVals
(Set<CertificateToken> certificateValuesToAdd) Builds and returns 'xVals' JSONArrayprotected void
incorporateAnyValidationData
(JAdESEtsiUHeader etsiUHeader, ValidationData validationDataForInclusion, boolean base64UrlEncoded) This method incorporates the 'anyValData' dictionary in the signatureprotected void
incorporateRVals
(JAdESEtsiUHeader etsiUHeader, Set<CRLToken> crlsToAdd, Set<OCSPToken> ocspsToAdd, boolean base64UrlEncoded) Incorporates the provided set of certificates intoetsiUHeader
protected void
incorporateTstValidationData
(JAdESEtsiUHeader etsiUHeader, ValidationData validationDataForInclusion, boolean base64UrlEncoded) This method incorporates the 'tstVD' dictionary in the signatureprotected void
incorporateValidationData
(JAdESEtsiUHeader etsiUHeader, ValidationData validationDataForInclusion, String headerName, boolean base64UrlEncoded) This method incorporates the validation data container in the signatureprotected void
incorporateXVals
(JAdESEtsiUHeader etsiUHeader, Set<CertificateToken> certificateValuesToAdd, boolean base64UrlEncoded) Incorporates the provided set of certificates intoetsiUHeader
protected void
removeLastTimestampAndAnyValidationData
(JAdESSignature jadesSignature, JAdESEtsiUHeader etsiUHeader) This method removes the 'tstVd' and 'anyValData' header parameters appearing in the end of the 'etsiU' unsigned property array.Methods inherited from class eu.europa.esig.dss.jades.signature.JAdESLevelBaselineT
extendSignatures, getSignatureRequirementsChecker, setOperationKind, setTspSource
Methods inherited from class eu.europa.esig.dss.jades.signature.JAdESExtensionBuilder
assertEtsiUComponentsConsistent, assertJSONSerializationObjectMayBeExtended, assertJWSJsonSerializationObjectValid
-
Constructor Details
-
JAdESLevelBaselineLT
The default constructor- Parameters:
certificateVerifier
-CertificateVerifier
to use
-
-
Method Details
-
extendSignatures
protected void extendSignatures(List<AdvancedSignature> signatures, JAdESSignatureParameters params) Description copied from class:JAdESLevelBaselineT
Extends the signatures- Overrides:
extendSignatures
in classJAdESLevelBaselineT
- Parameters:
signatures
- a list ofAdvancedSignature
s to be extendedparams
-JAdESSignatureParameters
the extension parameters
-
removeLastTimestampAndAnyValidationData
protected void removeLastTimestampAndAnyValidationData(JAdESSignature jadesSignature, JAdESEtsiUHeader etsiUHeader) This method removes the 'tstVd' and 'anyValData' header parameters appearing in the end of the 'etsiU' unsigned property array.- Parameters:
jadesSignature
-JAdESSignature
etsiUHeader
-JAdESEtsiUHeader
-
getXVals
protected org.jose4j.json.internal.json_simple.JSONArray getXVals(Set<CertificateToken> certificateValuesToAdd) Builds and returns 'xVals' JSONArray- Parameters:
certificateValuesToAdd
- a set ofCertificateToken
s to add- Returns:
JSONArray
'xVals' JSONArray
-
incorporateXVals
protected void incorporateXVals(JAdESEtsiUHeader etsiUHeader, Set<CertificateToken> certificateValuesToAdd, boolean base64UrlEncoded) Incorporates the provided set of certificates intoetsiUHeader
- Parameters:
etsiUHeader
-JAdESEtsiUHeader
to updatecertificateValuesToAdd
- a set ofCertificateToken
s to addbase64UrlEncoded
- if members of the etsiU array shall be base64UrlEncoded
-
getRVals
Builds and returns 'rVals' JsonObject- Parameters:
crlsToAdd
- a set ofCRLToken
s to addocspsToAdd
- a set ofOCSPToken
s to add- Returns:
JsonObject
'rVals' object
-
incorporateRVals
protected void incorporateRVals(JAdESEtsiUHeader etsiUHeader, Set<CRLToken> crlsToAdd, Set<OCSPToken> ocspsToAdd, boolean base64UrlEncoded) Incorporates the provided set of certificates intoetsiUHeader
- Parameters:
etsiUHeader
-JAdESEtsiUHeader
to updatecrlsToAdd
- a set ofCRLToken
s to addocspsToAdd
- a set ofOCSPToken
s to addbase64UrlEncoded
- if members of the etsiU array shall be base64UrlEncoded
-
incorporateTstValidationData
protected void incorporateTstValidationData(JAdESEtsiUHeader etsiUHeader, ValidationData validationDataForInclusion, boolean base64UrlEncoded) This method incorporates the 'tstVD' dictionary in the signature- Parameters:
etsiUHeader
-JAdESEtsiUHeader
containing the unsigned properties listvalidationDataForInclusion
-ValidationData
to be included into the signaturebase64UrlEncoded
- boolean value whether the etsiUHeader shall be base64url encoded or not
-
incorporateAnyValidationData
protected void incorporateAnyValidationData(JAdESEtsiUHeader etsiUHeader, ValidationData validationDataForInclusion, boolean base64UrlEncoded) This method incorporates the 'anyValData' dictionary in the signature- Parameters:
etsiUHeader
-JAdESEtsiUHeader
containing the unsigned properties listvalidationDataForInclusion
-ValidationData
to be included into the signaturebase64UrlEncoded
- boolean value whether the etsiUHeader shall be base64url encoded or not
-
incorporateValidationData
protected void incorporateValidationData(JAdESEtsiUHeader etsiUHeader, ValidationData validationDataForInclusion, String headerName, boolean base64UrlEncoded) This method incorporates the validation data container in the signature- Parameters:
etsiUHeader
-JAdESEtsiUHeader
containing the unsigned properties listvalidationDataForInclusion
-ValidationData
to be included into the signatureheaderName
-String
the name of the property to be incorporatedbase64UrlEncoded
- boolean value whether the etsiUHeader shall be base64url encoded or not
-