Contains the properties required to configure the encryption of Message payloads.

Hierarchy

  • Crypto

Methods

  • Generates a random key to be used in the encryption of the channel. If the language cryptographic randomness primitives are blocking or async, a callback is used. The callback returns a generated binary key.

    Parameters

    • Optional keyLength: number

      The length of the key, in bits, to be generated. If not specified, this is equal to the default keyLength of the default algorithm: for AES this is 256 bits.

    • Optional callback: StandardCallback<unknown>

      A function which, upon success, will be called with the generated key as a binary, for example, a byte array. Upon failure, the function will be called with information about the error.

    Returns void

Generated using TypeDoc