PKIXCertPathValidatorResult.java revision 0
0N/A * Copyright 2000-2001 Sun Microsystems, Inc. All Rights Reserved. 0N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 0N/A * This code is free software; you can redistribute it and/or modify it 0N/A * under the terms of the GNU General Public License version 2 only, as 0N/A * published by the Free Software Foundation. Sun designates this 0N/A * particular file as subject to the "Classpath" exception as provided 0N/A * by Sun in the LICENSE file that accompanied this code. 0N/A * This code is distributed in the hope that it will be useful, but WITHOUT 0N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 0N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 0N/A * version 2 for more details (a copy is included in the LICENSE file that 0N/A * accompanied this code). 0N/A * You should have received a copy of the GNU General Public License version 0N/A * 2 along with this work; if not, write to the Free Software Foundation, 0N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 0N/A * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, 0N/A * CA 95054 USA or visit www.sun.com if you need additional information or 0N/A * have any questions. 0N/A * This class represents the successful result of the PKIX certification 0N/A * path validation algorithm. 0N/A * <p>Instances of <code>PKIXCertPathValidatorResult</code> are returned by the 0N/A * {@link CertPathValidator#validate validate} method of 0N/A * <code>CertPathValidator</code> objects implementing the PKIX algorithm. 0N/A * <p> All <code>PKIXCertPathValidatorResult</code> objects contain the 0N/A * valid policy tree and subject public key resulting from the 0N/A * validation algorithm, as well as a <code>TrustAnchor</code> describing 0N/A * the certification authority (CA) that served as a trust anchor for the 0N/A * certification path. 0N/A * <b>Concurrent Access</b> 0N/A * Unless otherwise specified, the methods defined in this class are not 0N/A * thread-safe. Multiple threads that need to access a single 0N/A * object concurrently should synchronize amongst themselves and 0N/A * provide the necessary locking. Multiple threads each manipulating 0N/A * separate objects need not synchronize. 0N/A * @see CertPathValidatorResult 0N/A * @author Yassir Elley 0N/A * @author Sean Mullan 0N/A * Creates an instance of <code>PKIXCertPathValidatorResult</code> 0N/A * containing the specified parameters. 0N/A * @param trustAnchor a <code>TrustAnchor</code> describing the CA that 0N/A * served as a trust anchor for the certification path 0N/A * @param policyTree the immutable valid policy tree, or <code>null</code> 0N/A * if there are no valid policies 0N/A * @param subjectPublicKey the public key of the subject 0N/A * @throws NullPointerException if the <code>subjectPublicKey</code> or 0N/A * <code>trustAnchor</code> parameters are <code>null</code> 0N/A * Returns the <code>TrustAnchor</code> describing the CA that served 0N/A * as a trust anchor for the certification path. 0N/A * @return the <code>TrustAnchor</code> (never <code>null</code>) 0N/A * Returns the root node of the valid policy tree resulting from the 0N/A * PKIX certification path validation algorithm. The 0N/A * <code>PolicyNode</code> object that is returned and any objects that 0N/A * it returns through public methods are immutable. 0N/A * <p>Most applications will not need to examine the valid policy tree. 0N/A * They can achieve their policy processing goals by setting the 0N/A * policy-related parameters in <code>PKIXParameters</code>. However, more 0N/A * sophisticated applications, especially those that process policy 0N/A * qualifiers, may need to traverse the valid policy tree using the 0N/A * {@link PolicyNode#getParent PolicyNode.getParent} and 0N/A * {@link PolicyNode#getChildren PolicyNode.getChildren} methods. 0N/A * @return the root node of the valid policy tree, or <code>null</code> 0N/A * if there are no valid policies 0N/A * Returns the public key of the subject (target) of the certification 0N/A * path, including any inherited public key parameters if applicable. 0N/A * @return the public key of the subject (never <code>null</code>) 0N/A * Returns a copy of this object. 0N/A * Return a printable representation of this 0N/A * <code>PKIXCertPathValidatorResult</code>. 0N/A * @return a <code>String</code> describing the contents of this 0N/A * <code>PKIXCertPathValidatorResult</code>