本文整理了Java中org.bouncycastle.cert.X509AttributeCertificateHolder.<init>()
方法的一些代码示例,展示了X509AttributeCertificateHolder.<init>()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。X509AttributeCertificateHolder.<init>()
方法的具体详情如下:
包路径:org.bouncycastle.cert.X509AttributeCertificateHolder
类名称:X509AttributeCertificateHolder
方法名:<init>
暂无
代码示例来源:origin: OpenAttestation/OpenAttestation
/**
* This checks the certificate's notBefore and notAfter dates against the current time.
* This does NOT check the signature. Do that separately with isTrusted().
*
* @param date to check against the certificate's validity period
* @return true if the certificate is valid on the given date
*/
public boolean isValid(X509Certificate issuer, Date date) {
try {
X509AttributeCertificateHolder holder = new X509AttributeCertificateHolder(encoded);
ContentVerifierProvider verifierProvider = new BcRSAContentVerifierProviderBuilder(new DefaultDigestAlgorithmIdentifierFinder()).build(new X509CertificateHolder(issuer.getEncoded()));
if( !holder.isSignatureValid(verifierProvider) ) {
log.debug("Certificate signature cannot be validated with certificate: {}", issuer.getIssuerX500Principal().getName());
return false;
}
return date.compareTo(notBefore) > -1 && date.compareTo(notAfter) < 1;
}
catch(Exception e) {
log.error("Cannot initialize certificate verifier", e);
return false;
}
}
代码示例来源:origin: OpenAttestation/OpenAttestation
X509AttributeCertificateHolder cert;
try {
cert = new X509AttributeCertificateHolder(encodedCertificate);
代码示例来源:origin: org.xipki.shells/ocsp-client-shell
new X509AttributeCertificateHolder(IoUtil.read(certFile));
代码示例来源:origin: org.xipki.shell/ocsp-client-shell
new X509AttributeCertificateHolder(IoUtil.read(certFile));
代码示例来源:origin: org.italiangrid/voms-api-java
X509AttributeCertificateHolder acHolder = new X509AttributeCertificateHolder(
ac);
Attribute[] asn1Attrs = acHolder.getAttributes(VOMS_FQANS_OID);
内容来源于网络,如有侵权,请联系作者删除!