ts-algochat
    Preparing search index...

    Function verifyEncryptionKey

    • Verifies that an encryption public key was signed by an Ed25519 key.

      This checks that the signature over the X25519 encryption key was created by the Ed25519 private key corresponding to the given public key.

      Parameters

      • encryptionPublicKey: Uint8Array

        The X25519 public key (32 bytes)

      • verifyingKey: Uint8Array

        The Ed25519 public key (32 bytes, e.g., Algorand address bytes)

      • signature: Uint8Array

        The Ed25519 signature to verify (64 bytes)

      Returns boolean

      true if the signature is valid, false otherwise

      If the key or signature lengths are invalid