-
Notifications
You must be signed in to change notification settings - Fork 38.7k
fuzz: rule-out too deep derivation paths in descriptor parsing targets #28832
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
Conversation
|
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. Code CoverageFor detailed information about the code coverage, see the test coverage report. ReviewsSee the guideline for information on the review process.
If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update. |
src/test/fuzz/descriptor_parse.cpp
Outdated
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.
In 77af2c8b8c68f3e971229bd43a7ca6ffe3d0bbe8: Correct me if I'm wrong, but wouldn't HasDeepDerivPath avoid descriptors like pkh([d34db33f/44'/0'/0']xpub6ERApfZwUNrhLCkDtcHTcxd75RbzS1ed54G1LkBUHQVHQKqhMkhgbmJbZRkrgZw4koxb5JaHWkY4ALHY2grBGRjaDMzQLcgJvLJuZZvRcEL/1/*)? Is this intended?
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.
Yes:
Note this may also be hit for deriv paths in origins.
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.
Thanks, didn't notice that.
|
Another (related) one? clusterfuzz-testcase-miniscript_string-6556534783737856.bin.not.txt |
|
Could you add the exception for the bitcoin/src/wallet/test/fuzz/scriptpubkeyman.cpp Lines 54 to 56 in d854914
|
This one seems unrelated to the derivation paths parsing, which is part of the descriptor logic not Miniscript. Looks like it's spending most of the time in |
77af2c8 to
f5942c5
Compare
Done by moving the introduced |
This fixes the reported timeouts and direct the target cycles toward what it's intended to fuzz: the descriptor syntax.
f5942c5 to
a44808f
Compare
|
utACK a44808f |
dergoegge
left a comment
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.
ACK a44808f - Not running into timeouts anymore
sedited
left a comment
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.
ACK a44808f
|
ACK a44808f |


This fixes the
mocked_descriptor_parsetimeout reported in #28812 and direct the targets more toward what they are intended to fuzz: the descriptor syntax.