CTCertificateKeyEncryptor certKey = encList.next().getEncryptedCertificateKey(); AgileCertificateEntry ace = new AgileCertificateEntry(); ace.certVerifier = certKey.getCertVerifier(); ace.encryptedKey = certKey.getEncryptedKeyValue(); ace.x509 = (X509Certificate)cf.generateCertificate(new ByteArrayInputStream(certKey.getX509Certificate())); certList.add(ace);
CTCertificateKeyEncryptor certData = keyEnc.addNewEncryptedCertificateKey(); try { certData.setX509Certificate(ace.x509.getEncoded()); } catch (CertificateEncodingException e) { throw new EncryptedDocumentException(e); certData.setEncryptedKeyValue(ace.encryptedKey); certData.setCertVerifier(ace.certVerifier);
CTCertificateKeyEncryptor certData = keyEnc.addNewEncryptedCertificateKey(); try { certData.setX509Certificate(ace.x509.getEncoded()); } catch (CertificateEncodingException e) { throw new EncryptedDocumentException(e); certData.setEncryptedKeyValue(ace.encryptedKey); certData.setCertVerifier(ace.certVerifier);
CTCertificateKeyEncryptor certKey = encList.next().getEncryptedCertificateKey(); AgileCertificateEntry ace = new AgileCertificateEntry(); ace.certVerifier = certKey.getCertVerifier(); ace.encryptedKey = certKey.getEncryptedKeyValue(); ace.x509 = (X509Certificate)cf.generateCertificate(new ByteArrayInputStream(certKey.getX509Certificate())); certList.add(ace);