5.20202.699
Wijmo API Module wijmo.pdf.security Wijmo API Module

wijmo.pdf.security Module

Provides PDF encryption and permissions settings for the wijmo.pdf module.

Add this module on page to be able to use the wijmo.pdf.IPdfDocumentOptions.ownerPassword, wijmo.pdf.IPdfDocumentOptions.permissions and wijmo.pdf.IPdfDocumentOptions.userPassword properties while creating an instance of the wijmo.pdf.PdfDocument class:

import { PdfDocument, saveBlob } from '@grapecity/wijmo.pdf';
import '@grapecity/wijmo.pdf.security';

let doc = new PdfDocument({
   userPassword: 'abc',
   ended: (doc, args) => {
      saveBlob(args.blob, 'document.pdf');
   }
});

doc.end();

This module incorporates modified versions of the buffer, crypto-js and saslprep libraries.

Variables

Functions

Variables

CryptoJS

CryptoJS: any

CryptoJS core components.

Functions

Buffer

  • Buffer(arg: any, encodingOrOffset?: any, length?: any): void
  • The Buffer constructor returns instances of Uint8Array that have their prototype changed to Buffer.prototype. Furthermore, Buffer is a subclass of Uint8Array, so the returned instances will have all the node Buffer methods and the Uint8Array methods. Square bracket notation works as expected -- it returns a single octet.

    The Uint8Array prototype remains unmodified.

    Parameters

    • arg: any
    • Optional encodingOrOffset: any
    • Optional length: any

    Returns void

inRange

  • inRange(value: any, rangeGroup: any): boolean
  • Check if value is in a range group.

    Parameters

    • value: any
    • rangeGroup: any

    Returns boolean

    {boolean}

saslprep

  • saslprep(input: any, opts?: any): any
  • SASLprep.

    Parameters

    • input: any
    • Optional opts: any

    Returns any

    {string}