Skip to content

Improve tx input review #14

Description

@ImplOfAnImpl

In general, inputs that are commands have to be reviewed by the user before the tx is signed.

The blockchain has several kinds of "input commands":

  • account commands (AccountCommand or OrderAccountCommand); only one of these is allowed per tx;
  • account spendings (AccountSpending), which currently only allow spending from a delegation; any number of these is allowed per tx and they can co-exist with an account command.

Currently, the app assumes that only one "input command" is possible per tx. Worse, it silently overwrites the last stored "input command" when a new one arrives. So

  • At the very least, the app should reject txs with more than one "input command" (this is not a huge deal, because it's unlikely that anyone will create txs like this).
    Addressed by Fixing issues #23
  • Ideally, present all "input commands" for review one by one, same as it's done for outputs.

There are a couple of TODOs related to this, the main one is near TxSummaryCollector::input_command.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions