stellar / stellar-cli

CLI for Stellar developers
70 stars 69 forks source link

Add a --dry-run option to `tx sign` #1486

Open leighmcculloch opened 3 months ago

leighmcculloch commented 3 months ago

Once we add the tx sign command I think we should add a --dry-run option to it that doesn't actually sign or output a tx, but just lists what will and won't be signed.

For example for a simple tx it'll just show the tx being signed.

For a transaction with one or more auths it'd show which auths will be signed and which won't.

This could be really helpful for users of hardware signers or other devices in understanding what they'll be signing without needing to actually go and sign. It could become a good way to understand if the tx is doing something it shouldn't be.

I think we'll have other ways to introspect a tx as well, but this would be focused on auths and the entities to be signed.

Another way of approaching this instead of a --dry-run option would be to make an auths command, such as tx auths that provides capabilities specific to auths.

cc @janewang @willemneal

Ifropc commented 3 months ago

Created task for adding tx auths command #1493