Class CertificateValidityChecker
java.lang.Object
se.swedenconnect.sigval.cert.validity.CertificateValidityChecker
- All Implemented Interfaces:
PropertyChangeListener
,Runnable
,EventListener
- Direct Known Subclasses:
BasicCertificateValidityChecker
public abstract class CertificateValidityChecker
extends Object
implements Runnable, PropertyChangeListener
This is the complete certificate validity checker that attempts both CRL and OCSP and returns the result of the first conclusive method.
The process of each validation method is carried out as follows
- Start 2 threads, each attempting to do CRL and OCSP validation
- For each process that concludes. Check that certificate chaining from validation data is trusted
- If certificate chaining is trusted, check if result is conclusive
- Return on first conclusive result or when max time has been reached
- Author:
- Martin Lindström (martin@idsec.se), Stefan Santesson (stefan@idsec.se)
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final X509Certificate
static final String
protected final X509Certificate
protected List
<ValidityChecker> protected ValidityPathChecker
-
Constructor Summary
ConstructorsConstructorDescriptionCertificateValidityChecker
(X509Certificate certificate, X509Certificate issuer, String id, ValidityPathChecker validityPathChecker, PropertyChangeListener... propertyChangeListeners) -
Method Summary
Modifier and TypeMethodDescriptionabstract ValidationStatus
Getter for validity checkers used to check validity statusvoid
run()
void
setValidityCheckers
(List<ValidityChecker> validityCheckers) Setter for validity checkers used to check validity statusvoid
setValidityPathChecker
(ValidityPathChecker validityPathChecker) Setter for certificate path checker used to validate the certificate validity tokenMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.beans.PropertyChangeListener
propertyChange
-
Field Details
-
EVENT_ID
- See Also:
-
validityCheckers
-
validityPathChecker
-
certificate
-
issuer
-
-
Constructor Details
-
CertificateValidityChecker
public CertificateValidityChecker(X509Certificate certificate, X509Certificate issuer, String id, ValidityPathChecker validityPathChecker, PropertyChangeListener... propertyChangeListeners)
-
-
Method Details
-
setValidityCheckers
Setter for validity checkers used to check validity status- Parameters:
validityCheckers
- validity checkers
-
getValidityCheckers
Getter for validity checkers used to check validity status- Returns:
- validity checkers
-
setValidityPathChecker
Setter for certificate path checker used to validate the certificate validity token- Parameters:
validityPathChecker
- certificate path checker
-
run
public void run() -
checkValidity
-