-
Notifications
You must be signed in to change notification settings - Fork 27
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
CHIA-1226 Include the cost of the whole spend in get_conditions_from_spendbundle's return value #680
Merged
arvidn
merged 1 commit into
Chia-Network:main
from
AmineKhaldi:cost_in_get_conditions_from_spendbundle
Aug 30, 2024
Merged
CHIA-1226 Include the cost of the whole spend in get_conditions_from_spendbundle's return value #680
arvidn
merged 1 commit into
Chia-Network:main
from
AmineKhaldi:cost_in_get_conditions_from_spendbundle
Aug 30, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
AmineKhaldi
force-pushed
the
cost_in_get_conditions_from_spendbundle
branch
3 times, most recently
from
August 27, 2024 19:48
bced560
to
2dfe9b2
Compare
Rigidity
requested changes
Aug 27, 2024
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.
The benefit of subtracting the cost incrementally as you go is to exit early if the spend exceeds the limit, before processing the actual CLVM and conditions, or other spends. I think doing it afterward could open up a DoS attack vector
AmineKhaldi
force-pushed
the
cost_in_get_conditions_from_spendbundle
branch
from
August 27, 2024 20:06
2dfe9b2
to
ae7c06f
Compare
Rigidity
previously approved these changes
Aug 27, 2024
arvidn
requested changes
Aug 27, 2024
Pull Request Test Coverage Report for Build 10630724752Details
💛 - Coveralls |
AmineKhaldi
force-pushed
the
cost_in_get_conditions_from_spendbundle
branch
from
August 27, 2024 20:54
ae7c06f
to
0f1ca2c
Compare
AmineKhaldi
force-pushed
the
cost_in_get_conditions_from_spendbundle
branch
from
August 28, 2024 16:50
0f1ca2c
to
84c8429
Compare
arvidn
reviewed
Aug 29, 2024
arvidn
reviewed
Aug 29, 2024
arvidn
reviewed
Aug 29, 2024
AmineKhaldi
force-pushed
the
cost_in_get_conditions_from_spendbundle
branch
from
August 29, 2024 10:02
84c8429
to
ffe1306
Compare
AmineKhaldi
force-pushed
the
cost_in_get_conditions_from_spendbundle
branch
2 times, most recently
from
August 29, 2024 10:13
ebeb253
to
3340573
Compare
This was referenced Aug 29, 2024
arvidn
reviewed
Aug 30, 2024
arvidn
previously approved these changes
Aug 30, 2024
…e's return value.
AmineKhaldi
force-pushed
the
cost_in_get_conditions_from_spendbundle
branch
from
August 30, 2024 10:01
3340573
to
e13254a
Compare
arvidn
approved these changes
Aug 30, 2024
Rigidity
approved these changes
Aug 30, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The generator doesn't just include the puzzle reveal and the solution, it also includes the coin that's being spent, specifically in the form of
(parent_id, puzzle_hash, amount)
. Each spend will necessarily have to pay that size-cost.