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

feat(gnokey): update gnokey verify and tests #2333

Open
wants to merge 14 commits into
base: master
Choose a base branch
from

Conversation

thinhnx-var
Copy link
Contributor

Contributors' checklist...
  • Added new tests, or not needed, or not feasible
  • Provided an example (e.g. screenshot) to aid review or the PR is self-explanatory
  • Updated the official documentation or not needed
  • No breaking changes were made, or a BREAKING CHANGE: xxx message was included in the description
  • Added references to related issues and PRs
  • Provided any useful hints for running manual tests
  • Added new benchmarks to generated graphs, if any. More info here.

Link to this issue: #2311
This PR changes the Verify() to read the signed doc, verify the exactly original message hash that was signed.
It also adds chainid, account-number, account-sequence config flag to the gnokey verify command.

The sign function now expose the hex-format of signature to the IO in oder to feed the verify as an argument. I think we need better way for user to verify their signed document, which currently need this hex-format (#2272)

What do you think about this change?

@thinhnx-var thinhnx-var requested review from jaekwon and a team as code owners June 12, 2024 04:42
@github-actions github-actions bot added the 📦 🌐 tendermint v2 Issues or PRs tm2 related label Jun 12, 2024
Copy link

codecov bot commented Jun 12, 2024

Codecov Report

Attention: Patch coverage is 85.18519% with 4 lines in your changes missing coverage. Please review.

Project coverage is 60.99%. Comparing base (f04ec89) to head (9166f69).
Report is 53 commits behind head on master.

Files with missing lines Patch % Lines
tm2/pkg/crypto/keys/client/verify.go 84.61% 2 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2333      +/-   ##
==========================================
+ Coverage   60.44%   60.99%   +0.55%     
==========================================
  Files         563      564       +1     
  Lines       75159    76006     +847     
==========================================
+ Hits        45427    46358     +931     
+ Misses      26343    26217     -126     
- Partials     3389     3431      +42     
Flag Coverage Δ
contribs/gnodev 61.46% <ø> (ø)
contribs/gnofaucet 15.31% <ø> (ø)
gno.land 67.92% <ø> (+0.70%) ⬆️
gnovm 65.77% <ø> (+1.30%) ⬆️
misc/genstd 80.54% <ø> (ø)
misc/logos 20.23% <ø> (+0.35%) ⬆️
tm2 62.07% <85.18%> (+0.02%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@leohhhn
Copy link
Contributor

leohhhn commented Jun 12, 2024

Hey @thinhnx-var thanks for this - can you please check why the CI is failing and fix it?

@thinhnx-var thinhnx-var changed the title [gnokey] update gnokey verify and tests feat(gnokey): update gnokey verify and tests Jun 12, 2024
@thinhnx-var
Copy link
Contributor Author

@leohhhn yeah sure. Maybe CI failed because CI-Lint. I gonna fix it up.

@thinhnx-var
Copy link
Contributor Author

@leohhhn
Can you please review this. I ( and I think others) have problems when using current version of gno sign so I think it should be good to merge this.

@leohhhn
Copy link
Contributor

leohhhn commented Sep 11, 2024

Hey! I will take a look. Please stop clicking "merge master". This is annoying and spammy, and will not get your PR reviewed faster. You should only merge in master if there are conflicts to be resolved.

@Kouteki Kouteki added the review/triage-pending PRs opened by external contributors that are waiting for the 1st review label Oct 3, 2024
@jefft0 jefft0 removed the review/triage-pending PRs opened by external contributors that are waiting for the 1st review label Oct 4, 2024
@jefft0
Copy link
Contributor

jefft0 commented Oct 4, 2024

Removed the "review team" label because this is already reviewed by leohhhn.

Co-authored-by: Jeff Thompson <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📦 🌐 tendermint v2 Issues or PRs tm2 related
Projects
Status: No status
Status: In Review
Development

Successfully merging this pull request may close these issues.

4 participants