@Override protected void setUp() throws Exception { super.setUp(); // Jan 31, 2009 FakeTimeSource timeSource = new FakeTimeSource(1233465103000L); DefaultCacheImpl cache = new DefaultCacheImpl(timeSource); CachedCertPathValidator validator = new CachedCertPathValidator(cache, timeSource, new FakeTrustRootsProvider(CertConstantUtil.CA_PUB_CERT)); store = new DefaultCertPathStore(); verifier = new WaveSignatureVerifier(validator, store); }
@Override protected void setUp() throws Exception { super.setUp(); // Jan 31, 2009 FakeTimeSource timeSource = new FakeTimeSource(1233465103000L); DefaultCacheImpl cache = new DefaultCacheImpl(timeSource); CachedCertPathValidator validator = new CachedCertPathValidator(cache, timeSource, new FakeTrustRootsProvider(CertConstantUtil.CA_PUB_CERT)); store = new DefaultCertPathStore(); verifier = new WaveSignatureVerifier(validator, store); }
private WaveSignatureVerifier getRealVerifier(CertPathStore store) throws Exception { TrustRootsProvider trustRoots = new DefaultTrustRootsProvider(); VerifiedCertChainCache cache = new DefaultCacheImpl(getFakeTimeSource()); WaveCertPathValidator validator = new CachedCertPathValidator( cache, getFakeTimeSource(), trustRoots); return new WaveSignatureVerifier(validator, store); }
private WaveSignatureVerifier getRealVerifier(CertPathStore store) throws Exception { TrustRootsProvider trustRoots = new DefaultTrustRootsProvider(); VerifiedCertChainCache cache = new DefaultCacheImpl(getFakeTimeSource()); WaveCertPathValidator validator = new CachedCertPathValidator( cache, getFakeTimeSource(), trustRoots); return new WaveSignatureVerifier(validator, store); }
private WaveSignatureVerifier getVerifier(CertPathStore store, boolean disableSignerVerification) { VerifiedCertChainCache cache = new DefaultCacheImpl(getFakeTimeSource()); WaveCertPathValidator validator; if (disableSignerVerification) { validator = new DisabledCertPathValidator(); } else { validator = new CachedCertPathValidator( cache, getFakeTimeSource(), getTrustRootsProvider()); } return new WaveSignatureVerifier(validator, store); }
private WaveSignatureVerifier getVerifier(CertPathStore store, boolean disableSignerVerification) { VerifiedCertChainCache cache = new DefaultCacheImpl(getFakeTimeSource()); WaveCertPathValidator validator; if (disableSignerVerification) { validator = new DisabledCertPathValidator(); } else { validator = new CachedCertPathValidator( cache, getFakeTimeSource(), getTrustRootsProvider()); } return new WaveSignatureVerifier(validator, store); }