kopia lustrzana https://github.com/solokeys/solo1
salty: cast pointer arguments to avoid warnings.
This is a kind of promise that the underlying buffers have the correct size. We know what we are doing. Hopefully ;-)pull/478/head
rodzic
3ee801b76b
commit
471df2a63e
|
@ -370,7 +370,7 @@ void crypto_ed25519_derive_public_key(uint8_t * data, int len, uint8_t * x)
|
||||||
uint8_t seed[salty_SECRETKEY_SEED_LENGTH];
|
uint8_t seed[salty_SECRETKEY_SEED_LENGTH];
|
||||||
|
|
||||||
generate_private_key(data, len, NULL, 0, seed);
|
generate_private_key(data, len, NULL, 0, seed);
|
||||||
salty_public_key(seed, x);
|
salty_public_key(&seed, (uint8_t (*)[salty_PUBLICKEY_SERIALIZED_LENGTH])x);
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
|
@ -430,7 +430,8 @@ void crypto_ed25519_sign(uint8_t * data1, int len1, uint8_t * data2, int len2, u
|
||||||
#if defined(STM32L432xx)
|
#if defined(STM32L432xx)
|
||||||
|
|
||||||
// TODO: check that correct load_key() had been called?
|
// TODO: check that correct load_key() had been called?
|
||||||
salty_sign(_signing_key, data, len, sig);
|
salty_sign((uint8_t (*)[salty_SECRETKEY_SEED_LENGTH])_signing_key, data, len,
|
||||||
|
(uint8_t (*)[salty_SIGNATURE_SERIALIZED_LENGTH])sig);
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
|
|
Ładowanie…
Reference in New Issue