このNuclei Actionを使うと、NucleiをGitHub Actionで簡単に連携できます。 すべてのNuclei Templatesを強力な継続的セキュリティワークフローに統合し、セキュアなソフトウェア開発ライフサイクルの一部にしましょう。
Nuclei Action
v3.0.0+ は Node.js v24 で動作し、CLIファーストのインターフェースを採用しています。version、install-only、args などの入力を受け付け、出力は stdout と stderr のみに出力します。v2.0.0+ および v2.x は、target、urls、templates、workflows、flags などのアクション固有の入力と、さまざまなエクスポーター/レポートのトグルに依存しています。v2.x は非推奨であり、2026年3月1日以降サポートされません。アップグレード前に MIGRATION.md を参照してください。v1+ は Node.js v16 で動作し、target、urls、templates、workflows、output、json、include-rr、config、report-config、github-report、github-token、sarif-export、markdown-export、flags などの入力を使用します。[!IMPORTANT]
configとconfig-pathは 同時に設定してはいけません。argsはconfigまたはconfig-pathより 常に優先されます。
[!NOTE] デバッグログ が有効な場合、このアクションは自動的に
-debugおよび-verboseフラグを Nuclei に追加します。
| 名前 | 説明 |
|---|---|
stdout | Nuclei実行時の標準出力 |
stderr | Nuclei実行時の標準エラー出力 |
このアクションは node24 アクションです。
- uses: projectdiscovery/nuclei-action@v3
with:
version:
# Setup with specific version ("latest" or in format "vX.Y.Z").
#
# Required: true
# Default: latest
install-only:
# Install Nuclei without running scans.
#
# Required: false
# Default: false
args:
# Arguments to pass to Nuclei.
#
# Required: false
# Default: ""
config:
# Nuclei configuration file content.
#
# Required: false
# Default: ""
config-path:
# Path to Nuclei configuration file.
#
# Required: false
# Default: ""
cache:
# Enable caching of Nuclei caches, configs, templates, and browser.
#
# Required: false
# Default: true
token:
# GitHub Token. It is used to fetch Nuclei releases from GitHub.
#
# Required: true
# Default: ${{ github.token }}
デフォルト設定(最新のNuclei)
- uses: projectdiscovery/nuclei-action@v3
with:
args: -u http://scanme.sh
特定のバージョンでの設定
- uses: projectdiscovery/nuclei-action@v3
with:
version: v3.6.0
args: -u http://scanme.sh
スキャンを実行せずにNucleiをセットアップまたはインストール
- uses: projectdiscovery/nuclei-action@v3
with:
version: v3.6.0
install-only: true
- run: nuclei -version
またはインストールのみでキャッシュなし:
- uses: projectdiscovery/nuclei-action@v3
with:
version: v3.6.0
install-only: true
cache: false
- run: nuclei -version
Nuclei設定を使用したセットアップ
- uses: projectdiscovery/nuclei-action@v3
with:
version: latest
config: |
target:
- http://scanme.sh
sarif-export: results.sarif
または変数を介して渡す:
- uses: projectdiscovery/nuclei-action@v3
with:
version: latest
config: ${{ vars.NUCLEI_CONFIG }}
またはリポジトリ管理の設定ファイルを介して:
- uses: projectdiscovery/nuclei-action@v3
with:
version: latest
config-path: path/to/nuclei.yaml
GitHubコードスキャン を使用した設定
- uses: projectdiscovery/nuclei-action@v3
with:
version: latest
config: |
target:
- http://scanme.sh
sarif-export: results.sarif
- uses: github/codeql-action/upload-sarif@v3
if: success()
with:
sarif_file: results.sarif
category: nuclei-results
レポートを使用した設定
- uses: projectdiscovery/nuclei-action@v3
with:
args: -u http://scanme.sh
config: |
report-config: issue-tracker-config.yaml
env:
GITHUB_BASE_URL: https://localhost:8443/github
GITHUB_USERNAME: test-username
GITHUB_OWNER: test-owner
GITHUB_TOKEN: ${{ secrets.GITHUB_PAT }}
GITHUB_PROJECT_NAME: test-project
issue-tracker-config.yaml(リポジトリファイル):github:
# base-url is the optional self-hosted GitHub application url
base-url: $GITHUB_BASE_URL # read from environment variable
# username is the username of the GitHub user
username: $GITHUB_USERNAME # read from environment variable
# owner is the owner name of the repository for issues
owner: $GITHUB_OWNER # read from environment variable
# token is the token for GitHub account
token: $GITHUB_TOKEN # read from environment variable
# project-name is the name of the repository
project-name: $GITHUB_PROJECT_NAME # read from environment variable
# issue-label is the label of the created issue type
issue-label: bug
# allow-list sets a tracker level filter to only create issues for templates with
# these severity labels or tags (does not affect exporters. set those globally)
allow-list:
severity: high, critical
tags: network
# deny-list sets a tracker level filter to never create issues for templates with
# these severity labels or tags (does not affect exporters. set those globally)
deny-list:
severity: low
# duplicate-issue-check flag to enable duplicate tracking issue check.
duplicate-issue-check: false
https://github.com/projectdiscovery/nuclei/blob/dev/cmd/nuclei/issue-tracker-config.yaml を参照してください。
貢献を歓迎します! 詳細については、貢献ガイド を参照して始めてください。
MIT。詳細は LICENSE を参照してください。
| 名前 | 説明 | 必須 | デフォルト |
|---|
version | 特定のバージョンでセットアップします("latest"または"vX.Y.Z"形式)。 | true | latest |
install-only | スキャンを実行せずにNucleiをインストールします。 | false | false |
args | Nucleiに渡す引数。 | false | "" |
config | Nuclei設定ファイルの内容。 | false | "" |
config-path | Nuclei設定ファイルへのパス。 | false | "" |
cache | Nucleiのキャッシュ、設定、テンプレート、ブラウザのキャッシュを有効にします。 | false | true |
token | GitHub Token。NucleiのリリースをGitHubから取得するために使用されます。 | true | ${{ github.token }} |