THotPDF.TryLoadedPubSecFilterKey Method

Looks up the recovered envelope key of one named public-key crypt filter in the currently loaded document. Use the result code to find out whether a filter decrypts with its own key or with the document default key

Declaration

function TryLoadedPubSecFilterKey(const FilterName: AnsiString; out Key: THPDFLoadedPubSecFilterKey): Integer;

Unit

HPDFDoc

Parameters

NamePurpose
FilterNameName of the crypt filter whose recovered key is requested, such as the stream or string crypt filter name of the loaded document
KeyReceives the matching THPDFLoadedPubSecFilterKey entry when the method returns 1

Return value

Returns 1 when the named filter carries its own recovered envelope key, 0 when it carries envelopes whose key was not recovered, and -1 when the filter has no envelopes of its own and decrypts with the document default key

Usage notes

Related APIs