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

sandbox: add wrapper functions to prepare templated transaction data #30

Open
pastaghost opened this issue Aug 31, 2022 · 0 comments
Open

Comments

@pastaghost
Copy link
Collaborator

Issue: Certain transaction formats (Cosmos, possibly UTXO, etc) require that prepared transactions contain information from the signer to be signed properly.

In the case of Cosmos transactions, transfer messages require the from_address field to be populated with the signer's address. Delegate messages require the delegator_address field to be populated with the signer's address, etc. Modify the transaction data in CosmosTransactions.ts and substitute the values of each key to be replaced prior to signing with a $VALUE string. Add a wrapper function around the direct adaptercosmoSignTransaction call that first makes a call to cosmosGetAddress then replaces the templated fields in each of the necessary areas per transaction with the correct data. Update AssetCardListConfig and replace the callback for cosmos_signTransaction with this wrapper function.

Investigate whether the same applies to UTXO transactions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant