Skip to content

Commit

Permalink
feat!: ledger metadata signature with receiver adress confirmation (#…
Browse files Browse the repository at this point in the history
…6462)

Description
---
Send the user spend public key to the ledger for script generation and
user validation via the ledger device.

Motivation and Context
---
Initially we though we would need to send all the parts to the ledger,
instead we will change the format by hashing the script, and hashing all
other fields, then hashing those hashes.
This allows us to hash the other fields, and send just the hash to the
ledger instead of serializing all the independent parts (covenants,
encrypted data, etc.) As they have variable lengths and it gets messy
quick.

Then we can send just the receiver public spend key to the ledger, and
use it to generate the entire TariScript for the message, after the user
has verified the address on the ledger screen.

How Has This Been Tested?
---

What process can a PR reviewer use to test or verify this change?
---

<!-- Checklist -->
<!-- 1. Is the title of your PR in the form that would make nice release
notes? The title, excluding the conventional commit
tag, will be included exactly as is in the CHANGELOG, so please think
about it carefully. -->


Breaking Changes
---

- [ ] None
- [ ] Requires data directory on base node to be deleted
- [ ] Requires hard fork
- [X] Other - Please specify

<!-- Does this include a breaking change? If so, include this line as a
footer -->
<!-- Metadata signature change required a new genesis block

---------

Co-authored-by: Hansie Odendaal <[email protected]>
  • Loading branch information
brianp and hansieodendaal authored Aug 12, 2024
1 parent 310a470 commit 84e7c0a
Show file tree
Hide file tree
Showing 20 changed files with 701 additions and 337 deletions.
91 changes: 48 additions & 43 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions applications/minotari_ledger_wallet/common/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,5 @@ license = "BSD-3-Clause"
edition = "2021"

[dependencies]
tari_utilities = { version = "0.7", default-features = false }
bs58 = { version = "0.5.1", default-features = false, features = ["alloc"] }
Loading

0 comments on commit 84e7c0a

Please sign in to comment.