FSPDF_SECURITYHANDLER_FDRM Struct Reference

Structure for Foxit DRM security handler. More...

#include <fpdf_security_r.h>

Public Attributes

FS_LPVOID clientData
 User-defined data. More...
 
FS_RESULT(* GetDecryptionParams )(FS_LPVOID clientData, FSCRT_FILE file, const FSCRT_BSTR *subFilter, FS_BOOL *isOwner, FS_DWORD *userPermissions, FS_INT32 *cipher, FS_INT32 *keyLen, FSCRT_BSTR *fileID, FSCRT_BSTR *initialKey)
 Get decryption parameters. More...
 

Detailed Description

Structure for Foxit DRM security handler.

Note
This is a handler and is implemented by caller.
When host application wants to use Foxit DRM to decrypt, this handler should be implemented and function FSPDF_Security_SetFoxitDRMHandler should be called to set this handler to Foxit PDF SDK.

Member Data Documentation

FS_LPVOID FSPDF_SECURITYHANDLER_FDRM::clientData

User-defined data.

Note
Caller can use this field to track controls.
FS_RESULT(* FSPDF_SECURITYHANDLER_FDRM::GetDecryptionParams) (FS_LPVOID clientData, FSCRT_FILE file, const FSCRT_BSTR *subFilter, FS_BOOL *isOwner, FS_DWORD *userPermissions, FS_INT32 *cipher, FS_INT32 *keyLen, FSCRT_BSTR *fileID, FSCRT_BSTR *initialKey)

Get decryption parameters.

Parameters
[in]clientDataPointer to user-defined data.
[in]fileHandle to a FSCRT_FILE object which is a PDF file object to be opened or decrypted.
[in]subFilterPointer to a FSCRT_BSTR structure which is the sub filter of encryption.
[out]isOwnerPointer to a FS_BOOL object that indicates to open PDF file as owner or user: TRUE means owner, or FALSE means user.
[out]userPermissionsPointer to a FS_DWORD object that receives user permissions. Please refer to macro definitions FSPDF_PERMISSION_XXX and this would be one or a combination of these macros.
[out]cipherPointer to a FS_INT32 object that receives cipher type. It would be one of the following macro definitions:
[out]keyLenPointer to a FS_INT32 object that specifies the key length in bytes. To FSCRT_CIPHER_RC4 cipher, this parameter is between 5 and 16. To FSCRT_CIPHER_AES cipher, this parameter can be 16 or 32.
[out]fileIDPointer to a FSCRT_BSTR structure that receives file identity code. This can be empty.
[out]initialKeyPointer to a FSCRT_BSTR structure that receives initial key value. This can be empty, but recommended strongly.
Returns
FSCRT_ERRCODE_SUCCESS for success.
For more error codes, please refer to macro definitions FSCRT_ERRCODE_XXX.

The documentation for this struct was generated from the following file:

Foxit Corporation