Commit Graph

325 Commits

Author SHA1 Message Date
Francois Beutin
60d1d97667 Return to Exchange when failing to sign in swap mode 2023-12-01 19:50:07 +01:00
Alexandre Paillier
edad008ed1 Fix signature generation for SET_EXTERNAL_PLUGIN in client 2023-11-30 10:55:44 +01:00
Francois Beutin
84d0ce2b80 Misc modifications from previous review 2023-11-17 15:32:54 +01:00
apaillier-ledger
5d913f3a15 Merge pull request #449 from LedgerHQ/tdj/eth_plugin_sdk_update
Update plugins SDK framework
2023-10-19 11:26:32 +02:00
Alexandre Paillier
49da32af8e Added missing return value checks following recent changes 2023-10-10 16:42:24 +02:00
tdejoigny-ledger
eeb52344df ETH plugin SDK : Move some parts from plugin boilerplate to Eth plugin SDK to ease the plugins development, remove throw and fix the CI issues 2023-10-10 16:42:19 +02:00
Alexandre Paillier
015842d4e5 Simplified adding new clones
Removed dead code from the app (was safeguarded by #ifdefs of macros
that weren't defined)
2023-10-04 18:06:52 +02:00
Francois Beutin
ad2786efe0 Add a PRINTF of amounts in ERR_SILENT_MODE_CHECK_FAILED 2023-10-04 14:51:40 +02:00
Alexandre Paillier
60b73eeab1 New NFT metadata test key 2023-09-07 16:08:03 +02:00
Alexandre Paillier
684e19b06f New SET_PLUGIN test key 2023-09-07 16:08:03 +02:00
Alexandre Paillier
72c19e0222 Renamed NFT_TEST_KEY to NFT_STAGING_KEY 2023-09-07 16:08:02 +02:00
Alexandre Paillier
7efb861804 Removed chain ID restrictions from SET_PLUGIN and PROVIDE_NFT_INFORMATION apdus 2023-09-07 16:08:01 +02:00
Alexandre Paillier
b05b16143d Now shows the network name in the Stax public address UI flow 2023-09-07 14:35:55 +02:00
Alexandre Paillier
a903e2db6e Implemented the optional chain ID in the GET_ETH_PUBLIC_ADDRESS apdu 2023-09-07 14:35:47 +02:00
Jorge Martins
0bc9ea00ac TLV: raise error when length = 0 2023-07-27 10:45:06 +02:00
Alexandre Paillier
17968338d8 Removed EIP712 verbose display of inner struct names 2023-07-18 17:00:35 +02:00
Alexandre Paillier
af8123ad45 Fix improper handling of empty arrays in EIP712 messages 2023-07-18 17:00:35 +02:00
Alexandre Paillier
6a04c14df0 Add back the call to ui_idle in case of EIP712 failure
Was removed during the Stax porting
2023-07-18 17:00:30 +02:00
Alexandre Paillier
61015e3840 NBGL message signing refactoring 2023-07-18 11:35:26 +02:00
Alexandre Paillier
c8360741a4 Activated ENS on other Ethereum-compatible chains 2023-07-06 14:45:31 +02:00
Alexandre Paillier
34ea137c1a network.c functions cleanup 2023-07-06 14:45:29 +02:00
Francois Beutin
8082bd7f8b Return in Exchange after a successful swap 2023-07-04 12:24:20 +02:00
Francois Beutin
02cdc23751 Rename called_from_swap to G_called_from_swap 2023-06-30 14:05:46 +02:00
Benjyskan
25ace8ab6a clean dataContext.tokenContext.data buffer between each plugin call to avoid unwanted data in last parameter when it isn't full length. (#434) 2023-05-31 18:33:12 +02:00
Alexandre Paillier
8881471a8e EIP-712 fixes
- Now displays a Review page before showing the fields
- Now asks for confirmation before rejecting
- Now does not refresh the screen twice after a signature approval/rejection
- Both EIP-712 implementations on par UX-wise
- Fixed v0 approve/reject status word mismatch
- Unified NBGL UI of both implementations
2023-05-16 11:42:30 +02:00
Alexandre Paillier
b5c58b59cf network: cleanup 2023-05-16 11:42:29 +02:00
Francois Beutin
3fa410fb24 Add log for exception 2023-04-24 11:30:14 +02:00
Alexandre Paillier
1edd8c528a Review 2023-04-24 11:30:04 +02:00
Alexandre Paillier
d128b0c9cb Workaround strncasecmp segfault 2023-04-24 11:28:42 +02:00
Alexandre Paillier
504747aba2 Improve finalizeParsing() checking in swap context
Simplify code in logic_signTx.c
2023-04-24 11:27:13 +02:00
Alexandre Paillier
fbe062a861 Extra security checks on domain name when parsing it 2023-04-20 10:12:41 +02:00
Alexandre Paillier
ceacee00a7 Provide domain name APDU implementation 2023-03-29 18:09:42 +02:00
Alexandre Paillier
e15899c92e Moved hash_byte & hash_nbytes functions to common
Also fixed possible overflow on large payload hashing
2023-03-29 17:53:29 +02:00
Alexandre Paillier
f17104312b Challenge implementation 2023-03-29 15:16:23 +02:00
Alexandre Paillier
27392c20de Better context checks when processing EIP-191 APDUs 2023-02-09 11:44:21 +01:00
Alexandre Paillier
74f880dce9 Removes useless space at the end of tickers 2023-01-10 14:12:39 +01:00
Alexandre Paillier
fb1e1b2f78 EIP712 verbose mode "Struct review" visual glitch fix 2022-11-18 15:07:08 +01:00
Clement Bouvet
800116ee9d cmd_signMessage712.c: use common ui 2022-11-10 13:33:59 +01:00
Alexandre Paillier
174d35782f Review fixes 2022-10-26 14:54:10 +02:00
Alexandre Paillier
c158c3e502 Better split between business logic & UI code for EIP-712 2022-10-24 10:18:51 +02:00
Alexandre Paillier
109dffc70e Better context check for EIP712 sign
It was possible to define empty structs without any fields and right after, trigger the EIP712 sign UI flow for blank domain & message hashes.
Added checks if there is actually anything relevant to sign.
2022-10-18 11:51:39 +02:00
Jorge Martins
0b288cd924 Eip712 review (#355)
* Possible security fix.

It is possible to send a new structure definition after sending a structure implementation, which makes the app treat unrestricted data as if it was a well defined structure.
This commit tries to fix that behaviour. Once a structure implementation is sent, we consider all structures to be defined and we do not allow new definitions.

* Fix previous commit
2022-10-18 11:09:00 +02:00
Alexandre Paillier
c803322f3c Review fixes 2022-10-17 11:57:16 +02:00
Alexandre Paillier
d297a66951 Enforce proper memory alignment on APDU buffer for response status words 2022-10-17 11:57:16 +02:00
Alexandre Paillier
2474bdb81a Merge remote-tracking branch 'origin/develop' into HEAD 2022-10-17 11:44:28 +02:00
Alexandre Paillier
f43d9c4dc7 Fix EIP-191 UI split 2022-10-06 15:11:30 +02:00
Alexandre Paillier
e9ecf2e109 Activate full EIP-191 implementation on LNS + with adequate wording 2022-10-04 13:59:50 +02:00
Lucas PASCAL
3f294f9582 Minor fixes after review 2022-09-16 14:43:51 +02:00
Alexandre Paillier
ba34e37bce Downgrade to make the app fit on LNS 2022-09-15 16:49:20 +02:00
Alexandre Paillier
50dd4f5965 Linting + updated to clang-format 12.0.1 2022-09-15 16:49:19 +02:00