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

Early sapling balance check #3439

Merged
merged 40 commits into from
Jul 5, 2024
Merged

Conversation

grarco
Copy link
Contributor

@grarco grarco commented Jun 25, 2024

Describe your changes

Closes #2721.

Moves the check on the sapling value balance slightly up in the masp vp to reject invalid transactions earlier.

Indicate on which release or other PRs this topic is based on

#3393 (diffs for review: https://github.com/anoma/namada/pull/3439/files/13b4bcd098d0288c11c90088c6a7b106818f76a8..a3bb632a1f40700abae9027a80cc9fcd88725f70)

Checklist before merging to draft

  • I have added a changelog
  • Git history is in acceptable state

Copy link

codecov bot commented Jun 25, 2024

Codecov Report

Attention: Patch coverage is 26.50288% with 1406 lines in your changes missing coverage. Please review.

Project coverage is 53.51%. Comparing base (879a326) to head (a3bb632).
Report is 4 commits behind head on main.

Files Patch % Lines
crates/sdk/src/masp.rs 0.00% 572 Missing ⚠️
crates/sdk/src/tx.rs 0.00% 293 Missing ⚠️
crates/sdk/src/signing.rs 0.00% 134 Missing ⚠️
crates/apps_lib/src/cli.rs 0.00% 110 Missing ⚠️
crates/namada/src/ledger/protocol/mod.rs 77.65% 78 Missing ⚠️
crates/light_sdk/src/transaction/transfer.rs 0.00% 32 Missing ⚠️
crates/node/src/bench_utils.rs 0.00% 31 Missing ⚠️
crates/token/src/lib.rs 0.00% 26 Missing ⚠️
crates/sdk/src/lib.rs 0.00% 24 Missing ⚠️
crates/state/src/wl_state.rs 58.82% 21 Missing ⚠️
... and 13 more
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3439      +/-   ##
==========================================
- Coverage   53.92%   53.51%   -0.41%     
==========================================
  Files         317      317              
  Lines      107575   108647    +1072     
==========================================
+ Hits        58011    58147     +136     
- Misses      49564    50500     +936     

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

@grarco grarco marked this pull request as ready for review June 25, 2024 13:22
@grarco grarco requested a review from murisi June 25, 2024 13:22
murisi
murisi previously approved these changes Jun 25, 2024
Copy link
Contributor

@murisi murisi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great, thanks!

@grarco grarco mentioned this pull request Jun 25, 2024
brentstone added a commit that referenced this pull request Jun 28, 2024
* grarco/early-sapling-balance-check:
  Extracts the sapling value balance directly in `validate_transparent_bundle`
  Changelog #2721
  Early sapling balance check in masp vp
brentstone added a commit that referenced this pull request Jul 4, 2024
* origin/grarco/early-sapling-balance-check:
  Extracts the sapling value balance directly in `validate_transparent_bundle`
  Changelog #2721
  Early sapling balance check in masp vp
@brentstone brentstone merged commit 93e7911 into main Jul 5, 2024
11 of 19 checks passed
@brentstone brentstone deleted the grarco/early-sapling-balance-check branch July 5, 2024 21:16
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

Successfully merging this pull request may close these issues.

Early rejection of transactions with invalid sapling value balance
3 participants