Use fuzz_targets from clusterfuzz_manifest.json if available - #5387
Open
notvictorl wants to merge 2 commits into
Open
Use fuzz_targets from clusterfuzz_manifest.json if available#5387notvictorl wants to merge 2 commits into
notvictorl wants to merge 2 commits into
Conversation
notvictorl
marked this pull request as draft
July 23, 2026 21:58
notvictorl
marked this pull request as ready for review
July 24, 2026 20:59
dylanjew
reviewed
Jul 28, 2026
dylanjew
left a comment
Collaborator
There was a problem hiding this comment.
is this going to fix all of the run_*_fuzzer targets?
| return False | ||
|
|
||
|
|
||
| def _get_manifest_fuzz_targets(path): |
Collaborator
There was a problem hiding this comment.
should this be a shared util?
| return fuzz_target_paths | ||
|
|
||
|
|
||
| def get_fuzz_targets_local(path): |
Collaborator
There was a problem hiding this comment.
what is the behavior for the non local version of get_fuzz_targets?
|
|
||
|
|
||
| def get_fuzz_targets_local(path): | ||
| """Get list of fuzz targets paths (local).""" |
Collaborator
There was a problem hiding this comment.
nit: update the docstring to explain the manifest and fallback behavior
| def test_manifest_targets_used(self): | ||
| """Test that clusterfuzz_manifest.json is used to find targets.""" | ||
| target_a = self._create_file('target_a', contents=b'LLVMFuzzerTestOneInput') | ||
| self._create_file('run_target_a_fuzzer', contents=b'LLVMFuzzerTestOneInput') |
Collaborator
There was a problem hiding this comment.
nit: instead of target_a and run_target_a_fuzzer you could name these something like manifest_target and file_target or dir_target and the assertions would be clearer
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.
Chrome archives initially pick fuzz targets from a
fuzz_targetproperty fromclusterfuzz_manifest.json, but it doesn't use it on future runs when picking fuzz targets. This leads to wasting time doing a directory scan for_fuzzerbinaries to choose a fuzz target and can pick a binary that is not intended to be run (run_*_fuzzer).Modifying fuzzer utils to re-access
clusterfuzz_manifest.jsonforfuzz_targetsif available otherwise fall back to existing behavior. Adding unit tests for fuzzer utils.Drive-by: Improve Chrome manifest path search by joining to
root_dirfor wrapped directories where ClusterFuzz's build directory is not the Chrome archives root directory with respective unit tests.Bug: https://crbug.com/507833074