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

Allow client-side signing with SIGN_MODE_TEXTUAL #13747

Closed
1 task
amaury1093 opened this issue Nov 3, 2022 · 0 comments · Fixed by #14661
Closed
1 task

Allow client-side signing with SIGN_MODE_TEXTUAL #13747

amaury1093 opened this issue Nov 3, 2022 · 0 comments · Fixed by #14661
Assignees

Comments

@amaury1093
Copy link
Contributor

amaury1093 commented Nov 3, 2022

Summary

part of #11970

Allow golang clients to be able to generate and sign Txs with SIGN_MODE_TEXTUAL.

Problem Definition

In #13700 we added a SignModeHandler, which means we're able to call GetSignBytes with Textual using our client Tx infrastructure (TxConfig, TxBuilder...).

However, Textual signing is not stateless, and generating the sign doc needs access to latest state (for coin metadata). This issue is about how a client-side Textual can access to state.

For this, we proposed in #13646 to add a context.Context arg to some of the signing functions. Most notably, on the client side, both Sign and SignWithPrivKey take a new context.Context arg.

Proposal

  • When passing a Textual instance to the client.Context's TxConfig, we should make so that Textual's coinMetadataQuerier instantiates a bank query client using the grpc.ClientConn, and retrieves the coin metadata via a remote gRPC query.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant