public abstract class BaseService extends Object implements EnvelopeService
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
addChain |
protected static CertificateService |
certServ |
protected int |
minKeyLen |
protected static int |
NDX_SHA1 |
protected static int |
NDX_SHA224 |
protected static int |
NDX_SHA256 |
protected static int |
NDX_SHA384 |
protected static int |
NDX_SHA512 |
protected static PkiOps |
pkiOps |
protected byte[] |
policyHash |
protected String |
policyId |
protected String |
policyUri |
protected boolean |
procHash |
protected static String |
SIG_POLICY_BES_ID |
protected static String |
SIG_POLICY_BES_ID_20 |
protected static String |
SIG_POLICY_BES_ID_21 |
protected static String |
SIG_POLICY_BES_ID_23 |
protected static String |
SIG_POLICY_HASH |
protected static String |
SIG_POLICY_HASH_20 |
protected static String |
SIG_POLICY_HASH_21 |
protected static String |
SIG_POLICY_HASH_23 |
protected static String |
SIG_POLICY_URI |
protected static String |
SIG_POLICY_URI_20 |
protected static String |
SIG_POLICY_URI_21 |
protected static String |
SIG_POLICY_URI_23 |
protected boolean |
signedAttr |
protected boolean |
signingCertFallback |
protected int |
version |
| Constructor and Description |
|---|
BaseService() |
| Modifier and Type | Method and Description |
|---|---|
byte[] |
buildCms(List<AppSignedInfoEx> listAsiEx,
int attachSize) |
byte[] |
buildFromS3Sha1(List<AppSignedInfo> listAsi,
int attachSize) |
byte[] |
buildFromS3Sha224(List<AppSignedInfo> listAsi,
int attachSize) |
byte[] |
buildFromS3Sha256(List<AppSignedInfo> listAsi,
int attachSize) |
byte[] |
buildFromS3Sha384(List<AppSignedInfo> listAsi,
int attachSize) |
byte[] |
buildFromS3Sha512(List<AppSignedInfo> listAsi,
int attachSize) |
byte[] |
buildSha256(List<AppSignedInfoEx> listAsiEx,
int attachSize) |
byte[] |
calcSha1(byte[] content) |
byte[] |
calcSha224(byte[] content) |
byte[] |
calcSha256(byte[] content) |
byte[] |
calcSha384(byte[] content) |
byte[] |
calcSha512(byte[] content) |
byte[] |
hashSignedAttribSha1(byte[] origHash,
Date signingTime,
X509Certificate x509) |
byte[] |
hashSignedAttribSha224(byte[] origHash,
Date signingTime,
X509Certificate x509) |
byte[] |
hashSignedAttribSha256(byte[] origHash,
Date signingTime,
X509Certificate x509) |
byte[] |
hashSignedAttribSha384(byte[] origHash,
Date signingTime,
X509Certificate x509) |
byte[] |
hashSignedAttribSha512(byte[] origHash,
Date signingTime,
X509Certificate x509) |
boolean |
isProcHash() |
protected boolean |
isSignedAttr() |
protected boolean |
isSigningCertFallback() |
byte[] |
rebuildEnvelope(byte[] envelopeb64) |
org.bouncycastle.asn1.ASN1Set |
siCreate(byte[] origHash,
Date signingTime,
X509Certificate x509,
DerEncoder derEnc,
byte[] certHash,
int idSha) |
protected static final String SIG_POLICY_URI
protected static final String SIG_POLICY_BES_ID
protected static final String SIG_POLICY_HASH
protected static final String SIG_POLICY_URI_20
protected static final String SIG_POLICY_BES_ID_20
protected static final String SIG_POLICY_HASH_20
protected static final String SIG_POLICY_URI_21
protected static final String SIG_POLICY_BES_ID_21
protected static final String SIG_POLICY_HASH_21
protected static final String SIG_POLICY_URI_23
protected static final String SIG_POLICY_BES_ID_23
protected static final String SIG_POLICY_HASH_23
protected static final int NDX_SHA1
protected static final int NDX_SHA224
protected static final int NDX_SHA256
protected static final int NDX_SHA384
protected static final int NDX_SHA512
protected int version
protected int minKeyLen
protected boolean signedAttr
protected boolean signingCertFallback
protected boolean addChain
protected boolean procHash
protected byte[] policyHash
protected String policyUri
protected String policyId
protected static PkiOps pkiOps
protected static CertificateService certServ
public boolean isProcHash()
isProcHash in interface EnvelopeServiceprotected boolean isSigningCertFallback()
protected boolean isSignedAttr()
public byte[] rebuildEnvelope(byte[] envelopeb64)
throws Exception
Exceptionpublic byte[] calcSha1(byte[] content)
throws NoSuchAlgorithmException
calcSha1 in interface EnvelopeServiceNoSuchAlgorithmExceptionpublic byte[] calcSha224(byte[] content)
throws NoSuchAlgorithmException
calcSha224 in interface EnvelopeServiceNoSuchAlgorithmExceptionpublic byte[] calcSha256(byte[] content)
throws NoSuchAlgorithmException
calcSha256 in interface EnvelopeServiceNoSuchAlgorithmExceptionpublic byte[] calcSha384(byte[] content)
throws NoSuchAlgorithmException
calcSha384 in interface EnvelopeServiceNoSuchAlgorithmExceptionpublic byte[] calcSha512(byte[] content)
throws NoSuchAlgorithmException
calcSha512 in interface EnvelopeServiceNoSuchAlgorithmExceptionpublic byte[] hashSignedAttribSha1(byte[] origHash,
Date signingTime,
X509Certificate x509)
throws NoSuchAlgorithmException,
CertificateEncodingException,
Exception,
IOException
hashSignedAttribSha1 in interface EnvelopeServiceNoSuchAlgorithmExceptionCertificateEncodingExceptionExceptionIOExceptionpublic byte[] buildFromS3Sha1(List<AppSignedInfo> listAsi, int attachSize) throws Exception
buildFromS3Sha1 in interface EnvelopeServiceExceptionpublic byte[] buildCms(List<AppSignedInfoEx> listAsiEx, int attachSize) throws Exception
buildCms in interface EnvelopeServiceExceptionpublic byte[] buildSha256(List<AppSignedInfoEx> listAsiEx, int attachSize) throws Exception
Exceptionpublic byte[] hashSignedAttribSha224(byte[] origHash,
Date signingTime,
X509Certificate x509)
throws NoSuchAlgorithmException,
CertificateEncodingException,
Exception,
IOException
hashSignedAttribSha224 in interface EnvelopeServiceNoSuchAlgorithmExceptionCertificateEncodingExceptionExceptionIOExceptionpublic byte[] buildFromS3Sha224(List<AppSignedInfo> listAsi, int attachSize) throws Exception
buildFromS3Sha224 in interface EnvelopeServiceExceptionpublic byte[] hashSignedAttribSha256(byte[] origHash,
Date signingTime,
X509Certificate x509)
throws NoSuchAlgorithmException,
CertificateEncodingException,
Exception,
IOException
hashSignedAttribSha256 in interface EnvelopeServiceNoSuchAlgorithmExceptionCertificateEncodingExceptionExceptionIOExceptionpublic byte[] buildFromS3Sha256(List<AppSignedInfo> listAsi, int attachSize) throws Exception
buildFromS3Sha256 in interface EnvelopeServiceExceptionpublic byte[] hashSignedAttribSha384(byte[] origHash,
Date signingTime,
X509Certificate x509)
throws NoSuchAlgorithmException,
CertificateEncodingException,
Exception,
IOException
hashSignedAttribSha384 in interface EnvelopeServiceNoSuchAlgorithmExceptionCertificateEncodingExceptionExceptionIOExceptionpublic byte[] buildFromS3Sha384(List<AppSignedInfo> listAsi, int attachSize) throws Exception
buildFromS3Sha384 in interface EnvelopeServiceExceptionpublic byte[] hashSignedAttribSha512(byte[] origHash,
Date signingTime,
X509Certificate x509)
throws NoSuchAlgorithmException,
CertificateEncodingException,
Exception,
IOException
hashSignedAttribSha512 in interface EnvelopeServiceNoSuchAlgorithmExceptionCertificateEncodingExceptionExceptionIOExceptionpublic byte[] buildFromS3Sha512(List<AppSignedInfo> listAsi, int attachSize) throws Exception
buildFromS3Sha512 in interface EnvelopeServiceExceptionpublic org.bouncycastle.asn1.ASN1Set siCreate(byte[] origHash,
Date signingTime,
X509Certificate x509,
DerEncoder derEnc,
byte[] certHash,
int idSha)
throws Exception
siCreate in interface EnvelopeServiceExceptionCopyright © 2020. All rights reserved.