1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-10-19 06:19:27 +00:00
Commit Graph

75 Commits

Author SHA1 Message Date
matejcik
f6f52445bd feat(core/cardano): support Icarus, Icarus-Trezor, and Ledger derivations 2021-11-10 13:57:57 +01:00
matejcik
387466e073 refactor(core): separate Cardano cryptography into its own module 2021-11-10 13:57:57 +01:00
Ondřej Vejpustek
29ce860d46 refactor(core,crypto): rename schnorr to BIP340 2021-10-25 14:41:28 +02:00
Ondřej Vejpustek
7ac0bdd215 feat(core): make core use Schnorr signatures 2021-10-25 14:41:28 +02:00
Ondřej Vejpustek
26463eb3ce feat(core): make core use ecdsa from secp256k1_zkp wherever possible 2021-10-25 14:41:28 +02:00
Jan Pochyla
2703d714c2 feat(core): add Rust UI components, layouts, text rendering
[no changelog]
2021-10-07 15:01:55 +02:00
Martin Milata
bd005e33df refactor(core): decouple T1 button handling from touch
[no changelog]
2021-09-23 12:30:13 +02:00
matejcik
b41d4c71f0 feat(core/emulator): JSON memory map dump
use `trezor.utils.mem_dump("somefile.json")` in a key place, then
`analyze.py src/somefile.json` to look at what is going on
2021-07-14 13:50:24 +02:00
Jan Pochyla
8a21e3fc73 feat(core): Add Rust Protobuf codec 2021-06-08 09:55:19 +02:00
Pavol Rusnak
23aa69caea fix(core): unify Features.revision reporting with legacy 2021-06-04 12:50:49 +02:00
matejcik
391976bcda refactor(core/usb): do not require serial number on instantiaton of USB
On a cleanly wiped device, storage must be unlocked in order to create
and retrieve the serial number. However, storage unlocking happens in
boot.py, which is imported _after_ usb.py

We must therefore sidestep asking for the serial number.
2021-05-06 13:14:21 +02:00
Martin Milata
ac711fb8ee style(core): use more recent type annotation syntax
https://www.python.org/dev/peps/pep-0585/ - Type Hinting Generics In Standard Collections
https://www.python.org/dev/peps/pep-0604/ - Allow writing union types as X | Y
2021-04-01 11:12:30 +02:00
Martin Milata
8b3ac659a0 style(core): mypy: disable implicit Optional for function arguments
https://www.python.org/dev/peps/pep-0484/#union-types
2021-04-01 11:12:30 +02:00
Andrew Kozlik
2836bfc64c fix(core): Improve error handling and range checking in modtrezorconfig. 2021-03-26 10:54:56 +01:00
Andrew Kozlik
3084d1196d feat(core): Support 50 digit PIN and wipe code. 2021-03-25 14:24:41 +01:00
Andrew Kozlik
a8c500bffd feat(core): Ensure that WebAuthn runs on port 21326 by default for both production and debug emulator. 2021-03-09 16:13:21 +01:00
matejcik
ccd241fe55 feat(core/cardano): enable typing for Cardano app 2021-02-10 10:56:52 +01:00
Martin Milata
db5b65a420 perf(core): enable rendering of substrings to avoid slicing 2021-01-11 16:47:59 +01:00
Andrew Kozlik
aeb021b159 chore(core): Improve naming of SLIP39's T9 mask lookup. 2020-12-15 13:41:42 +01:00
Pavol Rusnak
d8534b5ee6
perf(core/extmod): replace HMAC Python implementation with C
We keep Python implementation of HMAC for Monero in
core/src/apps/monero/xmr/crypto/__init__.py
2020-10-12 16:33:13 +02:00
matejcik
7e5d9e295b fix(core): help mypy understand micropython's module management 2020-09-23 16:00:10 +02:00
Martin Milata
b8bb63fbef core: drop unused FONT_SIZE constant 2020-09-01 19:57:46 +02:00
Martin Milata
1b982659c4
core: fix boot loop after uploading invalid homescreen (#1205) 2020-08-21 12:00:42 +02:00
Pavol Rusnak
4e11735d22 core/modtrezorui: remove prefill from text functions
use display.bar where needed to prefill the areas
2020-08-07 15:08:14 +02:00
Pavol Rusnak
cec87bba50
core: remove mono bold font variant (not used anywhere) 2020-07-27 23:22:34 +02:00
matejcik
fa757f4b7f core: improve type annotation for bip32.derive_path 2020-07-24 16:37:58 +02:00
matejcik
0c3bc53aee core: clean up types for field caching, fix count_message 2020-07-24 14:09:31 +02:00
matejcik
85d74ece76 core: implement synchronous v1 codec 2020-07-24 14:09:31 +02:00
matejcik
872e0fb0e0 core: lower scheduler resolution to milliseconds
This avoids problems with large timeouts causing the scheduler queue to
think the time counter has overflown, and ordering the autolock task before
immediate tasks.

The maximum reasonable time difference is 0x20000000, which in
microseconds is ~8 minutes, but in milliseconds a more reasonable ~6
days.
2020-06-04 16:18:46 +02:00
matejcik
837c4df61f core: expose storage_is_unlocked() as config.is_unlocked() 2020-06-04 16:18:46 +02:00
matejcik
87433995b0 core: add BITCOIN_ONLY to mock file 2020-06-04 16:18:46 +02:00
matejcik
aa52fc3903 core/extmod: drop unused rfc6979 module 2020-05-18 14:31:00 +02:00
matejcik
7f2e7b0003 core: add Ethereum constants to mocks 2020-05-15 14:08:29 +02:00
Pavol Rusnak
a7806d08d7
core/crypto: remove unused bip32.deserialize function 2020-04-06 18:04:24 +02:00
Pavol Rusnak
1695228d80
core/crypto: remove unused serialize_private function 2020-04-06 15:49:36 +00:00
Pavol Rusnak
f07ff17fad
core/crypto: add missing field to Blake2b constructor 2020-04-06 12:28:36 +00:00
matejcik
3789a3372b core/sdcard: modify exception handling in fatfs
expose ff.c constants, raise them as arguments to FatFSError

introduce NotMounted and NoFilesystem as subclasses of FatFSError with
the appropriate error code set
2020-03-20 14:03:28 +01:00
Andrew Kozlik
bfd834d1de storage: Add storage_ensure_not_wipe_code(). 2020-03-19 15:04:33 +01:00
Dusan Klinec
2658e253fa xmr/bp: memory optimizations and improvements
- different approach to vector manipulation - more on the fly operations. Prepared for fully offloaded operations, BP on Trezor with constant memory.
- memory requirements reduced from (4MN + const) to (2MN + const)
- more raw methods to avoid unnecessary encoding/decoding
- chunking improved, chunk size set as a constant, changed from 64 to 32, missing pieces implemented to cover also BP 16
- proof_v8 support discontinued, old hardfork, not needed anymore
- get_exponent register clash fixed (for large vectors)
- reduced heap fragmentation by removing some temporary allocations
- hashing with len and offset to reduce heap fragmentation by creating a sliced arrays
- use to() wherever possible to avoid allocations and return of mutable private object
- global functions start with _ prefix, reduce import footprint
- use __slots__ in classes to minimize footprint
2020-03-02 12:17:03 +01:00
matejcik
9ab84d2455 core/tests: thoroughly test modified APIs 2020-02-27 10:56:23 +01:00
matejcik
fa746e2990 core/fatfs: rework low-level FatFS API
Instead of having possibly multiple FatFS objects, each with its own
`fs` struct, there is one global static fs_instance. This is to match
the mode of operation of ff.c, which assumes a global list of mounts,
and all functions operate on the global based on path.

Methods of FatFS were converted to functions on the fatfs module.

fatfs.unmount() does not call ff.c's unmount, but simply invalidates
fs_instance. This is basically what ff.c would do, except without
messing with ff.c's global list of mounts.
2020-02-26 14:18:41 +01:00
Pavol Rusnak
39ce100608
Merge pull request #864 from trezor/prusnak/bootloader-text-break
core/bootloader: split long vendor string
2020-02-21 18:39:20 +01:00
matejcik
b2084a19be core/trezorio: move sdcard functions to a submodule 2020-02-20 12:51:48 +01:00
Pavol Rusnak
74802a107e
core/modtrezorui: add display_text_split 2020-02-19 21:40:28 +00:00
Pavol Rusnak
32f8f1cb61
core/embed: update fatfs to 0.14; use upstream version 2020-02-07 15:21:16 +00:00
Pavol Rusnak
3de1b3aa54
core/embed: switch to unprivileged in main.c 2020-01-24 12:29:46 +00:00
Tomas Susanka
51ef963738 tests: introduce UI tests for core 2020-01-03 14:28:27 +00:00
Andrew Kozlik
a3b608d8dd storage, core: Reveal the wipe code status after the device is unlocked. 2019-11-25 12:32:20 +01:00
Andrew Kozlik
a168d661cf core: Add support for ChangeWipeCode message. 2019-11-25 12:32:20 +01:00
Tomas Susanka
0511cc8b8c core: add final mypy fixes! 2019-10-22 14:36:25 +00:00