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

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

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

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

ツールディレクトリ

カテゴリ

すべてのカテゴリを見る
Loading categories
sj — 公開された(Swagger/OpenAPI)定義ファイルで定義されたエンドポイントを監査するためのツール。 | Kitploit
ツール/GitHubGitHub/bishopfox/sj
脆弱性スキャナーAPIセキュリティテストウェブセキュリティペネトレーションテスト
GitHubbishopfox/sj

sj

公開された(Swagger/OpenAPI)定義ファイルで定義されたエンドポイントを監査するためのツール。

リポジトリを見る
8671133518日前Kitploit レビュー済み

人気

すべて見る →

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

すべてのツールを探索

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

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

sj (Swagger Jacker)

sjは、公開されているSwagger/OpenAPI定義ファイルに関連するAPIエンドポイントをチェックし、弱い認証を監査するためのコマンドラインツールです。また、手動脆弱性テスト用のコマンドテンプレートも提供します。

このツールは、定義ファイルからパス、パラメータ、および受け入れられるメソッドを解析し、その結果を5つのサブコマンドのいずれかで使用することで機能します。

  • automate - 一連のリクエストを作成し、レスポンスのステータスコードを分析します。
  • prepare - 手動テストに使用するコマンドのリストを生成します。
  • endpoints - 生のAPIルートのリストを生成します。パス値はテストデータに置き換えられません。
  • brute - 一般的なファイルパスに基づいて操作定義を見つけるために、ターゲットに一連のリクエストを送信します。
  • convert - 定義ファイルをv2からv3に変換します。

ビルド

ソースからコンパイルするには、Goバージョン >= 1.22.5 がインストールされていることを確認し、リポジトリ内で go build を実行してください:

$ git clone https://github.com/BishopFox/sj.git
$ cd sj/
$ go build .

インストール

ツールの最新バージョンをインストールするには、以下を実行します:

$ go install github.com/BishopFox/sj@latest

# Note: you may also need to place the path to your Go binaries within your PATH environment variable:
$ export PATH=$PATH:~/go/bin

使用方法

automate コマンドを使用して、定義された各エンドポイントに一連のリクエストを送信し、各レスポンスのステータスコードを分析します。

$ sj automate -u https://petstore.swagger.io/v2/swagger.json -qi -p http://127.0.0.1:8080               

Gathering API details.
Title: Swagger Petstore
Description: This is a sample server Petstore server.  You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/).  For this sample, you can use the api key `special-key` to test the authorization filters.
✓  GET  200  /v2/pet/findByStatus
✓  GET  200  /v2/user/logout
⚠  POST  400  /v2/user/createWithArray
⚠  POST  400  /v2/store/order
✗  GET  404  /v2/store/order/1
⚠  POST  400  /v2/pet
⚠  PUT  415  /v2/pet
⚠  POST  400  /v2/user/createWithList
✗  GET  404  /v2/user/bishopfox
⚠  PUT  415  /v2/user/bishopfox
⚠  POST  400  /v2/user
⚠  POST  415  /v2/pet/1/uploadImage
✓  GET  200  /v2/pet/findByTags
✗  GET  404  /v2/pet/1
⚠  POST  415  /v2/pet/1
✓  GET  200  /v2/store/inventory
✓  GET  200  /v2/user/login

--replay-proxy フラグを使用すると、一致したリクエストを別のプロキシ(例:Burp Suite)を介して再生できます。これにより、すべてのトラフィックを1つのプロキシ(または直接)経由でルーティングしながら、興味深い結果のみをインターセプトプロキシに送信できます:

$ sj automate -u https://petstore.swagger.io/v2/swagger.json -qi --replay-proxy http://127.0.0.1:8080

また、--proxy と組み合わせて、スキャントラフィックを別のプロキシ経由でルーティングし、一致したリクエストをBurpに再生することもできます:

$ sj automate -u https://petstore.swagger.io/v2/swagger.json -qi -p http://proxy:9090 --replay-proxy http://127.0.0.1:8080

詳細出力を要求して、応答の一部(または全体)を表示することもできます:

$ sj automate -u https://petstore.swagger.io/v2/swagger.json -qi -p http://127.0.0.1:8080 -v           

Gathering API details.
Title: Swagger Petstore
Description: This is a sample server Petstore server.  You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/).  For this sample, you can use the api key `special-key` to test the authorization filters.
✗  GET  404  /v2/user/bishopfox
   {"code":1,"type":"error","message":"User not found
⚠  PUT  415  /v2/user/bishopfox
   {"code":415,"type":"unknown","message":"com.sun.je
✓  GET  200  /v2/user/logout
   {"code":200,"type":"unknown","message":"ok"}
⚠  POST  400  /v2/user/createWithArray
   {"code":400,"type":"unknown","message":"bad input"
⚠  POST  400  /v2/user/createWithList
   {"code":400,"type":"unknown","message":"bad input"
✗  GET  404  /v2/pet/1
   {"code":1,"type":"error","message":"Pet not found"
⚠  POST  415  /v2/pet/1
   {"code":415,"type":"unknown"}
✓  GET  200  /v2/store/inventory
   {"sold":117,"string":26,"invalidStatus":1,"-1":1,"
⚠  POST  400  /v2/store/order
   {"code":400,"type":"unknown","message":"bad input"
✓  GET  200  /v2/user/login
   {"code":200,"type":"unknown","message":"logged in 
⚠  POST  400  /v2/pet
   {"code":400,"type":"unknown","message":"bad input"
⚠  PUT  415  /v2/pet
   {"code":415,"type":"unknown","message":"com.sun.je
✓  GET  200  /v2/pet/findByStatus
   []
✓  GET  200  /v2/pet/findByTags
   []
✗  GET  404  /v2/store/order/1
   {"code":1,"type":"error","message":"Order not foun
⚠  POST  400  /v2/user
   {"code":400,"type":"unknown","message":"bad input"
⚠  POST  415  /v2/pet/1/uploadImage
   {"code":415,"type":"unknown"}

prepare コマンドを使用して、手動テスト用のコマンドリストを準備します。現在は curl と sqlmap の両方をサポートしています。これらは必要に応じて多少変更する必要があります。

$ sj prepare -u https://petstore.swagger.io/v2/swagger.json -qi -p http://127.0.0.1:8080      

INFO[0000] Gathering API details.
                      
Title: Swagger Petstore
Description: This is a sample server Petstore server.  You can find out more about Swagger at [http://swagger.io](http://swagger.io) or on [irc.freenode.net, #swagger](http://swagger.io/irc/).  For this sample, you can use the api key `special-key` to test the authorization filters.
$ curl -X POST "https://petstore.swagger.io/v2/pet/{petId}"
$ curl -X GET "https://petstore.swagger.io/v2/pet/{petId}"
$ curl -X GET "https://petstore.swagger.io/v2/store/inventory"
$ curl -X POST "https://petstore.swagger.io/v2/user/createWithList" -d 'body=1'
$ curl -X GET "https://petstore.swagger.io/v2/user/logout"
$ curl -X POST "https://petstore.swagger.io/v2/user/createWithArray" -d 'body=1'
$ curl -X GET "https://petstore.swagger.io/v2/pet/findByStatus"
$ curl -X GET "https://petstore.swagger.io/v2/pet/findByTags"
$ curl -X POST "https://petstore.swagger.io/v2/store/order" -d 'petId=1&quantity=1&shipDate=bishopfox&status=bishopfox&complete=1&id=1&body='
$ curl -X POST "https://petstore.swagger.io/v2/pet/{petId}/uploadImage"
$ curl -X POST "https://petstore.swagger.io/v2/pet" -d 'photoUrls=1&tags=1&status=bishopfox&id=1&category=&name=doggie&body='
$ curl -X PUT "https://petstore.swagger.io/v2/pet" -d 'id=1&category=&name=doggie&photoUrls=1&tags=1&status=bishopfox&body='
$ curl -X GET "https://petstore.swagger.io/v2/user/{username}"
$ curl -X PUT "https://petstore.swagger.io/v2/user/{username}" -d 'email=bishopfox&password=bishopfox&phone=bishopfox&userStatus=1&id=1&username=bishopfox&firstName=bishopfox&lastName=bishopfox&body='
$ curl -X GET "https://petstore.swagger.io/v2/user/login"
$ curl -X POST "https://petstore.swagger.io/v2/user" -d 'phone=bishopfox&userStatus=1&id=1&username=bishopfox&firstName=bishopfox&lastName=bishopfox&email=bishopfox&password=bishopfox&body='
$ curl -X GET "https://petstore.swagger.io/v2/store/order/{orderId}"

endpoints コマンドを使用して、提供された定義ファイルから生のエンドポイントのリストを生成します。

$ sj endpoints -u https://petstore.swagger.io/v2/swagger.json -qi -p http://127.0.0.1:8080

INFO[0000] Gathering endpoints.
                        
/v2/store/inventory
/v2/store/order/{orderId}
/v2/pet
/v2/pet
/v2/store/order
/v2/user/createWithList
/v2/pet/{petId}/uploadImage
/v2/pet/findByTags
/v2/pet/{petId}
/v2/pet/{petId}
/v2/user/{username}
/v2/user/{username}
/v2/user/createWithArray
/v2/pet/findByStatus
/v2/user/login
/v2/user/logout
/v2/user

brute コマンドを使用して、ターゲットで定義ファイルを見つけるために一連のリクエストを送信します。

$ sj brute -u https://petstore.swagger.io -qi -p http://127.0.0.1:8080 -e
INFO[0000] Sending 2173 requests. This could take a while... 
Request: 343
INFO[0033] Definition file found: https://petstore.swagger.io/v2/swagger 

convert コマンドを使用して、定義ファイルをバージョン2からバージョン3に変換します。

$ sj convert -u https://petstore.swagger.io/v2/swagger.json -qi -p http://127.0.0.1:8080 -o openapi.json

INFO[0000] Gathering API details.
                      
INFO[0000] Wrote file to /current/directory/openapi.json 

ヘルプ

コマンドの完全なリストは --help フラグを使用して確認できます:

$ sj --help
The process of reviewing and testing exposed API definition files is often tedious and requires a large investment of time for a thorough review.
ツールをダウンロード