An LLM-based multi-agent framework for end-to-end reproduction of CVEs.
RESULTS.md provides details on accessing the results.
If you want to reproduce a CVE follow the steps in (A-❶) to extract CVE data, otherwise, to reproduce a vulnerability that is not a CVE, follow step in (A-❷).
‼️ Currently to extract CVE data we rely oncvelistbut it will be deprecated in the future, this we are planning to move tocvelistV5soon!
-
Install necessary packages
python3 -m venv env pip install -r src/data/requirements.txt playwright install
-
Clone the
cvelistrepositorycd src/ git clone https://github.com/CVEProject/cvelistV5.git data/cvelistV5/ -
Create
.envinsrc/and make sure it has yourGITHUB_TOKEN -
Run the following script to extract the given CVE data
python3 ./data/scripts/cve_data.py --cve_id CVE-2024-4340 --output_path ./data/example/test.json
-
If the above script returns
✅ Ready to reproduce!!you can move to next step, otherwise go to PROCESSING.md, you might have to add some missing CVE context (mainly source code url and its version) manually. This can happen because the CVE records incvelistV5(1) do not contain the source code information (maybe because the CVE belongs to a commercial product), (2) records were modified, or (3) our parsing script was not able to automatically extract some of the content.
Currently, we do not support automated extraction of non-CVE data, so please refer to PROCESSING.md and you can manually add vulnerability context to reproduce it.
We provide the following two options to run CVE-Genie:
‼️ Easy to setup but it might not be compatible for CVEs that require running multiple services, as it can crash the DevContainer
-
Start the
devcontainerin VS Code -
cdinto thesrcdirectory -
Create
.envfile insrc, and add theOPENAI_API_KEYto use -
Run the following command to reproduce the given CVE
ENV_PATH=.env MODEL=example_run python3 main.py --cve CVE-2024-4340 --json data/example/test.json --run-type build,exploit,verify
-
The final results will be stored in
/shared/<cve_id>/
Read the VM Library Documentation on how to run it in a VM.
-
Make sure the CVE reproduction run that you are trying to visualize is in
results/reproduced_cve/ -
Run the visualizer
cd visualizer/ python3 serve.py -
Click on the
urlgenerated by the above script and it will take you to the web application. -
Enter CVE-ID in the given field and click
Load CVE. Now you can navigate through the agent conversations and tool calls and intermediate artifacts for all components of CVE-Genie for the given CVE's reproduction run.