wolfcrypt/src/curve25519.c: use endian-conditional initializer for kCurve25519BasePoint.

This commit is contained in:
Daniel Pouzzner
2023-09-01 11:36:18 -05:00
parent 136cb98412
commit 196f154c51

View File

@ -58,7 +58,13 @@ const curve25519_set_type curve25519_sets[] = {
}
};
static const word32 kCurve25519BasePoint[CURVE25519_KEYSIZE/sizeof(word32)] = {9};
static const word32 kCurve25519BasePoint[CURVE25519_KEYSIZE/sizeof(word32)] = {
#ifdef BIG_ENDIAN_ORDER
0x09000000
#else
9
#endif
};
/* Curve25519 private key must be less than order */
/* These functions clamp private k and check it */