PDFium Delphi Component Docs

FPdfTsaWin unit

Unit: FPdfTsaWin
Windows WinHttp timestamp transport backend that posts an RFC 3161 request to a timestamp authority URL and returns the response bytes

Syntax

const TsaMaxResponseBytes= 4* 1024* 1024;
function WinHttpAvailable: Boolean;
function PostTimeStampQuery(const TsaUrl: string; const ReqDer: TBytes;
  out RespDer: TBytes): Boolean;

Description

FPdfTsaWin is the Windows-specific timestamp transport consumed by FPdfTsa. It uses the WinHttp API to POST an encoded TimeStampReq to a timestamp authority URL and collect the TimeStampResp bytes

WinHttpAvailable reports whether the WinHttp bindings resolve on this machine; PostTimeStampQuery performs the actual HTTP exchange and returns False (rather than raising) when the request fails at the transport level, letting the caller apply its own retry policy

All WinHttp handle and function-pointer bindings live in the implementation section; the interface exposes only the availability check and the post helper

Functions

FunctionDescription
WinHttpAvailableReturns True when the WinHttp transport bindings can be resolved at runtime
PostTimeStampQueryPOSTs a TimeStampReq to a TSA URL and returns the response DER; returns False on transport failure

Constants

ConstantPurpose
TsaMaxResponseBytesUpper bound on a timestamp response, 4 MB; a reply that exceeds it is abandoned rather than accumulated, so a hostile or broken authority cannot exhaust memory. The transports on other platforms enforce the same limit

Remarks

See Also

FPdfTsa