edgeport - v1.0.3
    Preparing search index...

    Function deriveShared

    • Derives the 32-byte shared secret (the x-coordinate) from our private key and the server's uncompressed public point.

      Parameters

      • privateKey: CryptoKey

        Our ephemeral private key.

      • peerPublicKey: Uint8Array

        The server's uncompressed public point (65 bytes).

      Returns Promise<Uint8Array<ArrayBufferLike>>

      The 32-byte shared secret K.

      If the peer point cannot be imported.

      1.0.0