1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-11-15 20:19:23 +00:00
Commit Graph

94 Commits

Author SHA1 Message Date
Ondřej Vejpustek
aca37e5eb2 refactor(crypto): make helper function for ecdsa_recover_pub_from_sig and
ecdsa_verify_digest
2021-10-25 14:41:28 +02:00
Ondřej Vejpustek
3cd2e89fbc refactor(crypto): split test_ecdsa_signature into two tests 2021-10-25 14:41:28 +02:00
Pavol Rusnak
d34b1636ee feat(crypto): add BIP-350 test cases to test_check_segwit 2021-10-18 13:36:05 +02:00
Pavol Rusnak
86ea94d06b fix(crypto): remove 3 BIP-173 test cases from segwit_addr
because they encode segwit program > 0 and these should no longer
be encoded with Bech32 but rather with Bech32m
2021-10-18 13:36:05 +02:00
Pavol Rusnak
60bd59fbad feat(crypto): update segwit_addr to support Bech32m 2021-10-18 13:36:05 +02:00
Andrew Kozlik
c1843f9f9f style(legacy): Remove nested conditional operators. 2021-07-22 10:54:49 +02:00
Pavol Rusnak
f740515c85 fix(core,crypto): add more test cases from bip-173 2021-07-21 11:20:11 +02:00
Andrew Kozlik
ce18f4bc8a test(crypto): Add progressive tests for hash functions. 2021-06-11 20:22:42 +02:00
Adam R
c4bf522b31
feat(crypto): add extra BIP32 test (test vector #4) (#1646) 2021-06-03 15:37:23 +02:00
Ondřej Vejpustek
e1a5f42c81 feat(core): make chacha_drbg more robust 2021-05-21 13:42:53 +02:00
Pavol Rusnak
b04d5bd514 fix(crypto): use ck_assert_uint_eq where we compare unsigned values 2021-05-13 14:13:56 +02:00
Fabien
9ef26c347e Add support for Schnorr crypto (BCH variant)
Support Schnorr signature and verification defined in
https://github.com/bitcoincashorg/bitcoincash.org/blob/master/spec/2019-05-15-schnorr.md.

The implementation is based on https://github.com/Bitcoin-ABC/secp256k1
as well as the test vectors.
2021-03-09 14:22:56 +01:00
Pavol Rusnak
93215ae3c7 style: reformat with clang-format 11 2021-01-04 14:40:16 +01:00
Rafael Korbas
edf9b4ee85 Refactor mnemonic_to_entropy to not (misleadingly) return checksum 2020-12-19 20:17:16 +01:00
Andrew Kozlik
b90ce7f2fc test(crypto): Add unit tests for ecdsa_sig_from_der(). 2020-12-17 16:33:33 +01:00
Andrew Kozlik
acf7294ca2 test(crypto): Add more unit tests for invalid T9 prefix in SLIP39 word lookup. 2020-12-15 13:41:42 +01:00
Andrew Kozlik
55f3df6b0c chore(crypto): Rework SLIP-39 word lookup. 2020-12-15 13:41:42 +01:00
Andrew Kozlik
e3afd984ae test(crypto): Add SLIP39 word completion test. 2020-12-15 13:41:42 +01:00
Andrew Kozlik
7fc1851279 fix(crypto): Improve naming and robustness of SLIP39's T9 mask lookup. 2020-12-15 13:41:42 +01:00
Andrew Kozlik
dab353f888 test(crypto): Test signature verification for a digest which is equal to the group order. 2020-12-02 17:11:29 +01:00
Andrew Kozlik
c67ecb984b chore(crypto): Move XPUB_MAXLEN and ADDRESS_MAXLEN from modtrezorcrypto to bip32.h. 2020-10-13 13:13:49 +02:00
Ondřej Vejpustek
015c294857 crypto/tests: parametrize test_bn_format 2020-06-26 12:29:21 +02:00
Ondřej Vejpustek
24ceb0ab6b crypto/bignum: change limb size to 29, add tests 2020-05-24 14:36:38 +00:00
Ondřej Vejpustek
4504469e80 crypto: add tests for chacha_drbg 2020-04-16 11:51:28 +02:00
Pavol Rusnak
ff706eb70b
crypto: split hdnode_deserialize into hdnode_deserialize_{public,private} 2020-04-06 16:28:02 +00:00
Pavol Rusnak
78041d261b
crypto: refactor bip39 api 2019-09-23 17:56:36 +02:00
Andrew Kozlik
217c910b4b cardano: Implement SLIP-0023 and add SLIP-0039 support for Cardano. 2019-07-25 19:43:05 +02:00
Tomas Susanka
49d6a35249 core: add slip39 keyboard 2019-06-23 21:33:58 +02:00
Andrew Kozlik
013929de0b crypto/hmac_drbg: Fix buffer overflow. 2019-06-11 11:41:40 +02:00
Andrew Kozlik
d95756ccf3 crypto/hmac_drbg: Fix style. 2019-06-11 11:41:40 +02:00
Andrew Kozlik
b915092a44 crypto/hmac_drbg: Add nonce parameter to hmac_drbg_init(). 2019-06-11 11:41:40 +02:00
Andrew Kozlik
7c44340c40 crypto: Add HMAC deterministic random bit generator and unit tests. 2019-06-11 11:41:40 +02:00
Pavol Rusnak
cc2acb2e67
Revert "crypto: add support for schnorr signatures"
This reverts commit 8114e0f9fc.
2019-05-23 20:15:30 +02:00
Andrew Kozlik
223868f552 crypto/shamir: Fix edge case when shamir_interpolate() is called with duplicate share indices which are equal to the result index. 2019-05-02 18:44:56 +02:00
Andrew Kozlik
e631983d6d Merge remote-tracking branch 'origin/master' into andrewkozlik/slip0039 2019-04-29 11:29:54 +02:00
Tomas Susanka
456d98ac03 all: style 2019-04-23 14:41:59 +02:00
armatusmiles
8114e0f9fc
crypto: add support for schnorr signatures 2019-04-22 00:52:50 +02:00
Tomas Susanka
1995169255 crypto: style 2019-04-19 16:36:39 +02:00
Pavol Rusnak
8b06598474
core+legacy: rework code styling checks 2019-04-18 17:40:55 +02:00
Andrew Kozlik
1ee831f50c Merge remote-tracking branch 'origin/master' into andrewkozlik/slip0039 2019-04-18 14:59:05 +02:00
Andrew Kozlik
c073d68a2d crypto/shamir: Improve error handling. 2019-04-18 14:35:18 +02:00
Andrew Kozlik
1b3c0e0243 crypto/tests: Add unit tests for Shamir secret sharing. 2019-04-17 17:28:34 +02:00
Kurotych Anatolii
23bfb31ad2 crypto/ecdsa: add compress_coords (#42) 2019-04-17 12:19:01 +02:00
matejcik
4e0d813269 MONOREPO MERGE trezor-crypto 2019-04-15 19:14:52 +02:00