safequard-api-for-react-native
    Preparing search index...

    Function safequard_mlkem768_init

    • Parameters

      • context: Uint8Array

        The buffer for the internal context. Must have size at least 5985.

      • encap_key: Uint8Array

        The buffer to the encapsulation key. Must have size 1184.

      Returns void

      Generate a new ML-KEM-768 keypair for encrypting and decrypting messages.

      Generate a new ML-KEM-768 keypair.

      This function should be called by the receiver of the encrypted messages. On successful execution of this function, context contains information for the receiver to decrypt the messages sent by the sender. The encapsulation (public) key bytes encap_key are expected to be transferred to the sender.

      Related functions: safequard_mlkem768_encrypt(), safequard_mlkem768_decrypt(), safequard_mlkem768_finalise().

      if any argument is invalid.