mirror of
https://github.com/trezor/trezor-firmware.git
synced 2024-11-21 23:18:13 +00:00
vendor: update trezor-crypto
This commit is contained in:
parent
965a6e653a
commit
9d5fe82b45
@ -7,7 +7,7 @@
|
||||
|
||||
#include "py/objstr.h"
|
||||
|
||||
#include "trezor-crypto/curve25519-donna/curve25519-donna.h"
|
||||
#include "trezor-crypto/curve25519-donna/curve25519.h"
|
||||
|
||||
#include "rand.h"
|
||||
|
||||
@ -50,7 +50,7 @@ STATIC mp_obj_t mod_TrezorCrypto_Curve25519_publickey(mp_obj_t self, mp_obj_t se
|
||||
}
|
||||
vstr_t vstr;
|
||||
vstr_init_len(&vstr, 32);
|
||||
curve25519_publickey((uint8_t *)vstr.buf, (const uint8_t *)sk.buf);
|
||||
curve25519_donna_basepoint((uint8_t *)vstr.buf, (const uint8_t *)sk.buf);
|
||||
return mp_obj_new_str_from_vstr(&mp_type_bytes, &vstr);
|
||||
}
|
||||
STATIC MP_DEFINE_CONST_FUN_OBJ_2(mod_TrezorCrypto_Curve25519_publickey_obj, mod_TrezorCrypto_Curve25519_publickey);
|
||||
@ -72,7 +72,7 @@ STATIC mp_obj_t mod_TrezorCrypto_Curve25519_multiply(mp_obj_t self, mp_obj_t sec
|
||||
}
|
||||
vstr_t vstr;
|
||||
vstr_init_len(&vstr, 32);
|
||||
curve25519_scalarmult((uint8_t *)vstr.buf, (const uint8_t *)sk.buf, (const uint8_t *)pk.buf);
|
||||
curve25519_donna((uint8_t *)vstr.buf, (const uint8_t *)sk.buf, (const uint8_t *)pk.buf);
|
||||
return mp_obj_new_str_from_vstr(&mp_type_bytes, &vstr);
|
||||
}
|
||||
STATIC MP_DEFINE_CONST_FUN_OBJ_3(mod_TrezorCrypto_Curve25519_multiply_obj, mod_TrezorCrypto_Curve25519_multiply);
|
||||
|
2
vendor/micropython
vendored
2
vendor/micropython
vendored
@ -1 +1 @@
|
||||
Subproject commit 51bcadba1da9157b177b58103ceb072f9df57be7
|
||||
Subproject commit 26553fefd87651e80bf6610f61101977a0d1c5a8
|
2
vendor/trezor-crypto
vendored
2
vendor/trezor-crypto
vendored
@ -1 +1 @@
|
||||
Subproject commit 6d08eb99b8472a2896f73905c00a6405a258750c
|
||||
Subproject commit fa8772dfee59f426fda238553f4613bcb7d30636
|
Loading…
Reference in New Issue
Block a user