Stay organized with collections
Save and categorize content based on your preferences.
CertPathChecker
public
interface
CertPathChecker
java.security.cert.CertPathChecker
|
Known indirect subclasses
PKIXCertPathChecker |
An abstract class that performs one or more checks on an
X509Certificate .
|
PKIXRevocationChecker |
A PKIXCertPathChecker for checking the revocation status of
certificates with the PKIX algorithm.
|
|
Performs one or more checks on each Certificate
of a
CertPath
.
A CertPathChecker
implementation is typically created to extend
a certification path validation algorithm. For example, an implementation
may check for and process a critical private extension of each certificate
in a certification path.
Summary
Public methods |
abstract
void
|
check(Certificate cert)
Performs the check(s) on the specified certificate using its internal
state.
|
abstract
void
|
init(boolean forward)
Initializes the internal state of this CertPathChecker .
|
abstract
boolean
|
isForwardCheckingSupported()
Indicates if forward checking is supported.
|
Public methods
check
public abstract void check (Certificate cert)
Performs the check(s) on the specified certificate using its internal
state. The certificates are presented in the order specified by the
init
method.
Parameters |
cert |
Certificate : the Certificate to be checked |
init
public abstract void init (boolean forward)
Initializes the internal state of this CertPathChecker
.
The forward
flag specifies the order that certificates will
be passed to the check
method (forward or reverse).
Parameters |
forward |
boolean : the order that certificates are presented to the
check method. If true , certificates are
presented from target to trust anchor (forward); if
false , from trust anchor to target (reverse). |
isForwardCheckingSupported
public abstract boolean isForwardCheckingSupported ()
Indicates if forward checking is supported. Forward checking refers
to the ability of the CertPathChecker
to perform its checks
when certificates are presented to the check
method in the
forward direction (from target to trust anchor).
Returns |
boolean |
true if forward checking is supported, false
otherwise |
Content and code samples on this page are subject to the licenses described in the Content License. Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-02-10 UTC."],[],[],null,["# CertPathChecker\n\nAdded in [API level 24](/guide/topics/manifest/uses-sdk-element#ApiLevels) \nSummary: [Methods](#pubmethods) \n\nCertPathChecker\n===============\n\n\n`\npublic\n\n\ninterface\nCertPathChecker\n`\n\n\n`\n\n\n`\n\n|------------------------------------|\n| java.security.cert.CertPathChecker |\n\n|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| Known indirect subclasses [PKIXCertPathChecker](/reference/java/security/cert/PKIXCertPathChecker), [PKIXRevocationChecker](/reference/java/security/cert/PKIXRevocationChecker) |------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------| | [PKIXCertPathChecker](/reference/java/security/cert/PKIXCertPathChecker) | An abstract class that performs one or more checks on an `X509Certificate`. | | [PKIXRevocationChecker](/reference/java/security/cert/PKIXRevocationChecker) | A `PKIXCertPathChecker` for checking the revocation status of certificates with the PKIX algorithm. | |\n\n\u003cbr /\u003e\n\n*** ** * ** ***\n\n\u003cbr /\u003e\n\nPerforms one or more checks on each `Certificate` of a\n`CertPath`.\n\nA `CertPathChecker` implementation is typically created to extend\na certification path validation algorithm. For example, an implementation\nmay check for and process a critical private extension of each certificate\nin a certification path.\n\nSummary\n-------\n\n| ### Public methods ||\n|---------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ` abstract void` | ` `[check](/reference/java/security/cert/CertPathChecker#check(java.security.cert.Certificate))`(`[Certificate](/reference/java/security/cert/Certificate)` cert) ` Performs the check(s) on the specified certificate using its internal state. |\n| ` abstract void` | ` `[init](/reference/java/security/cert/CertPathChecker#init(boolean))`(boolean forward) ` Initializes the internal state of this `CertPathChecker`. |\n| ` abstract boolean` | ` `[isForwardCheckingSupported](/reference/java/security/cert/CertPathChecker#isForwardCheckingSupported())`() ` Indicates if forward checking is supported. |\n\nPublic methods\n--------------\n\n### check\n\nAdded in [API level 24](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\n```\npublic abstract void check (Certificate cert)\n```\n\nPerforms the check(s) on the specified certificate using its internal\nstate. The certificates are presented in the order specified by the\n`init` method.\n\n\u003cbr /\u003e\n\n| Parameters ||\n|--------|-------------------------------------------------------|\n| `cert` | `Certificate`: the `Certificate` to be checked \u003cbr /\u003e |\n\n| Throws ||\n|----------------------------------------------------------------------------------------|------------------------------------------------------|\n| [CertPathValidatorException](/reference/java/security/cert/CertPathValidatorException) | if the specified certificate does not pass the check |\n\n### init\n\nAdded in [API level 24](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\n```\npublic abstract void init (boolean forward)\n```\n\nInitializes the internal state of this `CertPathChecker`.\n\nThe `forward` flag specifies the order that certificates will\nbe passed to the [check](/reference/java/security/cert/CertPathChecker#check(java.security.cert.Certificate)) method (forward or reverse).\n\n\u003cbr /\u003e\n\n| Parameters ||\n|-----------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `forward` | `boolean`: the order that certificates are presented to the `check` method. If `true`, certificates are presented from target to trust anchor (forward); if `false`, from trust anchor to target (reverse). \u003cbr /\u003e |\n\n| Throws ||\n|----------------------------------------------------------------------------------------|----------------------------------------------------------------------------------|\n| [CertPathValidatorException](/reference/java/security/cert/CertPathValidatorException) | if this `CertPathChecker` is unable to check certificates in the specified order |\n\n### isForwardCheckingSupported\n\nAdded in [API level 24](/guide/topics/manifest/uses-sdk-element#ApiLevels) \n\n```\npublic abstract boolean isForwardCheckingSupported ()\n```\n\nIndicates if forward checking is supported. Forward checking refers\nto the ability of the `CertPathChecker` to perform its checks\nwhen certificates are presented to the `check` method in the\nforward direction (from target to trust anchor).\n\n\u003cbr /\u003e\n\n| Returns ||\n|-----------|-------------------------------------------------------------------|\n| `boolean` | `true` if forward checking is supported, `false` otherwise \u003cbr /\u003e |"]]