List<CRLRefType> crlRefList = crlRefs.getCRLRef(); List<byte[]> crls = revocationData.getCRLs(); for (byte[] encodedCrl : crls) { CRLRefType crlRef = this.objectFactory.createCRLRefType();
private RevocationValuesType createRevocationValues(RevocationData revocationData) { RevocationValuesType revocationValues = this.objectFactory.createRevocationValuesType(); if (revocationData.hasCRLs()) { CRLValuesType crlValues = this.objectFactory.createCRLValuesType(); revocationValues.setCRLValues(crlValues); List<EncapsulatedPKIDataType> encapsulatedCrlValues = crlValues.getEncapsulatedCRLValue(); List<byte[]> crls = revocationData.getCRLs(); for (byte[] crl : crls) { EncapsulatedPKIDataType encapsulatedCrlValue = this.objectFactory.createEncapsulatedPKIDataType(); encapsulatedCrlValue.setValue(crl); encapsulatedCrlValues.add(encapsulatedCrlValue); } } if (revocationData.hasOCSPs()) { OCSPValuesType ocspValues = this.objectFactory.createOCSPValuesType(); revocationValues.setOCSPValues(ocspValues); List<EncapsulatedPKIDataType> encapsulatedOcspValues = ocspValues.getEncapsulatedOCSPValue(); List<byte[]> ocsps = revocationData.getOCSPs(); for (byte[] ocsp : ocsps) { EncapsulatedPKIDataType encapsulatedOcspValue = this.objectFactory.createEncapsulatedPKIDataType(); encapsulatedOcspValue.setValue(ocsp); encapsulatedOcspValues.add(encapsulatedOcspValue); } } return revocationValues; } }