ecdhGenerateKeyPair()

The function generates a random private/public key pair for an ECDH key exchange.

Synopsis

int ecdhGenerateKeyPair()

Parameters

Parameter Meaning
- -

Return value

The ID of the key pair, which is always bigger than or equal to 0.

Error

In case of an error, an exception is thrown.

Description

The function generates a random private/public key pair and returns the ID of the key pair (>= 0). The key pair is then available for an Elliptic-curve Diffie-Hellman (ECDH) key exchange

Note: The name of the ECDH curve to use can be configured with the already existing config entry [allSections] ECDHCurve.

Assignment

Communication functions

Availability

CTRL