@Test public void retrieveRevocation() throws Exception { try (InputStream is = AbstractTestCRLUtils.class.getResourceAsStream("/http___crl.globalsign.com_gs_gspersonalsign2sha2g2.crl"); InputStream isCer = AbstractTestCRLUtils.class.getResourceAsStream("/citizen_ca.cer")) { CertificateToken certificateToken = loadCert(isCer); CRLBinary crlBinary = CRLUtils.buildCRLBinary(toByteArray(is)); CRLValidity validity = CRLUtils.buildCRLValidity(crlBinary, certificateToken); BigInteger serialNumber = new BigInteger("288350169419475868349393253038503091234"); X509CRLEntry entry = CRLUtils.getRevocationInfo(validity, serialNumber); assertNotNull(entry); assertNotNull(entry.getRevocationDate()); assertNull(entry.getRevocationReason()); assertNotNull(entry.getSerialNumber()); assertEquals(serialNumber, entry.getSerialNumber()); serialNumber = new BigInteger("288350169419475868349393264025423631520"); entry = CRLUtils.getRevocationInfo(validity, serialNumber); assertNotNull(entry); assertNotNull(entry.getRevocationDate()); assertNull(entry.getRevocationReason()); assertNotNull(entry.getSerialNumber()); assertEquals(serialNumber, entry.getSerialNumber()); serialNumber = new BigInteger("111111111111111111111111111"); entry = CRLUtils.getRevocationInfo(validity, serialNumber); assertNull(entry); } }
public CRLBinary buildCRLBinary(byte[] binaries) throws IOException { return new CRLBinary(getDERContent(binaries)); }
AbstractCRLUtils { public CRLBinary buildCRLBinary(byte[] binaries) throws IOException { return new CRLBinary(getDERContent(binaries)); } }
AbstractCRLUtils { public CRLBinary buildCRLBinary(byte[] binaries) throws IOException { return new CRLBinary(getDERContent(binaries)); }  }
AbstractCRLUtils { public CRLBinary buildCRLBinary(byte[] binaries) throws IOException { return new CRLBinary(getDERContent(binaries)); }  CRLBinary buildCRLBinary(byte[] binaries); }
AbstractCRLUtils { public CRLBinary buildCRLBinary(byte[] binaries) throws IOException { return new CRLBinary(getDERContent(binaries)); }  CRLBinary buildCRLBinary(byte[] binaries);  }