evo-atheris-fuzz-driver
Creates Atheris-based coverage-guided fuzz drivers for Python libraries using FuzzedDataProvider for structured input generation. Includes templates and patterns for different library types (parsers,
SKILL.mdtasks-evolved/setup-fuzzing-py/environment/skills/evo-atheris-fuzz-driver/SKILL.md
GitHubAtheris Fuzz Driver Generator
Generates fuzz.py harness files for Python libraries with proper Atheris instrumentation, FuzzedDataProvider usage, and exception handling.
Driver Design Principles
- Import target library inside
atheris.instrument_imports()context manager - Use
FuzzedDataProviderto generate structured typed inputs - Catch only expected exceptions (ValueError, TypeError, domain-specific errors)
- Guard with
if __name__ == "__main__":block - Use
atheris.Setup(sys.argv, TestOneInput)thenatheris.Fuzz()
Supported Libraries
- arrow: Date/time parsing, timestamp boundary testing
- black: Code formatting with Mode configuration
- ipython: Input transformation pipeline
- minisgl: JSON/msgpack parsing (lightweight targets)
- ujson: Differential fuzzing against stdlib json
Key Functions
generate_fuzz_driver(lib_path)- Generate and write fuzz.py for a libraryget_driver_template(lib_name)- Get driver source code for a libraryget_exception_handlers_for_lib(lib_name)- Get expected exceptions listcreate_fuzz_driver_file(lib_path, lib_name)- Write fuzz.py to disk
Usage
import sys
sys.path.insert(0, '/app/environment/skills/evo-atheris-fuzz-driver/scripts')
from fuzz_driver import generate_fuzz_driver, create_fuzz_driver_file
generate_fuzz_driver('/app/arrow')
generate_fuzz_driver('/app/black')