Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat/ledger signing #1278

Merged
merged 87 commits into from
May 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
87 commits
Select commit Hold shift + click to select a range
4f8e15b
Exploring how to interact with Ledger from rust code
elizabethengelman Mar 18, 2024
50e5e5f
WIP: get_public_key works, but needs to be cleaned up
elizabethengelman Mar 19, 2024
852114e
Clean up: get_public_key
elizabethengelman Mar 19, 2024
db1c976
Clean up: remove unused tests, etc
elizabethengelman Mar 20, 2024
e24d8a6
WIP: start the speculos emulator via docker
elizabethengelman Mar 22, 2024
0d1c9e7
WIP: start speculos via docker and include some default elf files
elizabethengelman Mar 27, 2024
37b2a24
Allow for stopping the emulator
elizabethengelman Mar 27, 2024
c68c40d
Make get_public_key async
elizabethengelman Mar 28, 2024
1f51f3e
WIP: Allow get_public_key to use Exchange trait to get the transport
elizabethengelman Mar 28, 2024
b74f972
Pass transport into get_public_key_with_display_flag
elizabethengelman Mar 28, 2024
7c1898b
Create a Ledger struct that takes in a generic that implements Exchange
elizabethengelman Mar 28, 2024
d477ce8
Add get_public_key_with_display_flag to Ledger implementation
elizabethengelman Mar 28, 2024
6780f4d
WIP: try to connect ledger struct to emulator transport intead of the…
elizabethengelman Mar 28, 2024
b968fc7
WIP: connected to the emulator
elizabethengelman Mar 28, 2024
614e75b
Add stellarNanoApp.elf
elizabethengelman Apr 1, 2024
404dd46
Cleanup
elizabethengelman Apr 1, 2024
9c36b4c
Add get_app_configuration fn
elizabethengelman Apr 1, 2024
e39d95b
Add sign_transaction_hash fn
elizabethengelman Apr 3, 2024
63bafad
Allow for enabling tx hash signing on the emulator
elizabethengelman Apr 4, 2024
0f96420
WIP - approve the tx on the device
elizabethengelman Apr 4, 2024
d249506
WIP signing a tx
elizabethengelman Apr 8, 2024
691102b
wip sign tx
elizabethengelman Apr 8, 2024
98a0ffa
not sure which is right
elizabethengelman Apr 9, 2024
28f999d
Making progress
elizabethengelman Apr 11, 2024
5f422ef
cleanup
elizabethengelman Apr 11, 2024
b3a1a1c
Up the TransportZemuHttp timeout
elizabethengelman Apr 11, 2024
16ca7a5
Cleanup
elizabethengelman Apr 11, 2024
1ea114f
Update the expected sign_transaction response hex
elizabethengelman Apr 11, 2024
e2b6e0f
Fix tests
elizabethengelman Apr 11, 2024
692e659
Remove unused imports
elizabethengelman Apr 11, 2024
84d2b07
Move app code into lib.rs
elizabethengelman Apr 11, 2024
0d5d159
Make LedgerSigner adhere to Stellar signer trait
elizabethengelman Apr 12, 2024
dcc34ab
Check in Cargo.lock
elizabethengelman Apr 16, 2024
fb9f653
Clippy
elizabethengelman Apr 16, 2024
d8a5dc0
WIP: start to use testcontainers, but it's flakey
elizabethengelman Apr 17, 2024
db06ddc
Getting closer, this isn't as flakey but has some sleeps in there
elizabethengelman Apr 17, 2024
e6cbf77
Use testcontainers for all ledger tests
elizabethengelman Apr 18, 2024
a367a58
Move speculos testcontainer setup to its own file
elizabethengelman Apr 18, 2024
bd51844
Remove docker.rs and emulator.rs to use testcontainers instead
elizabethengelman Apr 18, 2024
0a3fdaf
wip
elizabethengelman Apr 22, 2024
fd402fc
Cleanup
elizabethengelman Apr 22, 2024
396bc1f
Checkin Cargo.lock
elizabethengelman Apr 22, 2024
0b7034e
Merge branch 'main' into feat/ledger-signing
elizabethengelman Apr 22, 2024
8b53aad
Clippy
elizabethengelman Apr 22, 2024
ecfa66a
Merge branch 'main' into feat/ledger-signing
elizabethengelman Apr 22, 2024
868b9d6
Make sure that the ledger's ready text is displayed before continuing…
elizabethengelman Apr 24, 2024
bb6c4ab
Try waiting until the screen has changed before sending another butto…
elizabethengelman Apr 24, 2024
fb773e7
Fix issue with cc 1.0.86 and macos builds and build binaries on all (…
leighmcculloch Apr 23, 2024
11961ae
Cleanup
elizabethengelman Apr 25, 2024
25be1e6
Apply suggestions from code review
elizabethengelman Apr 26, 2024
3fb067f
Address PR feedback
elizabethengelman Apr 29, 2024
bf6a870
Separate emulator-dependent tests
elizabethengelman Apr 29, 2024
a2eaeb6
Merge branch 'main' into feat/ledger-signing
elizabethengelman Apr 29, 2024
1ac9400
Run emulator-dependent tests in a separate workflow
elizabethengelman Apr 29, 2024
8a097af
chore: move feature to mod declaration
willemneal Apr 29, 2024
7829271
Add unit tests to lib that mock out http requests
elizabethengelman Apr 30, 2024
e1631d7
Merge branch 'main' into feat/ledger-signing
elizabethengelman Apr 30, 2024
b44a9b4
Merge branch 'main' into feat/ledger-signing
elizabethengelman May 1, 2024
b5fedfd
Merge branch 'main' into feat/ledger-signing
elizabethengelman May 1, 2024
ba0a75c
Merge branch 'main' into feat/ledger-signing
elizabethengelman May 2, 2024
a5b6f9b
Cleanup
elizabethengelman May 2, 2024
8829da2
Rename TransportZemuHttp -> EmulatorHttpTransport
elizabethengelman May 2, 2024
feec1a0
Update error handling
elizabethengelman May 2, 2024
40d978e
Fix SignatureHint
elizabethengelman May 3, 2024
8026558
Add get_transport fn back in
elizabethengelman May 3, 2024
02f840e
Update one last error
elizabethengelman May 3, 2024
a5eca37
Cleanup imports
elizabethengelman May 7, 2024
876f81a
Merge branch 'main' into feat/ledger-signing
elizabethengelman May 8, 2024
0c3274b
Merge branch 'main' into feat/ledger-signing
elizabethengelman May 8, 2024
1d9a93f
feat: update signer interface in stellar-ledger
willemneal May 7, 2024
a9981eb
feat: add Blob trait and simplify API
willemneal May 8, 2024
64f5493
Merge branch 'main' into feat/ledger-signing
elizabethengelman May 9, 2024
ff91690
Merge branch 'main' into feat/ledger-signing
elizabethengelman May 14, 2024
36cc011
Merge remote-tracking branch 'AhaLabs/feat/ledger-signing' into feat/…
willemneal May 14, 2024
f571eca
fix: fmt
willemneal May 14, 2024
c3f63a1
Apply suggestions from code review
willemneal May 15, 2024
91e83d1
fix: blob to make async_trait happy
willemneal May 15, 2024
69069a0
fix: tests
willemneal May 16, 2024
091beff
fix: pass emulator tests
willemneal May 16, 2024
ec977c9
Merge pull request #23 from AhaLabs/feat/ledger-signer-v1
elizabethengelman May 17, 2024
d4d0d41
Merge branch 'main' into feat/ledger-signing
elizabethengelman May 21, 2024
53774fe
Add to stellar-ledger crate readme
elizabethengelman May 22, 2024
180757b
Cleanup: comments, tests & clippy
elizabethengelman May 22, 2024
8129f16
Merge branch 'main' into feat/ledger-signing
elizabethengelman May 22, 2024
30d15e6
Merge remote-tracking branch 'origin/main' into feat/ledger-signing
willemneal May 27, 2024
0f8586f
Update cmd/crates/stellar-ledger/README.md
willemneal May 27, 2024
66af953
Update cmd/soroban-cli/src/commands/contract/invoke.rs
willemneal May 27, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions .github/workflows/ledger-emulator.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Ledger Emulator Tests

on:
push:
branches: [main, release/**]
pull_request:

defaults:
run:
shell: bash

jobs:
emulator-tests:
runs-on: ubuntu-latest
env:
CI_TESTS: true
steps:
- uses: actions/checkout@v3
- uses: stellar/actions/rust-cache@main
- name: install libudev-dev
run: |
sudo apt install -y libudev-dev
- run: |
cargo test --manifest-path cmd/crates/stellar-ledger/Cargo.toml --features "emulator-tests"
Loading
Loading