Drop message decode max length to 4_000_000#340
Merged
apoelstra merged 1 commit intorust-bitcoin:masterfrom Nov 12, 2019
Merged
Drop message decode max length to 4_000_000#340apoelstra merged 1 commit intorust-bitcoin:masterfrom
apoelstra merged 1 commit intorust-bitcoin:masterfrom
Conversation
It has been a long time since Bitcoin's maximum network message length was 32MB, so we should follow suit. This is also an important DoS limit, so we should limit it as much as possible.
Codecov Report
@@ Coverage Diff @@
## master #340 +/- ##
==========================================
- Coverage 81.89% 81.64% -0.26%
==========================================
Files 38 38
Lines 7169 7032 -137
==========================================
- Hits 5871 5741 -130
+ Misses 1298 1291 -7
Continue to review full report at Codecov.
|
apoelstra
approved these changes
Nov 6, 2019
Member
apoelstra
left a comment
There was a problem hiding this comment.
Nice. Trusting you that this matches Core's behaviour.
Member
Author
tamasblummer
approved these changes
Nov 11, 2019
Member
|
In the future we might want to decouple the limit for deserializing any |
dagurval
added a commit
to dagurval/rust-bitcoin
that referenced
this pull request
Jul 15, 2020
This adds the feature flag 'bump-decode-max-size' that when set, sets maximum decode size to the limit it was before PR rust-bitcoin#340.
yancyribbens
pushed a commit
to yancyribbens/rust-bitcoin
that referenced
this pull request
Mar 23, 2024
…tisfaction size 747876e Rectify `from_multi_a` max satisfaction size (Aman Rojjha) Pull request description: Cost incurred for a single Schnorr signature in the witness stack := `<var_int><64-byte signature><sig_type>` = 1 + 64 + 1 (as clarified by @sanket1729 in rust-bitcoin#340 ). ACKs for top commit: sanket1729: ACK 747876e Tree-SHA512: f20652240f1daa7b33b1d525870114e0bd6412e82845e80a94c616dedcfb3d8ae2f7ef19d7c08760f79270e0d465c18b713eff2e3e599b45c65f2a64da36713b
PastaPastaPasta
pushed a commit
to PastaPastaPasta/rust-dashcore
that referenced
this pull request
Feb 2, 2026
This file contains hidden or 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
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.
It has been a long time since Bitcoin's maximum network message
length was 32MB, so we should follow suit. This is also an important
DoS limit, so we should limit it as much as possible.