
Hands-on lab for CVE-2026-40072 — SSRF vulnerability in web3.py via CCIP Read (EIP-3668)
Hands-on local lab to demonstrate CVE-2026-40072 in web3.py, show the SSRF impact in Burp Suite, and verify the official fix.
This repository contains a safe, local-only proof of concept for CVE-2026-40072, a Server-Side Request Forgery (SSRF) issue tied to CCIP Read / OffchainLookup handling in web3.py. The lab uses Kali Linux, a Python virtual environment, Flask as a fake internal service, and Burp Suite to intercept the outbound request.
This lab is for authorized, local, educational use only. Run everything in your own isolated environment. Do not test against systems you do not own or have permission to assess.
python3 -m venv ~/ssrf-lab
source ~/ssrf-lab/bin/activate
pip install -r requirements.txt
If Kali blocks system-wide pip, keep using the venv above.
source ~/ssrf-lab/bin/activate
python3 lab/fake_internal_server.py
Keep this terminal open. It simulates a sensitive internal endpoint.
127.0.0.1:8080.source ~/ssrf-lab/bin/activate
python3 lab/ssrf_demo.py
The request should appear in Burp and the fake service should return a demo credential string.
Upgrade to the fixed release:
pip install "web3==7.15.0"
Then confirm the version:
pip show web3 | grep Version
Run the check script:
python3 lab/ssrf_fixed_check.py
You should confirm the patched environment and document that the SSRF request no longer occurs.
MIT