HTTP(S), LDAP, LDAPS and StartTLS transport helpers are shared core infrastructure; Enterprise functionality covers the higher-level trusted-signature, evidence and long-term validation workflows. Transport availability alone does not establish signer trust; see the edition matrix
type
EPdfSslError = class(Exception);
TPdfSslCapabilities = record
Available: Boolean;
DetachedVerification: Boolean;
AttachedVerification: Boolean;
SystemTrustStore: Boolean;
CustomTrustAnchors: Boolean;
LocalCrls: Boolean;
ChainCertificateCollection: Boolean;
OnlineRetrieval: Boolean;
RetrievalTimeout: Boolean;
RevocationDiagnostics: Boolean;
SignerDiagnostics: Boolean;
RevocationCertificateCollection: Boolean;
Signing: Boolean;
OcspVerification: Boolean;
end;
TPdfSslVerifyDiagnostic = (psvdBackendUnavailable, psvdOnlineRetrievalIgnored,
psvdRetrievalTimeoutIgnored, psvdNoCrlsConfigured);
TPdfSslVerifyDiagnostics = set of TPdfSslVerifyDiagnostic;
TPdfSslCmsVerifier = class(TInterfacedObject, IPdfCmsVerifier)
public
constructor Create; overload;
constructor Create(const LdapTlsOptions: TPdfLdapTlsOptions); overload;
function BackendName: string;
function VerifyDetached(const CmsDer: TBytes; Segment1: Pointer; Segment1Length: Cardinal; Segment2: Pointer; Segment2Length: Cardinal; const Options: TPdfCmsVerifyOptions): TPdfCmsVerifyResult;
function VerifyAttached(const CmsDer: TBytes; const Options: TPdfCmsVerifyOptions): TPdfCmsVerifyResult;
end;
procedure ConfigureSslLibraryPath(const APath: string);
function SslAvailable: Boolean;
function SslMissingSymbols: string;
function SslLibraryPath: string;
function SslLibraryVersion: string;
function SslAbiLayout: string;
function SslCapabilities: TPdfSslCapabilities;
function SslVerifyOptionsDiagnostics(const Options: TPdfCmsVerifyOptions): TPdfSslVerifyDiagnostics;
procedure ConfigureSslTrustAnchors(const Anchors: TPadesChainCertArray);
procedure ConfigureSslCrls(const Crls: TPadesChainCertArray);
procedure ConfigureSslOcspResponses(const Responses: TPadesChainCertArray);
function ConfigureSslCmsVerifier: IPdfCmsVerifier;
procedure ConfigureSslSigningCredentials(const PrivateKeyPem,
SignerCertificateDer: TBytes; const ChainCertificateDer:
TPadesChainCertArray; const Password: AnsiString = '');
function SslSigningAvailable: Boolean;
function SslSha3SigningAvailable: Boolean;
function ResolveSslSigner(const Options: TPadesSignerOptions): TPadesResolvedSigner;
function ResolveSslSignerForDigest(const Options: TPadesSignerOptions;
DigestAlgorithm: TCmsDigestAlgorithm): TPadesResolvedSigner;
FPdfCryptoHttp retrieval transport
CryptoHttpMaxResponseBytes = 1024*1024;
CryptoHttpMaxTotalBytes = 4*1024*1024;
CryptoHttpMaxRequests = 8;
CryptoHttpMaxUrlLength = 2048;
CryptoHttpDefaultTimeoutMs = 30000;
TPdfLdapTlsMode = (pltDisabled, pltLdaps, pltStartTls);
TPdfLdapTlsStatus = (pltsNotRequested, pltsUnavailable, pltsPolicyRejected, pltsHandshakeFailed, pltsActive);
TPdfLdapTlsOptions = record
Mode: TPdfLdapTlsMode;
CaCertificateFile: string;
class function Default: TPdfLdapTlsOptions; static;
end;
TPdfCryptoFetchSession = class
public
constructor Create(TimeoutMs: Cardinal); overload;
constructor Create(TimeoutMs: Cardinal; const LdapTlsOptions: TPdfLdapTlsOptions); overload;
constructor Create(TimeoutMs: Cardinal; const LdapTlsOptions: TPdfLdapTlsOptions; Policy: TPdfCryptoRetrievalPolicy; const AllowedOrigins: TPdfCryptoRetrievalOrigins); overload;
property LastLdapTlsStatus: TPdfLdapTlsStatus read FLastLdapTlsStatus;
function RemainingMs: Cardinal;
function Fetch(const Url: string; out Data: TBytes): Boolean;
end;
function CryptoHttpAvailable: Boolean;
function CryptoLdapAvailable: Boolean;
function CryptoLdapTlsAvailable: Boolean;
FPdfCryptoSsl is the OpenSSL CMS verification backend consumed by FPdfCrypto, the counterpart of what FPdfCryptoWin provides on Windows. It verifies a CMS SignedData value against the signed content, resolves the signer certificate, and evaluates the certificate chain against the OpenSSL system store extended with whatever trust anchors and CRLs the caller has configured
libcrypto is bound at run time by name rather than linked, which keeps the dependency optional and lets the unit compile on every target. ConfigureSslLibraryPath overrides the library that is loaded; passing an empty path restores the built-in candidate list for the platform
Free Pascal uses its native dynamic-library loader, Windows Delphi uses the Windows loader, and POSIX Delphi uses dlopen and dlsym. Select an actual library matching the executable's OS and CPU. macOS applications can use this backend alongside the Keychain verifier, whose declared SHA-2 RSA-PSS profile is verified through native SecKey since v3.212.0
SslAvailable, SslMissingSymbols, SslLibraryPath, SslLibraryVersion and SslAbiLayout report the state of that binding, so an application can decide at startup whether CMS verification will be possible on this host and can log which library answered
SslCapabilities condenses what this backend implements into one TPdfSslCapabilities record, and SslVerifyOptionsDiagnostics reports before a verification runs which TPdfCmsVerifyOptions settings would have no effect here, as a TPdfSslVerifyDiagnostics set a caller can surface as warnings
ConfigureSslTrustAnchors, ConfigureSslCrls, and ConfigureSslOcspResponses supply explicit DER evidence beyond the system store. ConfigureSslCmsVerifier installs the CMS verifier used by PAdES validation, raising EPdfSslError when OpenSSL is unavailable
TPdfSslCmsVerifier implements IPdfCmsVerifier. VerifyDetached joins the two byte ranges either side of the signature hole into one signed content stream, which is the shape a PDF signature takes; VerifyAttached covers a value that carries its own content, such as a timestamp token
ConfigureSslSigningCredentials supplies the private key, certificate, and optional chain used by ResolveSslSigner and the non-Windows default signing resolver. Verification does not require signing credentials
ResolveSslSignerForDigest extends the same resolution to SHA-3: the resolved signer declares id-sha3-256, id-sha3-384 or id-sha3-512, pairs it with the matching sha3-256WithRSAEncryption or ecdsa-with-SHA3-* signature algorithm, signs the digest through EVP_PKEY_sign with the digest set to the EVP SHA-3 object, and describes the same digest in the RSASSA-PSS parameters with a salt equal to its output length. Because OpenSSL 3 provides those digests everywhere, this is what makes the ISO/TS 32001 algorithms usable outside Windows
The online retrieval half lives in FPdfCryptoHttp: bounded HTTP(S) transport for AIA intermediates, CRL distribution points, and OCSP requests, plus Windows LDAP since v3.204.0 and optional FPC Unix OpenLDAP since v3.205.0. CryptoHttpAvailable and CryptoLdapAvailable report protocol-specific readiness; TPdfCryptoFetchSession enforces the shared per-call request, byte, and time budgets, and its HTTP(S) fetches run over WinHttp on Windows and over the FPdfCryptoHttpCurl libcurl backend on Linux and macOS
Since v3.170.0 OCSP requests whose GET encoding exceeds the RFC 6960 A.1 practical URL limit submit the full serialised OCSPRequest through TPdfCryptoFetchSession.FetchPost as an HTTP POST body with the application/ocsp-request content type; shorter requests keep the GET form. LDAP retrieval supports binary certificates and CRLs on the declared Windows/FPC Unix backends, while OCSP remains an HTTP(S) operation. On Windows, the asynchronous request retains its own POST data until WinHTTP finishes closing the request handle
| Function | Description |
|---|---|
ConfigureSslLibraryPath | Overrides the libcrypto library the backend loads; call it before the first use, and pass an empty APath to restore the built-in candidate list for the platform |
SslAvailable | Returns True when libcrypto loaded and every required symbol resolved |
SslMissingSymbols | Returns the names that failed to resolve, separated by spaces, or an empty string when everything bound; a non-empty result on a host that has libcrypto means the build is older than the API this unit targets |
SslLibraryPath | Returns the path of the library that loaded, or an empty string |
SslLibraryVersion | Returns the version string libcrypto reports, or an empty string |
SslAbiLayout | Reports the C type widths this build assumes, as ulong=<n> long=<n>; OpenSSL error-queue codes and store flags use C unsigned long, while X509 verification errors use C int |
SslCapabilities | Returns a TPdfSslCapabilities record describing the operations this backend implements; the flags describe implemented operations, not successful checks |
SslVerifyOptionsDiagnostics | Returns, as a TPdfSslVerifyDiagnostics set, the option effects to expect from Options under this backend before verification runs; configured CRLs still need to decode, cover the chain, and be current before revocation can be valid |
ConfigureSslTrustAnchors | Supplies the trust anchors, as DER in Anchors, that chain evaluation adds to the system store; an empty array leaves the evaluation with the system store alone |
ConfigureSslCrls | Supplies DER CRLs consulted during revocation checking; missing CRL coverage may be supplemented by authenticated OCSP evidence |
ConfigureSslOcspResponses | Clones up to 8 DER responses, at most 1 MiB each and 4 MiB in total, for native authentication during verification; an empty array clears the configuration |
ConfigureSslSigningCredentials | Validates and clones a PEM private key, matching DER certificate, optional DER chain, and optional encrypted PEM password; passing empty key, certificate, and chain clears the credentials, while an invalid replacement preserves the previous configuration |
SslSigningAvailable | Returns True only when the optional signing symbols and explicitly configured credentials are available |
ResolveSslSigner | Returns an ICmsSigner, matching certificate, and configured chain for Options; a nonempty certificate thumbprint is rejected because configuration has already selected the certificate |
SslSha3SigningAvailable | Returns True when plain signing is available and the loaded libcrypto also exposes EVP_sha3_256, EVP_sha3_384 and EVP_sha3_512, which OpenSSL 3 carries on every platform, so a caller can offer the ISO/TS 32001 digests only where a signature can actually be produced |
ResolveSslSignerForDigest | Returns the same triple for a chosen TCmsDigestAlgorithm. SHA-256 forwards to ResolveSslSigner, so a caller that never asked for SHA-3 sees no change; a SHA-3 member produces a signer that declares the matching digestAlgorithm and signature algorithm, signs the matching digest length, and sizes the RSA-PSS salt to the digest. The call raises EPadesCrypto when the loaded library lacks the digest entry points rather than quietly signing with SHA-256 |
ConfigureSslCmsVerifier | Builds an OpenSSL verifier and installs it as the CMS verification backend, returning it as an IPdfCmsVerifier |
CryptoHttpAvailable | Reports HTTP(S) readiness: always True on supported Windows hosts using WinHTTP, and elsewhere only when FPdfCryptoHttpCurl can bind a suitable libcurl; False does not exclude independent LDAP retrieval since v3.205.0 |
CryptoLdapAvailable | Reports LDAP readiness: True for the Windows system client, or for FPC Unix after the optional OpenLDAP library and every required API export bind successfully; otherwise False. The initial Unix binding result is cached, so installing a dependency after a failed first query requires a new process. Readiness does not certify a server, a platform profile or any verification outcome |
| Type | Members and purpose |
|---|---|
EPdfSslError | Exception raised by ConfigureSslCmsVerifier when OpenSSL is not available; the message carries the unresolved names reported by SslMissingSymbols |
TPdfSslCapabilities | Available, DetachedVerification, AttachedVerification, SystemTrustStore, CustomTrustAnchors, LocalCrls, and ChainCertificateCollection describe core verification operations; OnlineRetrieval and RetrievalTimeout additionally require at least one available HTTP(S) or LDAP transport, and RevocationDiagnostics requires the optional native error-capture bindings. SignerDiagnostics and RevocationCertificateCollection report diagnostic support; Signing reports optional signing symbols, independently of configured credentials; OcspVerification reports optional native OCSP symbols. None of these flags proves that a verification succeeded |
TPdfSslVerifyDiagnostic | psvdBackendUnavailable, psvdOnlineRetrievalIgnored, psvdRetrievalTimeoutIgnored, or psvdNoCrlsConfigured |
TPdfSslVerifyDiagnostics | Set of TPdfSslVerifyDiagnostic values returned by SslVerifyOptionsDiagnostics |
TPdfSslCmsVerifier | CMS verification through OpenSSL, implementing IPdfCmsVerifier with BackendName, VerifyDetached, and VerifyAttached |
TPdfCryptoFetchSession | One retrieval call's HTTP(S) and supported-platform LDAP transport session from FPdfCryptoHttp; it owns the shared deadline, the request counter, the cumulative byte budget, and per-session URL deduplication, and its Create, Destroy, RemainingMs, and Fetch members are described under Retrieval transport |
| Method | Description |
|---|---|
BackendName | Returns OpenSSL, the name under which this backend identifies itself in validation results |
VerifyDetached | Verifies the detached CMS value in CmsDer against the content described by Segment1 / Segment1Length and Segment2 / Segment2Length, honoring Options, and returns signature, trust, revocation status, and revocation diagnostics in a TPdfCmsVerifyResult |
VerifyAttached | Verifies an attached CMS value in CmsDer, whose signed content travels inside the structure, using Options |
FPdfCryptoHttp implements HTTP(S) and supported-platform LDAP retrieval behind OnlineRetrieval. One TPdfCryptoFetchSession instance spans one verification call, and every fetch it performs draws from the same deadline, request allowance, and byte budget
RetrievalPolicy defaults to pcrpAllowedOrigins. Set AllowedRetrievalOrigins to trusted origins such as https://pki.example.com or ldap://directory.example.com:389. Matching uses the scheme, host, and effective port. Entries omit paths and queries. An empty list denies retrieval, including when OnlineRetrieval is enabled. Direct sessions use the same policy through the four-argument constructor. pcrpUnrestricted explicitly restores retrieval from document-selected origins
Allowlisted names use the transport resolver, so configure names whose DNS you trust. Select pcrpAllowedIpOrigins to require canonical dotted-quad IPv4 or bracketed IPv6 literals in both the origin list and the requested URL. Equivalent IPv6 spellings match by address bytes. Scoped IPv6 literals are rejected. This policy binds the request to the listed address and port without resolving a hostname. Use an IP subject alternative name for TLS endpoints. Restricted HTTPS on Windows requires support for configuring local-only transport certificate-chain retrieval
WinHTTP and FPC Unix builds with libcurl support pcrpPinnedHttpOrigins. Use entries such as https://pki.example.com=192.0.2.10 or https://pki.example.com=2001:db8::10. The address on the right is an unbracketed IPv4 or IPv6 literal. The connection uses that address and the origin port, while HTTP and TLS retain the request hostname. Each origin can appear once. WinHTTP requires support for its per-request hostname resolution override and rejects the request if the override cannot be set
pcrpPinnedOrigins also accepts LDAP and LDAPS origins in the same format. On Windows and FPC Linux, macOS, FreeBSD, NetBSD, DragonFly BSD, and OpenBSD, pinned LDAPS or StartTLS connects directly to the configured IPv4 or IPv6 address and verifies the certificate chain and the original origin name before sending a bind or search. FPC Unix pinning with TLS requires an OpenLDAP library with ldap_init_fd and TLS entry points. On macOS, set PDFIUMPAS_OPENLDAP_LIBRARY to the absolute path of a compatible dylib before the first LDAP call. The macOS system LDAP binding supports plain LDAP for pinned origins. Unix pinned TLS requires a DNS name other than localhost because some OpenLDAP backends substitute the machine name. Other Unix builds can use numeric LDAP origins through pcrpAllowedIpOrigins
| Method | Description |
|---|---|
Create | Starts the session deadline; a TimeoutMs of zero selects CryptoHttpDefaultTimeoutMs, and the value is clamped to the range of Cardinal |
RemainingMs | Returns the milliseconds left on the shared deadline; fetches stop once it reaches zero |
Fetch | Downloads Url into Data, requiring a nonempty HTTP 200 response body or a successful supported-platform LDAP search with one binary value and a successful terminal result; URLs must fit CryptoHttpMaxUrlLength and the remaining budgets, exclude user information, and use http, https or the bounded ldap profile below; repeated URLs return False without consuming another request |
| Constant | Value | Meaning |
|---|---|---|
CryptoHttpMaxRequests | 8 | Maximum fetch attempts one session accepts |
CryptoHttpMaxResponseBytes | 1048576 | Maximum accepted size of a single response |
CryptoHttpMaxTotalBytes | 4194304 | Maximum cumulative accepted response bodies per session |
CryptoHttpMaxUrlLength | 2048 | Maximum URL length the parser accepts |
CryptoHttpDefaultTimeoutMs | 30000 | Session deadline used when Create receives zero |
Signature integrity, chain trust, and CRL verification run in separate passes. A revoked certificate does not change a valid SignatureStatus or the independently computed TrustStatus
Basic X509 chain validation uses X509_PURPOSE_ANY rather than assuming an S/MIME signer, allowing a TSA certificate with critical id-kp-timeStamping usage to be evaluated on its own chain. A valid chain alone does not establish an application-specific certificate role or revocation status. PAdES timestamp validation separately requires the RFC 3161 timestamp role and keeps that verdict in TimeStampTrustStatus
Only a failed CRL pass after successful chain trust that reports X509_V_ERR_CERT_REVOKED (23) produces RevocationStatus = pcvsInvalid with RevocationReason = pcrrCertificateRevoked
Expired or future CRLs, missing chain coverage, bad CRL signatures, and other unusable CRL evidence produce pcvsIndeterminate when the CRL pass fails, with pcrrCrlExpired, pcrrCrlNotYetValid, pcrrCrlUnavailable, pcrrCrlSignatureInvalid, pcrrCrlInvalid, or pcrrUnknown as appropriate. When CRL checking is enabled but the preceding trust pass failed, the result is pcvsIndeterminate with pcrrChainUntrusted
RevocationError contains the captured X509 verification error, or zero when no native diagnostic is available. Without the optional diagnostic bindings, failed CRL checks retain pcvsIndeterminate with pcrrUnknown and zero; basic CMS verification remains available
A successful CRL pass returns pcvsValid with pcrrNone and zero. The reason and error alone never prove success; inspect RevocationStatus
CMS verification stops at the first failing signer or chain condition, so the captured reason is not a complete list of errors for every signer. The diagnostic callback preserves OpenSSL's rejection decisions
For multiple signers, the statuses describe the aggregate CMS verification while SignerCertificate contains only the first signer certificate in the CMS structure. A revocation diagnostic can belong to a later signer or an issuing CA; do not attribute it automatically to SignerCertificate
A CRL containing a revoked serial still has to pass its time and signature checks. An expired CRL returns an indeterminate expiry result rather than establishing current revocation from its serial list
These diagnostics are available directly from IPdfCmsVerifier.VerifyDetached or VerifyAttached. PAdES trust validation also preserves the signature's RevocationReason and NativeRevocationError independently of TimeStampRevocationReason and NativeTimeStampRevocationError; evidence JSON and CSV export both pairs and the independent timestamp statuses
OnlineRetrieval=True opts into HTTP(S) AIA intermediate, CRL-distribution-point, and OCSP retrieval after cryptographic signature verification succeeds, plus Windows LDAP since v3.204.0 and optional FPC Unix OpenLDAP since v3.205.0; unavailable or disabled transport leaves the local verification path availableUrlRetrievalTimeoutMs=0. Oversized responses are rejected, and bytes delivered by a final rejected transport chunk can exceed the accepted-body limitcaIssuers, DER CRLs from distribution-point fullName URIs, and signed DER OCSP responses retrieved through GET or POSTSslVerifyOptionsDiagnostics reports ignored retrieval or timeout options when the selected capability cannot honor them; psvdNoCrlsConfigured describes the local configuration even when online retrieval is enabled. Option diagnostics are configuration information, not evidence that a network request or revocation check succeededSslAvailable as a precondition and use SslMissingSymbols to report why binding failedSince v3.213.0, OpenSSL AIA caIssuers responses may contain one DER X.509 certificate or a DER PKCS#7 certificates-only SignedData message with version 1, empty digestAlgorithms and signerInfos, absent id-data content, and 1 to 32 ordinary X.509 certificates. PEM, BER indefinite lengths, CRLs, attribute certificates, signed payloads, malformed certificates and trailing bytes are rejected
Every candidate is decoded before any certificate from that response is added. Duplicate certificates are counted once toward the 64-certificate untrusted-set limit, while the per-message 32-record limit also counts duplicates. Retrieved certificates never enter the trust-anchor store; OpenSSL still independently builds and validates each chain against configured or system anchors
Bundle retrieval shares the existing eight-request, 1 MiB response, 4 MiB total-body and elapsed-time budgets. The bounded DER scan permits at most 32 nesting levels and 32768 nodes; these accepted-data limits do not cap native parser allocations. A later offline call cannot reuse the downloaded candidates. Focused execution covers Delphi Win64 with the recorded OpenSSL 3 library
TPdfLdapTlsOptions.Default sets Mode=pltDisabled and an empty CaCertificateFile, preserving plain anonymous LDAP behavior and rejecting ldaps URLs. Use pltLdaps with ldaps URLs (default port 636), or pltStartTls with ldap URLs (default port 389); a mismatched scheme or CA file with disabled TLS returns pltsPolicyRejected before connecting
Pass the record and origin policy to TPdfCryptoFetchSession.Create for direct retrieval, or pass the TLS record to TPdfSslCmsVerifier.Create(LdapTlsOptions) for CMS AIA/CRL retrieval. The parameterless verifier constructor and existing factory retain disabled LDAP TLS. Configure the CMS origin policy in TPdfCmsVerifyOptions and enable OnlineRetrieval to fetch evidence
CryptoLdapTlsAvailable reports native Windows LDAPS support since v3.253.0, native Windows StartTLS since v3.261.0 and optional TLS exports on FPC Linux. Windows Delphi/FPC Win64 uses wldap32, Schannel, Crypt32 and Winsock without an additional TLS DLL; Linux uses OpenLDAP and its OpenSSL backend. Darwin and Delphi Unix TLS remain unavailable. Missing Linux TLS exports do not disable plain LDAP readiness
Each supported TLS connection requires a valid peer chain and matching subjectAltName, refuses CN-only fallback, requires TLS 1.2 or later before anonymous bind/search and refuses ambient client credentials. Linux clears inherited client certificates and validation callbacks and creates a private client TLS context. A nonempty CaCertificateFile supplies the transport CA bundle and clears inherited CA directories; an empty path uses the native system CA defaults. Transport CAs never become CMS trust anchors. No certificate-validation bypass or authenticated binding is provided
StartTLS must succeed before anonymous bind/search; rejection, certificate failure, unexpected plaintext or timeout never falls back to a plain connection. TLS handshakes and subsequent LDAP waits receive the remaining shared deadline. Native DNS, trust-file processing and parser allocations are not universally interruptible or independently memory-bounded
Windows StartTLS connects without binding, installs the same private trust and certificate callbacks as LDAPS, then calls the native upgrade operation and rechecks verified negotiated transport before bind/search
Native Windows LDAP TLS sessions queue within the process because concurrent native StartTLS operations can fail or disrupt later retrieval; queue wait consumes the same session deadline, while trust remains per connection
The native upgrade has a longer built-in timeout, so a per-connection watchdog shuts down its socket at the remaining session deadline; the owner joins that watchdog before releasing the LDAP handle, and no other session or global trust setting is changed
LastLdapTlsStatus reports the last parsed LDAP fetch: pltsNotRequested before negotiation or for plain retrieval, pltsUnavailable for an absent backend, pltsPolicyRejected for incompatible or unapplied policy, pltsHandshakeFailed for failed establishment, or pltsActive after verified TLS establishment. Active TLS does not imply a successful search, certificate trust for CMS, or a good revocation verdict; HTTP calls do not reset this LDAP-specific status
Windows validates the presented chain, serverAuth usage, digitalSignature when KeyUsage exists, certificate dates and an explicit matching DNS/IP subjectAltName. Explicit PEM roots use an exclusive in-memory chain engine and never modify OS stores or become CMS trust anchors; an empty CA path selects system transport trust. Chain building uses only cached or presented additional certificates and does not start a second network retrieval. Per-connection root sets remain independent under concurrent requests
Windows strong-crypto policy is supplemented by checking negotiated TLS 1.2/1.3 and at least 128-bit cipher strength before any anonymous LDAP bind. A legacy peer can complete a rejected transport handshake without receiving LDAP credentials or requests. Windows native connect timeouts can have coarse granularity; subsecond availability is not promised. pltsActive describes locally verified transport and can remain set when the peer subsequently rejects a missing client certificate; the fetch still fails without a payload
Linux temporarily blocks SIGPIPE in the calling thread throughout native TLS operations and cleanup, drains only a newly generated signal when the caller had not blocked it, and restores the previous mask without replacing the process handler or consuming a pre-existing pending signal
Since v3.204.0, Fetch uses the Windows wldap32.dll client for ldap:// certificate and CRL URLs with an explicit DNS/IPv4 host, a nonempty distinguished name, one recognized binary attribute, and an omitted or base search scope. An omitted filter uses (objectClass=*); percent-encoded UTF-8 names and filters are decoded without accepting embedded NUL or malformed UTF-8
Since v3.205.0, FPC Unix uses an optional OpenLDAP backend with the same URL, value and publication rules; Linux, FreeBSD, NetBSD, and DragonFly BSD look for libldap.so.2, libldap-2.5.so.0 or libldap-2.4.so.2. NetBSD first tries the pkgsrc path /usr/pkg/lib/libldap.so. OpenBSD resolves libldap.so to the installed versioned OpenLDAP library. The Darwin binding first tries the absolute dylib path in PDFIUMPAS_OPENLDAP_LIBRARY when set and otherwise uses /usr/lib/libldap.dylib or libldap.dylib. On macOS, the connection callback sets SO_NOSIGPIPE on each LDAP socket so a write failure returns a transport error while leaving the caller’s signal settings intact. Missing libraries or required exports return unavailable without replacing the HTTP backend. Focused execution covers WSL Linux x64, physical Ubuntu x64 and physical Mac ARM64 with FPC 3.3.1; the two physical hosts pass 91 main assertions each, and the Linux missing-export/no-libcurl controls remain separate from the Darwin profile. The Mac loader resolves the logical dylib through the system dyld cache to LDAP.framework; its loaded Mach-O UUID and OS identity are recorded when no standalone dylib file exists. These profiles do not qualify another Unix compiler or unexecuted architecture
Recognized attributes are cACertificate;binary, userCertificate;binary, certificateRevocationList;binary, authorityRevocationList;binary and deltaRevocationList;binary. The syntax follows the certificate retrieval use of RFC 4516 and RFC 5280 within this explicit subset
The client binds anonymously with empty credentials, disables referrals, alias dereferencing, automatic reconnect and credential prompts, and requests one entry and one attribute. Publication requires exactly one nonempty value, a successful terminal search result and a live deadline; multiple entries/values, referrals and partial/error results leave Data empty
LDAP shares the existing eight-request, 1 MiB value and 4 MiB cumulative payload limits with HTTP(S), and native connection/result waits receive the remaining session timeout. Value limits are checked after native LDAP decoding and do not bound the native parser's internal allocations or promise interruption of every internal DNS operation
Authenticated binds, IPv6 literals, non-base searches and URL extensions remain outside this profile; the opt-in FPC Linux TLS extension is described below. Retrieved certificates remain untrusted chain material and downloaded CRLs still require independent signature, issuer and validity checks
Supply a PEM private key and its matching DER certificate explicitly. The key and each certificate are limited to 4 MiB, the chain to 64 certificates, the combined key/certificate/chain input to 16 MiB, and the encrypted PEM password to 1024 bytes. Certificates must contain complete DER without trailing data; a mismatched key, unsupported key type, or invalid password rejects the replacement without changing the prior configuration
Password is supplied as an AnsiString byte sequence. The backend never prompts on standard input; an empty password is suitable for an unencrypted PEM key
RSA signing uses SHA-256 with RSA-PSS by default, SHA-256 for MGF1, and a 32-byte salt. PKCS#1 v1.5 is available for an unrestricted RSA key; an RSA-PSS restricted key rejects PKCS#1 v1.5. EC keys use ECDSA and return the DER signature form expected by CMS
TPdfSslCapabilities.Signing describes the optional OpenSSL signing bindings, while SslSigningAvailable additionally requires configured credentials. A resolved signer keeps its native key alive; release resolved signer interfaces before switching or unloading the libcrypto library
OCSP verification authenticates the responder signature, issuer or delegated responder authority, certificate identifier, and response times through OpenSSL. Each signer chain requires positive status for every non-anchor certificate; trust anchors are exempt. A good response for the leaf alone cannot cover an unchecked intermediate
Enabling online retrieval does not itself attempt OCSP verification. If no configured or retrieved OCSP response is examined and no responder URL is requested, the preceding CRL status, reason, native error, and affected certificate remain intact. An actual OCSP attempt can replace that verdict with its authenticated result or an indeterminate OCSP diagnostic
Responses pass the bounded freshness prefilter in FPdfCryptoOcsp before native authentication. The permitted clock skew is 300 seconds, producedAt and thisUpdate must be at most one day old, and a supplied nextUpdate must still be valid. The prefilter never authenticates a response
Online OCSP uses an RFC 5019 GET URL formed from the encoded request; requests carry no nonce and have no POST fallback. OCSP, AIA, and CRL requests share the same 8-request, 1 MiB response, 4 MiB total-body, and elapsed-time limits. Redirects remain disabled
Evidence retrieved during the aggregate verification is reused for offline signer diagnostics in the same call. Diagnostics do not issue more requests; an exhausted deadline or unavailable response leaves the affected snapshot indeterminate rather than treating it as positively checked
Optional signing or OCSP symbols may be absent while ordinary CMS verification remains available. Inspect SslCapabilities.OcspVerification and the result's RevocationStatus, rather than treating configuration or pcrrNone as proof of success
CollectSignerDiagnostics returns bounded offline SignerResults in encoded SignerInfo order, with a separate signature, trust, and revocation result for each signer. Collection is limited to 64 signers, 4 MiB of CMS input, and 64 MiB of aggregate diagnostic input/output work
SignerDiagnosticsStatus=pcvsValid means collection completed, including any invalid signer results; it is not a signature verdict. Read each snapshot's statuses and errors. RevocationCertificate identifies a captured failing certificate, including an intermediate when available, and is distinct from SignerCertificate