PLVerifyCertificatePathPure
Cryptography, digital signatures
Description
Builds and verifies a certificate path entirely in pure Pascal, from a leaf certificate through a pool toward trusted anchors
Syntax
Delphi
Function PLVerifyCertificatePathPure(Const CertificateDER: AnsiString;
Const Pool, Anchors, CRLs: Array Of AnsiString;
VerificationTime: TDateTime; CheckRevocation: Boolean;
Out Path: TPLCertificatePath; Out Status: Integer): Boolean;Parameters
| CertificateDER | DER-encoded leaf certificate to validate |
|---|---|
| Pool | Candidate intermediate certificates, concatenated DER entries |
| Anchors | Trusted self-signed anchor certificates |
| CRLs | Complete CRLs consulted when CheckRevocation is set |
| VerificationTime | The validity point for period checks |
| CheckRevocation | Validates each certificate against the supplied CRLs |
| Path | Receives the assembled chain on success |
| Status | Receives a detailed failure code when the path does not verify |
Return values
| True | A path to an anchor was built with every signature, validity period, CA flag, key usage and path length constraint verified |
|---|---|
| False | No valid path exists; Status carries the failure reason |
Every intermediate signature, validity period at VerificationTime and CA basic-constraints flag is verified; revocation checking consumes complete CRLs only
Key usage and path length follow RFC 5280: an issuer that carries a keyUsage extension must assert keyCertSign, no more intermediates may follow an issuer than its pathLenConstraint allows, and a signer certificate that carries keyUsage must assert digitalSignature or nonRepudiation. A certificate without a keyUsage extension is not restricted, and a CA certificate verified on its own is not treated as a signer certificate. Extended key usage is not evaluated
Status is one of PL_PATH_TRUSTED (0), PL_PATH_NO_ANCHOR (1), PL_PATH_BAD_SIGNATURE (2), PL_PATH_EXPIRED (3), PL_PATH_NOT_CA (4), PL_PATH_REVOKED (5), PL_PATH_REVOCATION_UNKNOWN (6), PL_PATH_MALFORMED (7), PL_PATH_KEY_USAGE (8) or PL_PATH_PATH_LENGTH (9)
Used by the native AdES verdicts alongside PLSigningCertificateAttributeStatus
See also
PLSigningCertificateAttributeStatus, PLVerifyModernDetachedCMS, PLSplitCertificateBundle