-
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
Ledger signing regressions #8109
Comments
I just saw the link in Telegram :) |
The ledger app does require amino JSON. We have not implemented SIGN_MODE_TEXTUAL yet for protobuf so the alternative is proto binary which won't work with the ledger. |
yes, the app uses canonical JSON and has a few restrictions on the structure.. (described here https://github.com/cosmos/ledger-cosmos/blob/master/docs/TXSPEC.md#format). However, there is no direct connection to amino in the formar .. (maybe the field names?) although I understand the naming as this was done at the time amino was used. proto binary would not work because the original design request was that the app had to be generic. So the tx needs to be self-documenting.. if we used protobuf, then we would need to restrict more the structure of the data. This would also affect other cosmos sdk based projects. Due to memory restrictions in Nano S, it is not good to use code generation either.. even nanopb is a problem in Ledger devices. Let me know if you need more info diagnosing why the error message. The easiest is to add this failing tx as a unit test. We can definitely adjust the app if the new format is well defined. |
https://github.com/cosmos/cosmos-sdk/blob/master/client/flags/flags.go#L62 |
Can anyone explain why Zaki's 2nd flow works? afaict |
@tomtau adding |
Amaury wrote a tests and look at the output-document independently here as well. |
Zaki pointed out two bugs:
|
@amaurymartiny , I didn't inspect the ledger signing. How about this:
|
@amaurymartiny I prefer this if we can make it happen. |
@clevinson - don't you think we should print a warning if we change user setting? |
For ledger, it's not possible to sign with sign mode direct, it would only result in an error anyway. Maybe we provide a description in the command? I would think that if we are adding amino-json flag ourselves that it overrides any settings from the user. Also- we already have a flag to let the user decide the sign mode. This is just about us ignoring that flag and always using |
fix is here: #8136 |
Summary of Bug
Version
0.40.0-rc4
in gaiacosmoshub-test-stargate-e
Steps to Reproduce
Sending transactions from keys in the keyring on ledgers fails
This appears to be because the system doesn't have a mechanism to switch to SIGN_MODE_AMINO when a keyring key is ledger based.
This flow works
Also:
--output-document
doesn't appear to work anymore. The signature is still sent toSTDOUT
even when this option is passed.So two issues:
output-document
doesn't work from thetx sign
subcommand.For Admin Use
The text was updated successfully, but these errors were encountered: