Code example for PKIXParameters

Methods: addCertPathCheckergetCertPathCheckers

        if (taSet == null) {
            fail(getName() + ": not performed (could not create test TrustAnchor set)");
        // checks that checkers cloned 
        PKIXParameters p = new PKIXParameters(taSet);
        PKIXCertPathChecker cpc = TestUtils.getTestCertPathChecker();
        // modify checker 
        // retrieve list and check that CertPathChecker's 
        // state it contains has not been changed by the 
        // above modification 
        List l = p.getCertPathCheckers();
        PKIXCertPathChecker cpc1 = (PKIXCertPathChecker)l.get(0);
        assertEquals("listSize", 1, l.size());
        assertFalse("isCopied", cpc1.isForwardCheckingSupported());
Experience pair programming with AI  Get Codota for Java