@Test @DisplayName("throws exception when the signature certificate is false") void crlThrowsAnExceptionWhenSignatureCertificateIsFalse() throws Exception { X509Certificate certificate = (X509Certificate)cf.generateCertificate(CertificationRevocationListImplTest.class.getResourceAsStream("/csca-root-cert.cer")); Set<X509Certificate> masterList = new HashSet<>(); masterList.add(certificate); CrlFetcher fetcher = getCrlFetcher(certificate); IllegalStateException illegalStateException = Assertions.assertThrows(IllegalStateException.class, () -> CertificationRevocationListImpl.initialize(masterList, certificate, fetcher)); Assert.assertEquals("Exception during initial retrieval of CRL", illegalStateException.getMessage()); Throwable certificateValidationException = illegalStateException.getCause(); Assertions.assertTrue(certificateValidationException instanceof CertificateValidationException); Assertions.assertEquals("Could not verify CRL", certificateValidationException.getMessage()); }
public static synchronized void initialize(Set<X509Certificate> masterList) { initialize(masterList, null, null); }
CertificationRevocationListImpl implements CertificationRevocationList { public static synchronized void initialize(Set<X509Certificate> masterList) { initialize(masterList, null, null); } }
CertificationRevocationListImpl implements CertificationRevocationList { public static synchronized void initialize(Set<X509Certificate> masterList) { initialize(masterList, null, null); } private  CertificationRevocationListImpl(Set<X509Certificate> masterList,
                                          X509Certificate cscaRootCertificate,
                                          CrlFetcher crlFetcher); }
CertificationRevocationListImpl implements CertificationRevocationList { public static synchronized void initialize(Set<X509Certificate> masterList) { initialize(masterList, null, null); } private  CertificationRevocationListImpl(Set<X509Certificate> masterList,
                                          X509Certificate cscaRootCertificate,
                                          CrlFetcher crlFetcher); static synchronized void initialize(Set<X509Certificate> masterList); static synchronized CertificationRevocationListImpl getInstance(); static List<String> getCrlDistributionPoints(X509Certificate certificate); void renewCrls(); @Override X509CRL getX509CRL(String url); boolean isOnCRL(X509Certificate x509CertificateToCheck); static void reset(); }
CertificationRevocationListImpl implements CertificationRevocationList { public static synchronized void initialize(Set<X509Certificate> masterList) { initialize(masterList, null, null); } private  CertificationRevocationListImpl(Set<X509Certificate> masterList,
                                          X509Certificate cscaRootCertificate,
                                          CrlFetcher crlFetcher); static synchronized void initialize(Set<X509Certificate> masterList); static synchronized CertificationRevocationListImpl getInstance(); static List<String> getCrlDistributionPoints(X509Certificate certificate); void renewCrls(); @Override X509CRL getX509CRL(String url); boolean isOnCRL(X509Certificate x509CertificateToCheck); static void reset();  }