Page MenuHomePhabricator

fuzz: Rework strong and weak net enum fuzzing
ClosedPublic

Authored by PiRK on Mar 18 2024, 09:09.

Details

Reviewers
Fabien
Group Reviewers
Restricted Project
Commits
rABCbf123f046d93: fuzz: Rework strong and weak net enum fuzzing
Summary

The fuzz tests have several problems:

  • The array passed to the fuzz engine to pick net_permission_flags is outdated
  • The process_message* targets has the service flags as well as connection type hardcoded, limiting potential coverage
  • The service flags deserialization from the fuzz engine doesn't allow for easy "exact matches". The fuzz engine has to explore a 64-bit space to hit an "exact match" (only one bit set)

Fix all issues in the commits in this pull

This is a backport of core#20789

Backport differences explained by out-of-order backports:

  • we no longer have local_services in ConsumeNode (D14750)
  • we no longer have CConnman::SetServices (D12248)
Test Plan

ninja bitcoin-fuzzers

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable