Skip to content
This repository was archived by the owner on Mar 5, 2024. It is now read-only.

Commit b3946f5

Browse files
author
hackermnementh
authored
Merge pull request #9 from flavio-santes/bugs
ecc_dh: Fix discrepancy of ecc_make_key definition and declaration. Filed issue: #12
2 parents ceac249 + dce6bb1 commit b3946f5

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

lib/include/tinycrypt/ecc_dh.h

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -83,22 +83,20 @@ extern "C" {
8383
* @return returns TC_CRYPTO_SUCCESS (1) if the key pair was generated successfully
8484
* returns TC_CRYPTO_FAIL (0) if:
8585
* the private key is 0
86-
86+
*
8787
* @param p_publicKey OUT -- the point representing the public key.
8888
* @param p_privateKey OUT -- the private key.
8989
* @param p_random IN -- The random number to use to generate the key pair.
9090
*
9191
* @note You must use a new non-predictable random number to generate each
9292
* new key pair.
93-
* @note p_random must have NUM_ECC_DIGITS*2 bits of entropy to eliminate
94-
* bias in keys.
9593
*
9694
* @note side-channel countermeasure: algorithm strengthened against timing
9795
* attack.
9896
*/
9997
int32_t ecc_make_key(EccPoint *p_publicKey,
10098
uint32_t p_privateKey[NUM_ECC_DIGITS],
101-
uint32_t p_random[NUM_ECC_DIGITS * 2]);
99+
uint32_t p_random[NUM_ECC_DIGITS]);
102100

103101
/**
104102
* @brief Determine whether or not a given point is on the chosen elliptic curve

0 commit comments

Comments
 (0)