eu.emi.security.authn.x509.helpers.pkipath.bc
Class CertPathValidatorUtilities

java.lang.Object
  extended by org.bouncycastle.jce.provider.CertPathValidatorUtilities
      extended by eu.emi.security.authn.x509.helpers.pkipath.bc.CertPathValidatorUtilities

public class CertPathValidatorUtilities
extends CertPathValidatorUtilities

Exposes otherwise hidden methods from CertPathValidatorUtilities plus in some cases fixes bugs plus produces errors in the desired format.

Author:
K. Benedyczak

Field Summary
 
Fields inherited from class org.bouncycastle.jce.provider.CertPathValidatorUtilities
ANY_POLICY, AUTHORITY_KEY_IDENTIFIER, BASIC_CONSTRAINTS, CERTIFICATE_POLICIES, CRL_DISTRIBUTION_POINTS, CRL_NUMBER, CRL_SIGN, CRL_UTIL, crlReasons, DELTA_CRL_INDICATOR, FRESHEST_CRL, INHIBIT_ANY_POLICY, ISSUING_DISTRIBUTION_POINT, KEY_CERT_SIGN, KEY_USAGE, NAME_CONSTRAINTS, POLICY_CONSTRAINTS, POLICY_MAPPINGS, SUBJECT_ALTERNATIVE_NAME
 
Constructor Summary
CertPathValidatorUtilities()
           
 
Method Summary
static void addAdditionalStoresFromAltNames(X509Certificate cert, ExtendedPKIXParameters pkixParams)
           
protected static void addAdditionalStoresFromCRLDistributionPoint(CRLDistPoint crldp, ExtendedPKIXParameters pkixParams)
           
static Collection<?> findIssuerCerts(X509Certificate cert, ExtendedPKIXBuilderParameters pkixParams)
           
static TrustAnchor findTrustAnchor2(X509Certificate cert, Set<?> trustAnchors, String sigProvider)
           
protected static Set<?> getCompleteCRLs2(DistributionPoint dp, X509Certificate cert, Date currentDate, ExtendedPKIXParameters paramsPKIX)
           
protected static Set<X509CRL> getDeltaCRLs2(Date currentDate, ExtendedPKIXParameters paramsPKIX, X509CRL completeCRL)
          Fetches delta CRLs according to RFC 3280 section 5.2.4.
protected static X500Principal getEncodedIssuerPrincipal(Object cert)
           
protected static DERObject getExtensionValue(X509Extension ext, String oid)
           
static BigInteger getSerialNumber(Object cert)
           
 
Methods inherited from class org.bouncycastle.jce.provider.CertPathValidatorUtilities
addAdditionalStoreFromLocation, findCertificates, findCertificates, findTrustAnchor, findTrustAnchor, getAlgorithmIdentifier, getCertStatus, getCompleteCRLs, getCRLIssuersFromDistributionPoint, getDeltaCRLs, getIssuerPrincipal, getNextWorkingKey, getQualifierSet, getSubjectPrincipal, getValidCertDateFromValidityModel, getValidDate, isAnyPolicy, isSelfIssued, prepareNextCertB1, prepareNextCertB2, processCertD1i, processCertD1ii, removePolicyNode, verifyX509Certificate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CertPathValidatorUtilities

public CertPathValidatorUtilities()
Method Detail

findTrustAnchor2

public static TrustAnchor findTrustAnchor2(X509Certificate cert,
                                           Set<?> trustAnchors,
                                           String sigProvider)
                                    throws AnnotatedException
Throws:
AnnotatedException

addAdditionalStoresFromAltNames

public static void addAdditionalStoresFromAltNames(X509Certificate cert,
                                                   ExtendedPKIXParameters pkixParams)
                                            throws CertificateParsingException
Throws:
CertificateParsingException

findIssuerCerts

public static Collection<?> findIssuerCerts(X509Certificate cert,
                                            ExtendedPKIXBuilderParameters pkixParams)
                                     throws AnnotatedException
Throws:
AnnotatedException

getCompleteCRLs2

protected static Set<?> getCompleteCRLs2(DistributionPoint dp,
                                         X509Certificate cert,
                                         Date currentDate,
                                         ExtendedPKIXParameters paramsPKIX)
                                  throws SimpleValidationErrorException
Throws:
SimpleValidationErrorException

getDeltaCRLs2

protected static Set<X509CRL> getDeltaCRLs2(Date currentDate,
                                            ExtendedPKIXParameters paramsPKIX,
                                            X509CRL completeCRL)
                                     throws SimpleValidationErrorException
Fetches delta CRLs according to RFC 3280 section 5.2.4. Copied to be able to fix bug in isDeltaCRL method.

Parameters:
currentDate - The date for which the delta CRLs must be valid.
paramsPKIX - The extended PKIX parameters.
completeCRL - The complete CRL the delta CRL is for.
Returns:
A Set of X509CRLs with delta CRLs.
Throws:
AnnotatedException - if an exception occurs while picking the delta CRLs.
SimpleValidationErrorException

getExtensionValue

protected static DERObject getExtensionValue(X509Extension ext,
                                             String oid)
                                      throws AnnotatedException
Throws:
AnnotatedException

addAdditionalStoresFromCRLDistributionPoint

protected static void addAdditionalStoresFromCRLDistributionPoint(CRLDistPoint crldp,
                                                                  ExtendedPKIXParameters pkixParams)
                                                           throws AnnotatedException
Throws:
AnnotatedException

getSerialNumber

public static BigInteger getSerialNumber(Object cert)

getEncodedIssuerPrincipal

protected static X500Principal getEncodedIssuerPrincipal(Object cert)


Copyright © 2012-2013 European Middleware Initiative. All Rights Reserved.