Skip to content

Merkle inputs #8

@coderofstuff

Description

@coderofstuff

With a limited amount of memory in a ledger device, we cannot have more than some small number of inputs. In testing, a Nano S will only allow us to have 14 UTXOS in a transaction.

To support more UTXOs (an arbitrary number, so we're only limited by mass limit), use Merkle Trees.

Reference: https://www.youtube.com/watch?v=n6nEPaE7KZ8

Change in sign_tx APDU:

  1. First APDU will receive the version, output length, input length and merkle root
  2. For {0...input_length}: ask the client to give provide the input along with the merkle proof. Verify the merkle proof to legitimize the input.
  3. Request approval from user to continue with signing
  4. After all inputs are verified this way, For {0..input_length}: ask the client to give provide the input along with the merkle proof. This time, sign them then ask for the next input.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions