@Test public void errorSignerUnauthorized() throws Exception { X509Certificate anotherSignerCert = TestCertUtil.getCa2TestOrg().certChain[0]; assertNotNull(anotherSignerCert); PrivateKey anotherSignerKey = TestCertUtil.getCa2TestOrg().key; assertNotNull(anotherSignerKey); OCSPResp ocsp = OcspTestUtils.createOCSPResponse(subject, issuer, anotherSignerCert, anotherSignerKey, CertificateStatus.GOOD); thrown.expectError(X_INCORRECT_VALIDATION_INFO); OcspVerifier verifier = new OcspVerifier(GlobalConf.getOcspFreshnessSeconds(true), new OcspVerifierOptions(true)); verifier.verifyValidityAndStatus(ocsp, issuer, anotherSignerCert); }
public void verifyValidityAndStatus(OCSPResp response, X509Certificate subject, X509Certificate issuer) throws Exception { verifyValidityAndStatus(response, subject, issuer, new Date()); }
OcspVerifier { public void verifyValidityAndStatus(OCSPResp response, X509Certificate subject, X509Certificate issuer) throws Exception { verifyValidityAndStatus(response, subject, issuer, new Date()); } }
OcspVerifier { public void verifyValidityAndStatus(OCSPResp response, X509Certificate subject, X509Certificate issuer) throws Exception { verifyValidityAndStatus(response, subject, issuer, new Date()); } OcspVerifier(int ocspFreshnessSeconds, OcspVerifierOptions options); }
OcspVerifier { public void verifyValidityAndStatus(OCSPResp response, X509Certificate subject, X509Certificate issuer) throws Exception { verifyValidityAndStatus(response, subject, issuer, new Date()); } OcspVerifier(int ocspFreshnessSeconds, OcspVerifierOptions options); void verifyValidityAndStatus(OCSPResp response,
                                        X509Certificate subject, X509Certificate issuer); void verifyValidityAndStatus(OCSPResp response,
                                        X509Certificate subject, X509Certificate issuer, Date atDate); void verifyValidity(OCSPResp response, X509Certificate subject,
                               X509Certificate issuer); void verifyValidity(OCSPResp response, X509Certificate subject,
                               X509Certificate issuer, Date atDate); static void verifyStatus(OCSPResp response); boolean isExpired(SingleResp singleResp, Date atDate); boolean isExpired(OCSPResp response); boolean isExpired(OCSPResp response, Date atDate); static X509Certificate getOcspCert(BasicOCSPResp response); }
OcspVerifier { public void verifyValidityAndStatus(OCSPResp response, X509Certificate subject, X509Certificate issuer) throws Exception { verifyValidityAndStatus(response, subject, issuer, new Date()); } OcspVerifier(int ocspFreshnessSeconds, OcspVerifierOptions options); void verifyValidityAndStatus(OCSPResp response,
                                        X509Certificate subject, X509Certificate issuer); void verifyValidityAndStatus(OCSPResp response,
                                        X509Certificate subject, X509Certificate issuer, Date atDate); void verifyValidity(OCSPResp response, X509Certificate subject,
                               X509Certificate issuer); void verifyValidity(OCSPResp response, X509Certificate subject,
                               X509Certificate issuer, Date atDate); static void verifyStatus(OCSPResp response); boolean isExpired(SingleResp singleResp, Date atDate); boolean isExpired(OCSPResp response); boolean isExpired(OCSPResp response, Date atDate); static X509Certificate getOcspCert(BasicOCSPResp response);  }