public class XMLDSIGHandler extends Object
Constructor and Description |
---|
XMLDSIGHandler(MerchantContext context) |
Modifier and Type | Method and Description |
---|---|
XMLDSIG |
assembleXMLDSIG(PrivateKey privateKey,
X509Certificate signerCertificate,
int slotId,
byte[] privateKeyLabel,
boolean includeCertChain,
X509Certificate[] certChain,
String canonicalizedObjectElement,
String hashAlg)
Method that creates an XML Digital Signature.
|
long |
calculateDaysUntilCertExpires(X509Certificate signerCert) |
public XMLDSIGHandler(MerchantContext context)
public XMLDSIG assembleXMLDSIG(PrivateKey privateKey, X509Certificate signerCertificate, int slotId, byte[] privateKeyLabel, boolean includeCertChain, X509Certificate[] certChain, String canonicalizedObjectElement, String hashAlg) throws BIDException
privateKey
- PrivateKey used to sign the SignedInfo element bytessignerCertificate
- JCRYPTO_X509Certificate The Signer CertificateslotId
- int holding the slotId if the merchant uses HSMprivateKeyLabel
- String The private key label used to identify the sign private key in the HSMincludeCertChain
- boolean Tells whether to include the whole Certificate Chain in the DSIGcertChain
- CertificateChain (Optional) Holding the Signer Certificate Chain (+Level1)canonicalizedObjectElement
- String contiaining the Canonicalized Object Element, The Object Element
MUST be canonicalized using http://www.w3.org/2001/10/xml-exc-c14n# algorithmBIDException
- If something failspublic long calculateDaysUntilCertExpires(X509Certificate signerCert) throws BIDException
BIDException
Copyright © 2017 Nets Branch Norway. All Rights Reserved.