-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
Add pub key proto definitions #6217
Conversation
…nd Fee -> FeeI
👋 Thanks for creating a PR! Before we can merge this PR, please make sure that all the following items have been For contributor use:
For admin use:
Thank you for your contribution to the Cosmos-SDK! 🚀 |
@marbar3778 this is what I have in mind for the basic structure of |
Codecov Report
@@ Coverage Diff @@
## master #6217 +/- ##
=======================================
Coverage 54.84% 54.84%
=======================================
Files 444 444
Lines 26771 26771
=======================================
Hits 14682 14682
Misses 11046 11046
Partials 1043 1043 |
crypto/types/types.proto
Outdated
|
||
// any_pubkey can be used for any pubkey that an app may use which is | ||
// not explicitly defined in the oneof | ||
google.protobuf.Any any_pubkey = 15; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How would this work for an external application? Eg: on Ethermint we use ethereum's secp256k1 implementation:
It'd be nice to have a concrete example to ease the migration
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm thinking there would be two ways to handle this.
One is we don't define the mapping to crypto.PubKey
on this type and instead let that be a parameter for TxDecoder
, i.e. func (types.PublicKey) (crypto.PubKey, error)
.
Or, you could use any_pubkey
which would specify the full URL (ex. ethermint.crypto.PubKeySecp256k1
).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, will work on bringing over the multisig
Co-authored-by: Alexander Bezobchuk <[email protected]>
Co-authored-by: Alexander Bezobchuk <[email protected]>
…aronc/6213-crypto-proto # Conflicts: # crypto/types/types.proto
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
ref: #6213, after #6214
This PR provides basic protobuf definitions for public keys. It does not implement any functionality beyond the protobuf definitions. That's for other PR's.
It also adds a "Public Key Encoding" section to ADR 020 to describe the approach.