PDFium Delphi Component Docs

FPdfTsaPosix unit

Unit: FPdfTsaPosix
Native Delphi POSIX transport for RFC 3161 timestamp queries over HTTP

Syntax

function TsaHttpAvailable: Boolean;
function TsaHttpBackendName: string;
function PostTimeStampQuery(const TsaUrl: string; const ReqDer: TBytes; out RespDer: TBytes): Boolean;

Description

FPdfTsa chooses this transport for Delphi POSIX targets; System.Net.HttpClient sends an actual HTTP or HTTPS POST using Content-Type: application/timestamp-query and Accept: application/timestamp-reply

The facade instead delegates to FPdfTsaWin on Windows or FPdfTsaFpc for native Free Pascal, keeping older Windows Delphi packages independent of the POSIX HTTP implementation

Transport availability concerns the selected HTTP backend only; it establishes neither TSA reachability nor signer-certificate trust or timestamp validity

Functions

FunctionDescription
TsaHttpAvailableIndicates whether the platform's chosen HTTP transport can be used
TsaHttpBackendNameNames System.Net.HttpClient on Delphi POSIX, or returns the delegated Windows/Free Pascal backend's name
PostTimeStampQueryPOSTs the supplied DER query to TsaUrl, accepting a nonempty 2xx body within the allowance and returning it in RespDer; failure clears the output and returns False

Limits and subsequent verification

Delphi limits both request and response bodies to 4 MiB and URLs to 8192 string code units; only HTTP and HTTPS are permitted, without redirects

Connection, sending and response timeouts are each set to 30000 milliseconds; a deadline worker requests native HTTP cancellation when the overall 30000 millisecond allowance expires. Limited response-stream writes and the completed-response check also refuse elapsed-budget violations, whilst the OS HTTP implementation determines how quickly cancellation takes effect

HTTPS keeps platform certificate and hostname checks. A successful POST establishes transport success alone: FPdfTsa must still parse the RFC 3161 response, verify imprint and nonce, and extract the token; PAdES trust validation separately verifies the original token's CMS signature, chain, revocation evidence and timestamp role

A 2xx body can still contain a TSA DER rejection, which the higher-level parser reports as an unsuccessful timestamp request

See Also

FPdfTsa, FPdfTsaFpc, FPdfTsaWin, TPdf.ValidatePadesTrust