Contributing
Contributing
PayloadFactory is developed by Ben Mz (x42en). Contributions — bug reports, new injection techniques, and template fixes — are welcome.
Running the test suite
The project is managed with Poetry and tested with pytest (see [tool.pytest.ini_options] in pyproject.toml):
poetry install
poetry run pytest
Tests live in tests/ and cover the template manager, constants, factory pipeline, injection routing, and end-to-end generation (including multi-OS).
Adding an injection technique
An injection technique is primarily a template plus a constants entry:
- Add a stub under
payloadfactory/templates/windows/{kernel,userland}/(orlinux/{kernel,userland}/) following the existing//#### PATTERN ####convention. - Add the technique name to the appropriate list in
payloadfactory/constants/payload_constants.py(SUPPORTED_INJECTIONS,REMOTE_INJECTIONS, orUSERLAND_INJECTIONS;LINUX_*for Linux). - Register a subparser for the technique in
main.py.
Note: the codebase currently contains both snake_case and legacy camelCase module files.
main.pyimports the snake_case modules (e.g.payload_factory,executable_factory,template_manager) — treat those as the source of truth.
Reporting issues
Please file issues on the GitHub repository with the full CLI invocation, target OS/arch, and the exact error message. PayloadFactory shells out to external compilers and the donut binary, so include your toolchain versions when reporting build failures.