cad-polito-it/byron

GitHub: cad-polito-it/byron

Byron 是一个基于进化算法的源代码模糊测试框架,通过随机生成并迭代优化程序来探索和评估汇编及高级语言代码。

Stars: 11 | Forks: 3

# `byron` 🖋 [![代号](https://img.shields.io/badge/codename-Don_Juan-pink.svg)](https://en.wikipedia.org/wiki/Don_Juan_(poem)) [![PyPI - 状态](https://img.shields.io/pypi/status/byron)](https://en.wikipedia.org/wiki/Software_release_life_cycle) [![GitHub 许可证](https://img.shields.io/github/license/squillero/byron)](https://opensource.org/licenses/) [![GitHub 仓库大小](https://img.shields.io/github/repo-size/squillero/byron)](https://github.com/squillero/byron) [![PyPI - Python 版本](https://img.shields.io/pypi/pyversions/byron)](https://www.python.org/) [![GitHub 工作流状态 (包含事件)](https://img.shields.io/github/actions/workflow/status/squillero/byron/pytest.yml?label=pytest)](https://github.com/squillero/byron/actions) [![FOSSA 状态](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fcad-polito-it%2Fbyron.svg?type=shield)](https://app.fossa.com/projects/git%2Bgithub.com%2Fcad-polito-it%2Fbyron?ref=badge_shield) [![文档状态](https://readthedocs.org/projects/byron/badge/?version=pre-alpha)](https://byron.readthedocs.io/en/pre-alpha/?badge=pre-alpha) [![PyPI - 版本](https://img.shields.io/pypi/v/byron?label=pypi)](https://pypi.org/project/byron/) [![PyPI - 下载量](https://img.shields.io/pypi/dm/byron?label=downloads)](https://pypi.org/project/byron/) Byron 是一个源代码 [fuzzer](https://en.wikipedia.org/wiki/Fuzzing),旨在支持汇编语言和高级语言。它首先生成一组随机程序,然后通过 [进化算法](https://cad-polito-it.github.io/byron/evolution) 对其进行迭代改进。在内部,它将候选解编码为 [有类型](https://rcor.me/papers/typed-graph-theory.pdf)、[有向](https://en.wikipedia.org/wiki/Graph_(discrete_mathematics#Directed_graph) [多重图](https://en.wikipedia.org/wiki/Multigraph),并且能够有效地处理包含局部和全局变量、条件与循环语句以及子程序的复杂且真实的结构。 程序可以通过用户自定义的 Python 函数或外部工具(如解释器或模拟器)进行评估。它原生支持多种类型的并行化,从简单的多线程,到创建多个子进程同时 [衍生](https://en.wikipedia.org/wiki/Spawn_(computing)) 的临时目录。 :package: 该 Python 包已在 [PyPi](https://pypi.org/project/byron/) 上发布;如果你想修改代码,本仓库才会派上用场。 ### 太长不看 * Byron 目前处于 [alpha](https://en.wikipedia.org/wiki/Software_release_life_cycle#Alpha) 阶段,且正在积极 开发中 * 默认分支始终是最稳定的 * 除非你确实清楚自己在做什么,否则请勿克隆实验性分支 `exp/*` * 请遵循此 [风格指南](https://github.com/squillero/style/blob/master/python.md),并使用 [Ruff](https://docs.astral.sh/ruff/formatter/) 格式化代码 * 撰写提交信息时请遵循此 [约定](https://github.com/squillero/style/blob/master/git.md) * 尽量少写代码行数,多写注释行数(即,使用内置函数,利用生成器和列表 推导式) * 保持 [偏执](https://cad-polito-it.github.io/byron/paranoia) (引自 *"I need someone to show me the things"*) * 使用 [pytest](https://docs.pytest.org/) 和 [Coverage.py](https://coverage.readthedocs.io/) 进行单元测试(即 `coverage run --module pytest --all`) * 使用 [Ruff](https://docs.astral.sh/ruff/linter/) 进行 lint,使用 [mypy](https://mypy-lang.org/) 进行类型检查 * 使用 [direnv](https://direnv.net) 修补环境变量 * 在尝试更改任何内容之前,最好先联系一下 [Giovanni](https://github.com/squillero) ### 主要贡献者 ### 许可证 版权所有 (c) 2023-24 [Giovanni Squillero](https://github.com/squillero) 与 [Alberto Tonda](https://github.com/albertotonda/) Byron 是一款 [自由且开源的软件](https://en.wikipedia.org/wiki/Free_and_open-source_software),基于宽松的 [Apache License 2.0](https://opensource.org/license/apache-2-0/) 进行分发。
标签:图论, 安全规则引擎, 源代码生成, 演化算法, 逆向工具