Skip to content

Commit a78ca5b

Browse files
Merge pull request #351 from LedgerHQ/develop
App release 1.9.20
2 parents 583677e + 3c73234 commit a78ca5b

File tree

779 files changed

+4240
-887
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

779 files changed

+4240
-887
lines changed
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
name: Compilation
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
branches:
7+
- master
8+
pull_request:
9+
branches:
10+
- master
11+
- develop
12+
13+
jobs:
14+
nano_debug_build:
15+
name: Build debug application for NanoS, X and S+
16+
strategy:
17+
matrix:
18+
include:
19+
- SDK: "$NANOS_SDK"
20+
artifact: nanos
21+
- SDK: "$NANOX_SDK"
22+
artifact: nanox
23+
- SDK: "$NANOSP_SDK"
24+
artifact: nanosp
25+
runs-on: ubuntu-latest
26+
container:
27+
image: ghcr.io/ledgerhq/ledger-app-builder/ledger-app-builder:latest
28+
29+
steps:
30+
- name: Clone
31+
uses: actions/checkout@v2
32+
with:
33+
submodules: recursive
34+
35+
- name: Build an altcoin
36+
run: |
37+
make BOLOS_SDK=${{ matrix.SDK }} DEBUG=1 ALLOW_DATA=1 CHAIN=ethereum_classic
38+
mv bin/app.elf ethereum_classic_${{ matrix.artifact }}.elf
39+
40+
- name: Upload altcoin binary
41+
uses: actions/upload-artifact@v2
42+
with:
43+
name: ethereum_classic_${{ matrix.artifact }}
44+
path: ./ethereum_classic_${{ matrix.artifact }}.elf
45+
46+
- name: Build Ethereum
47+
run: |
48+
make clean
49+
make BOLOS_SDK=${{ matrix.SDK }} DEBUG=1 ALLOW_DATA=1
50+
mv bin/app.elf ethereum_${{ matrix.artifact }}.elf
51+
52+
- name: Upload app binary
53+
uses: actions/upload-artifact@v2
54+
with:
55+
name: ethereum_${{ matrix.artifact }}
56+
path: ./ethereum_${{ matrix.artifact }}.elf

.github/workflows/ci-workflow.yml

Lines changed: 81 additions & 85 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Compilation & tests
1+
name: Tests
22

33
on:
44
workflow_dispatch:
@@ -11,79 +11,6 @@ on:
1111
- develop
1212

1313
jobs:
14-
job_build_debug_nano_s:
15-
name: Build debug Nano S
16-
runs-on: ubuntu-latest
17-
18-
container:
19-
image: ghcr.io/ledgerhq/ledger-app-builder/ledger-app-builder:latest
20-
21-
steps:
22-
- name: Clone
23-
uses: actions/checkout@v2
24-
with:
25-
submodules: recursive
26-
27-
- name: Build an altcoin
28-
run: |
29-
make DEBUG=1 ALLOW_DATA=1 CHAIN=ethereum_classic
30-
mv bin/app.elf ethereum_classic_nanos.elf
31-
32-
- name: Upload altcoin binary
33-
uses: actions/upload-artifact@v2
34-
with:
35-
name: ethereum_classic_nanos
36-
path: ./ethereum_classic_nanos.elf
37-
38-
- name: Build Ethereum
39-
run: |
40-
make clean
41-
make DEBUG=1 ALLOW_DATA=1
42-
mv bin/app.elf ethereum_nanos.elf
43-
44-
- name: Upload app binary
45-
uses: actions/upload-artifact@v2
46-
with:
47-
name: ethereum_nanos
48-
path: ./ethereum_nanos.elf
49-
50-
job_build_debug_nano_x:
51-
name: Build debug Nano X
52-
runs-on: ubuntu-latest
53-
54-
container:
55-
image: ghcr.io/ledgerhq/ledger-app-builder/ledger-app-builder:latest
56-
57-
steps:
58-
- name: Clone
59-
uses: actions/checkout@v2
60-
with:
61-
submodules: recursive
62-
63-
- name: Build an altcoin Nano X
64-
run: |
65-
make clean
66-
make BOLOS_SDK=$NANOX_SDK DEBUG=1 ALLOW_DATA=1 CHAIN=ethereum_classic
67-
mv bin/app.elf ethereum_classic_nanox.elf
68-
69-
- name: Upload altcoin binary
70-
uses: actions/upload-artifact@v2
71-
with:
72-
name: ethereum_classic_nanox
73-
path: ./ethereum_classic_nanox.elf
74-
75-
- name: Build Ethereum Nano X
76-
run: |
77-
make clean
78-
make BOLOS_SDK=$NANOX_SDK DEBUG=1 ALLOW_DATA=1
79-
mv bin/app.elf ethereum_nanox.elf
80-
81-
- name: Upload app binary
82-
uses: actions/upload-artifact@v2
83-
with:
84-
name: ethereum_nanox
85-
path: ./ethereum_nanox.elf
86-
8714
scan-build:
8815
name: Clang Static Analyzer
8916
runs-on: ubuntu-latest
@@ -104,8 +31,12 @@ jobs:
10431
name: scan-build
10532
path: scan-build
10633

107-
building_for_e2e_tests:
108-
name: Building binaries for E2E tests
34+
# =====================================================
35+
# ZEMU TESTS
36+
# =====================================================
37+
38+
building_for_e2e_zemu_tests:
39+
name: Building binaries for E2E Zemu tests
10940
runs-on: ubuntu-latest
11041
container:
11142
image: ghcr.io/ledgerhq/ledger-app-builder/ledger-app-builder:latest
@@ -114,17 +45,19 @@ jobs:
11445
- uses: actions/checkout@v2
11546

11647
- name: Build testing binaries
117-
run: cd tests && ./build_local_test_elfs.sh
48+
run: |
49+
git config --global --add safe.directory "$GITHUB_WORKSPACE"
50+
cd tests/zemu/ && ./build_local_test_elfs.sh
11851
11952
- name: Upload app binaries
12053
uses: actions/upload-artifact@v2
12154
with:
12255
name: e2e_elfs
123-
path: ./tests/elfs/
56+
path: ./tests/zemu/elfs/
12457

125-
jobs-e2e-tests:
126-
name: E2E tests
127-
needs: [building_for_e2e_tests]
58+
jobs-e2e-zemu-tests:
59+
name: E2E Zemu tests
60+
needs: [building_for_e2e_zemu_tests]
12861
runs-on: ubuntu-latest
12962
steps:
13063
- name: Test
@@ -146,18 +79,81 @@ jobs:
14679
run: npm install -g yarn
14780

14881
- name: Build/Install build js deps
149-
run: cd tests && yarn install
82+
run: cd tests/zemu/ && yarn install
15083

15184
- name: Create tmp folder for artifacts
152-
run: mkdir tests/elfs
85+
run: mkdir tests/zemu/elfs
15386

15487
- name: Download app binaries
15588
uses: actions/download-artifact@v2
15689
with:
15790
path: tmp/
15891

15992
- name: Gather elfs
160-
run: cp `find tmp/e2e_elfs/ -name "*.elf"` tests/elfs/
93+
run: cp `find tmp/e2e_elfs/ -name "*.elf"` tests/zemu/elfs/
16194

16295
- name: Run zemu tests
163-
run: cd tests && yarn test
96+
run: cd tests/zemu/ && yarn test
97+
98+
# =====================================================
99+
# SPECULOS TESTS
100+
# =====================================================
101+
102+
103+
building_for_e2e_speculos_tests:
104+
name: Building binaries for E2E Speculos tests
105+
runs-on: ubuntu-latest
106+
container:
107+
image: ghcr.io/ledgerhq/ledger-app-builder/ledger-app-builder:latest
108+
109+
steps:
110+
- uses: actions/checkout@v2
111+
112+
- name: Build testing binaries
113+
run: |
114+
mkdir tests/speculos/elfs
115+
make clean && make DEBUG=1 NFT_TESTING_KEY=1 BOLOS_SDK=$NANOS_SDK && mv bin/app.elf tests/speculos/elfs/nanos.elf
116+
make clean && make DEBUG=1 NFT_TESTING_KEY=1 BOLOS_SDK=$NANOX_SDK && mv bin/app.elf tests/speculos/elfs/nanox.elf
117+
make clean && make DEBUG=1 NFT_TESTING_KEY=1 BOLOS_SDK=$NANOSP_SDK && mv bin/app.elf tests/speculos/elfs/nanosp.elf
118+
119+
- name: Upload app binaries
120+
uses: actions/upload-artifact@v2
121+
with:
122+
name: e2e_elfs
123+
path: ./tests/speculos/elfs
124+
125+
126+
jobs-e2e-speculos-tests:
127+
name: Speculos tests
128+
strategy:
129+
matrix:
130+
model: ["nanosp", "nanos", "nanox"]
131+
132+
needs: [building_for_e2e_speculos_tests]
133+
runs-on: ubuntu-latest
134+
135+
steps:
136+
- name: Clone
137+
uses: actions/checkout@v2
138+
139+
- name: Create tmp folder for artifacts
140+
run: mkdir tests/speculos/elfs
141+
142+
- name: Download app binaries
143+
uses: actions/download-artifact@v2
144+
with:
145+
path: tmp/
146+
147+
- name: Gather elfs
148+
run: cp `find tmp/e2e_elfs/ -name "*.elf"` tests/speculos/elfs/
149+
150+
- name: Install dependencies
151+
run: |
152+
cd tests/speculos
153+
sudo apt-get update && sudo apt-get install -y qemu-user-static
154+
pip install --extra-index-url https://test.pypi.org/simple/ -r requirements.txt
155+
156+
- name: Run speculos tests
157+
run: |
158+
cd tests/speculos
159+
pytest --model ${{ matrix.model }} --path ./elfs/${{ matrix.model }}.elf --display headless

.github/workflows/lint-workflow.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@ jobs:
1919
uses: actions/checkout@v2
2020

2121
- name: Lint
22-
uses: DoozyX/clang-format-lint-action@v0.13
22+
uses: DoozyX/clang-format-lint-action@v0.14
2323
with:
2424
source: "./"
2525
extensions: "h,c"
26-
clangFormatVersion: 12.0.0
26+
clangFormatVersion: 12.0.1

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,4 @@ tests/elfs/*
1818
tests/snapshots-tmp
1919

2020
.vscode
21+
.idea

CHANGELOG.md

Lines changed: 25 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,28 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](http://keepachangelog.com/)
66
and this project adheres to [Semantic Versioning](http://semver.org/).
77

8+
## [1.9.20](https://github.com/ledgerhq/app-ethereum/compare/1.9.19...1.9.20) - 2022-10-10
9+
10+
### Added
11+
12+
- (clone) XDCNetwork
13+
- (clone) Meter
14+
- (clone) Multivac
15+
- (clone) Tecra
16+
- (clone) ApothemNetwork
17+
18+
### Changed
19+
20+
- EIP-191 improvements, now lets the user see the entire message one chunk at a time (255 characters for LNX & LNS+, 99 for LNS)
21+
22+
### Fixed
23+
24+
- Allow swap with variants
25+
26+
### Removed
27+
28+
- Compound support (will become its own plugin)
29+
830
## [1.9.19](https://github.com/ledgerhq/app-ethereum/compare/1.9.18...1.9.19) - 2022-06-15
931

1032
### Added
@@ -16,7 +38,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
1638

1739
### Changed
1840

19-
- EIP-191 signatures now show (up to 99 characters on LNS and 255 on LNX & LNS) the actual data contained in the message (clear-signing)
41+
- EIP-191 signatures now show (up to 99 characters on LNS and 255 on LNX & LNS+) the actual data contained in the message (clear-signing)
2042

2143
### Fixed
2244

@@ -64,7 +86,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
6486

6587
### Fixed
6688

67-
- Fixed stark order signature on LNS
89+
- Fixed stark order signature on LNS
6890

6991
## [1.9.13](https://github.com/ledgerhq/app-ethereum/compare/1.9.12...1.9.13) - 2021-11-17
7092

@@ -76,7 +98,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
7698

7799
### Fixed
78100

79-
- Fixed stark order signature on LNX
101+
- Fixed stark order signature on LNX
80102

81103
## [1.9.11](https://github.com/ledgerhq/app-ethereum/compare/1.9.10...1.9.11) - 2021-10-12
82104

Makefile

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,9 @@ APP_LOAD_PARAMS += --path "1517992542'/1101353413'"
3434

3535
APPVERSION_M=1
3636
APPVERSION_N=9
37-
APPVERSION_P=19
37+
APPVERSION_P=20
3838
APPVERSION=$(APPVERSION_M).$(APPVERSION_N).$(APPVERSION_P)
39-
APP_LOAD_FLAGS= --appFlags 0x240 --dep Ethereum:$(APPVERSION)
39+
APP_LOAD_FLAGS= --appFlags 0xa40 --dep Ethereum:$(APPVERSION)
4040

4141
###########################
4242
# Set Chain environnement #
@@ -194,6 +194,7 @@ SDK_SOURCE_PATH += lib_ux
194194
ifeq ($(TARGET_NAME),TARGET_NANOX)
195195
SDK_SOURCE_PATH += lib_blewbxx lib_blewbxx_impl
196196
endif
197+
APP_SOURCE_PATH += src_bagl
197198

198199
### initialize plugin SDK submodule if needed, rebuild it, and warn if a difference is noticed
199200
ifeq ($(CHAIN),ethereum)
@@ -222,13 +223,16 @@ delete:
222223
python3 -m ledgerblue.deleteApp $(COMMON_DELETE_PARAMS)
223224

224225
install_tests:
225-
cd tests && (yarn install || sudo yarn install)
226+
cd tests/zemu/ && (yarn install || sudo yarn install)
226227

227228
run_tests:
228-
cd tests && (yarn test || sudo yarn test)
229+
cd tests/zemu/ && (yarn test || sudo yarn test)
229230

230231
test: install_tests run_tests
231232

233+
unit-test:
234+
make -C tests/unit
235+
232236
# import generic rules from the sdk
233237
include $(BOLOS_SDK)/Makefile.rules
234238

doc/ethapp.asc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,8 @@ The address can be optionally checked on the device before being returned.
9494

9595
#### Description
9696

97+
https://github.com/ethereum/EIPs/blob/master/EIPS/eip-1559.md
98+
9799
This command signs an Ethereum transaction after having the user validate the following parameters
98100

99101
- Gas price

icons/nanos_app_apothemnetwork.gif

67 Bytes
Loading

icons/nanos_app_meter.gif

84 Bytes
Loading

icons/nanos_app_multivac.gif

75 Bytes
Loading

0 commit comments

Comments
 (0)