Functions#

This section provides a reference to the ECDH Crypto API functions.

Functions#

sl_status_t
sl_si91x_ecdh_point_addition(sl_si91x_ecdh_mode_t ecdh_mode, uint8_t *sx, uint8_t *sy, uint8_t *sz, uint8_t *tx, uint8_t *ty, uint8_t *tz, uint8_t *rx, uint8_t *ry, uint8_t *rz)

Compute the ECDH point addition vector.

sl_status_t
sl_si91x_ecdh_point_subtraction(sl_si91x_ecdh_mode_t ecdh_mode, uint8_t *sx, uint8_t *sy, uint8_t *sz, uint8_t *tx, uint8_t *ty, uint8_t *tz, uint8_t *rx, uint8_t *ry, uint8_t *rz)

Compute the ECDH point subtraction vector.

sl_status_t
sl_si91x_ecdh_point_multiplication(sl_si91x_ecdh_mode_t ecdh_mode, uint8_t *d, uint8_t *sx, uint8_t *sy, uint8_t *sz, uint32_t affinity, uint8_t *rx, uint8_t *ry, uint8_t *rz, uint8_t reverse)

Compute the ECDH point multiplication vector.

sl_status_t
sl_si91x_ecdh_point_double(sl_si91x_ecdh_mode_t ecdh_mode, uint8_t *sx, uint8_t *sy, uint8_t *sz, uint8_t *rx, uint8_t *ry, uint8_t *rz)

Compute the ECDH point double vector.

sl_status_t
sl_si91x_ecdh_point_affine(sl_si91x_ecdh_mode_t ecdh_mode, uint8_t *sx, uint8_t *sy, uint8_t *sz, uint8_t *rx, uint8_t *ry, uint8_t *rz)

Compute the ECDH point affinity vector.

Function Documentation#

sl_si91x_ecdh_point_addition#

sl_status_t sl_si91x_ecdh_point_addition (sl_si91x_ecdh_mode_t ecdh_mode, uint8_t * sx, uint8_t * sy, uint8_t * sz, uint8_t * tx, uint8_t * ty, uint8_t * tz, uint8_t * rx, uint8_t * ry, uint8_t * rz)

Compute the ECDH point addition vector.

Parameters
TypeDirectionArgument NameDescription
sl_si91x_ecdh_mode_t[in]ecdh_mode

ECDH mode of type sl_si91x_ecdh_mode_t

uint8_t *[in]sx

Pointer to x coordinate of the point1 that needs to be added

uint8_t *[in]sy

Pointer to y coordinate of the point1 that needs to be added

uint8_t *[in]sz

Pointer to z coordinate of the point1 that needs to be added

uint8_t *[in]tx

Pointer to x coordinate of the point2 that needs to be added

uint8_t *[in]ty

Pointer to y coordinate of the point2 that needs to be added

uint8_t *[in]tz

Pointer to z coordinate of the point2 that needs to be added

uint8_t *[out]rx

Pointer to x coordinate of the result point

uint8_t *[out]ry

Pointer to y coordinate of the result point

uint8_t *[out]rz

Pointer to z coordinate of the result point

This is a blocking API. Returns


sl_si91x_ecdh_point_subtraction#

sl_status_t sl_si91x_ecdh_point_subtraction (sl_si91x_ecdh_mode_t ecdh_mode, uint8_t * sx, uint8_t * sy, uint8_t * sz, uint8_t * tx, uint8_t * ty, uint8_t * tz, uint8_t * rx, uint8_t * ry, uint8_t * rz)

Compute the ECDH point subtraction vector.

Parameters
TypeDirectionArgument NameDescription
sl_si91x_ecdh_mode_t[in]ecdh_mode

ECDH mode of type sl_si91x_ecdh_mode_t

uint8_t *[in]sx

Pointer to x coordinate of the point1 that needs to be subtracted

uint8_t *[in]sy

Pointer to y coordinate of the point1 that needs to be subtracted

uint8_t *[in]sz

Pointer to z coordinate of the point1 that needs to be subtracted

uint8_t *[in]tx

Pointer to x coordinate of the point2 that needs to be subtracted

uint8_t *[in]ty

Pointer to y coordinate of the point2 that needs to be subtracted

uint8_t *[in]tz

Pointer to z coordinate of the point2 that needs to be subtracted

uint8_t *[out]rx

Pointer to x coordinate of the result point

uint8_t *[out]ry

Pointer to y coordinate of the result point

uint8_t *[out]rz

Pointer to z coordinate of the result point

This is a blocking API. Returns


sl_si91x_ecdh_point_multiplication#

sl_status_t sl_si91x_ecdh_point_multiplication (sl_si91x_ecdh_mode_t ecdh_mode, uint8_t * d, uint8_t * sx, uint8_t * sy, uint8_t * sz, uint32_t affinity, uint8_t * rx, uint8_t * ry, uint8_t * rz, uint8_t reverse)

Compute the ECDH point multiplication vector.

Parameters
TypeDirectionArgument NameDescription
sl_si91x_ecdh_mode_t[in]ecdh_mode

ECDH mode of type sl_si91x_ecdh_mode_t

uint8_t *[in]d

Pointer to scalar value that needs to be multiplied

uint8_t *[in]sx

Pointer to x coordinate of the point to be multiplied with scalar ‘d’

uint8_t *[in]sy

Pointer to y coordinate of the point to be multiplied with scalar ‘d’

uint8_t *[in]sz

Pointer to z coordinate of the point to be multiplied with scalar ‘d’

uint32_t[in]affinity
  • 0 : no affinity

  • 1 : affinity on input

  • 2 : affinity on output

  • 3 : affinity on both input and output

uint8_t *[out]rx

Pointer to x coordinate of the result point

uint8_t *[out]ry

Pointer to y coordinate of the result point

uint8_t *[out]rz

Pointer to z coordinate of the result point

uint8_t[in]reverse

Setting this will perform reverse_8 on the inputs and outputs.

This is a blocking API. Returns


sl_si91x_ecdh_point_double#

sl_status_t sl_si91x_ecdh_point_double (sl_si91x_ecdh_mode_t ecdh_mode, uint8_t * sx, uint8_t * sy, uint8_t * sz, uint8_t * rx, uint8_t * ry, uint8_t * rz)

Compute the ECDH point double vector.

Parameters
TypeDirectionArgument NameDescription
sl_si91x_ecdh_mode_t[in]ecdh_mode

ECDH mode of type sl_si91x_ecdh_mode_t

uint8_t *[in]sx

Pointer to x coordinate of the point1 that needs to be doubled

uint8_t *[in]sy

Pointer to y coordinate of the point1 that needs to be doubled

uint8_t *[in]sz

Pointer to z coordinate of the point1 that needs to be doubled

uint8_t *[out]rx

Pointer to x coordinate of the result point

uint8_t *[out]ry

Pointer to y coordinate of the result point

uint8_t *[out]rz

Pointer to z coordinate of the result point

This is a blocking API. Returns


sl_si91x_ecdh_point_affine#

sl_status_t sl_si91x_ecdh_point_affine (sl_si91x_ecdh_mode_t ecdh_mode, uint8_t * sx, uint8_t * sy, uint8_t * sz, uint8_t * rx, uint8_t * ry, uint8_t * rz)

Compute the ECDH point affinity vector.

Parameters
TypeDirectionArgument NameDescription
sl_si91x_ecdh_mode_t[in]ecdh_mode

ECDH mode of type sl_si91x_ecdh_mode_t

uint8_t *[in]sx

Pointer to x coordinate of the point1

uint8_t *[in]sy

Pointer to y coordinate of the point1

uint8_t *[in]sz

Pointer to z coordinate of the point1

uint8_t *[out]rx

Pointer to x coordinate of the result point

uint8_t *[out]ry

Pointer to y coordinate of the result point

uint8_t *[out]rz

Pointer to z coordinate of the result point

This is a blocking API. Returns