implementing-next-generation-firewall-with-palo-alto について
ネットワークセキュリティチーム向けに、Palo Alto Networks の次世代ファイアウォールの導入と設定を扱うスキルです。アプリケーション・IDベースのポリシー、脅威検査、復号、ログ、検証を取り上げます。
主な機能
- 01App-ID によるアプリ分類
- 02User-ID によるIDマッピング
- 03ゾーンベースのセキュリティポリシー
- 04脅威防御プロファイル
- 05SSL トラフィックの復号
- 06ログ記録とポリシー検証
活用シーン
- 01PA-series または VM-Series の導入
- 02ポートルールからアプリポリシーへの移行
- 03暗号化された送信トラフィックの検査
- 04ファイアウォールログの SIEM 転送
インストール
コマンドをコピーしてターミナルで実行します。
npx skills add https:/ / github.com/ mukul975/ anthropic-cybersecurity-skills --skill implementing-next-generation-firewall-with-palo-altoインストール後、Claude Code で/implementing-next-generation-firewall-with-palo-altoを入力して読み込まれたか確認します。
同梱ファイル
SKILL.md と一緒にインストールされる参考資料やスクリプト。
LICENSEassets/template.mdreferences/api-reference.mdstandards.mdworkflows.mdscripts/agent.pyprocess.py詳細
Palo Alto による次世代ファイアウォールの実装
概要
Palo Alto Networks の次世代ファイアウォール(NGFW)は、従来のポートベースのルール適用を超え、アプリケーションを認識し、ID に基づくセキュリティポリシーを提供します。トラフィックの分類には App-ID、ID ベースの適用には User-ID、脅威検査には Content-ID、暗号化トラフィックの可視化には SSL 復号を活用することで、組織はネットワークトラフィックを包括的に制御できるようになります。このスキルでは、初期構成から高度な脅威防御プロファイルまで、エンドツーエンドの導入を扱います。
使用するタイミング
- 環境で、Palo Alto による次世代ファイアウォールの機能を導入または構成する場合
- コンプライアンス要件に沿ったセキュリティ制御を確立する場合
- この分野のセキュリティアーキテクチャを構築または改善する場合
- この実装が必要となるセキュリティ評価を実施する場合
前提条件
- Palo Alto Networks PA シリーズアプライアンスまたは VM シリーズ仮想ファイアウォール
- PAN-OS 10.2 以降
- 有効な Threat Prevention、URL Filtering、WildFire ライセンス
- ゾーン定義を含むネットワークトポロジのドキュメント
- User-ID 用の LDAP/Active Directory 連携の認証情報
- SSL フォワードプロキシ復号用の社内 CA 証明書
主要な概念
App-ID テクノロジー
App-ID は、ポート、プロトコル、暗号化に関係なく、ネットワークトラフィックをアプリケーションごとに分類します。分類エンジンは、複数の識別手法を順番に使用します。
- アプリケーションシグネチャ - 既知のアプリケーションシグネチャとのパターンマッチング
- SSL/TLS 復号 - 暗号化されたトンネル内に隠れたアプリケーションを識別するためにトラフィックを復号
- アプリケーションプロトコルのデコード - プロトコルをデコードし、その中にトンネリングされたアプリケーションを検出
- ヒューリスティック分析 - 他の手法を回避するアプリケーションを対象とした振る舞い分析
Policy Optimizer ツールは、トラフィックログを分析して適切なアプリケーション固有のルールを提案することで、従来のポートベースのルールから App-ID ルールへの移行を支援します。
User-ID 連携
User-ID は、複数の方法で IP アドレスをユーザー ID にマッピングします。
- サーバー監視 - Windows セキュリティイベントログ(イベント ID 4624、4768、4769)を解析
- Syslog リスニング - RADIUS、802.1X、プロキシからの認証イベントを受信
- GlobalProtect - VPN ユーザーを自動的にマッピング
- キャプティブポータル - 未知のユーザー向けの Web ベース認証
- XML API - カスタムソースからのプログラムによるユーザーマッピング
ゾーンベースのアーキテクチャ
ゾーンは、ネットワークの論理的なセグメントを表します。セキュリティポリシーは、ゾーン間(インターゾーン)およびゾーン内(イントラゾーン)のトラフィックを制御します。
| ゾーン | 目的 | 信頼レベル |
|---|---|---|
| Trust | 社内コーポレート LAN | 高 |
| Untrust | インターネット向け | なし |
| DMZ | 公開向けサーバー | 中 |
| Guest | ゲスト用無線 LAN | 低 |
| DataCenter | サーバー基盤 | 高 |
ワークフロー
ステップ 1: 初期システム構成
管理インターフェース、DNS、NTP、およびシステム設定を構成します。
set deviceconfig system hostname PA-FW01
set deviceconfig system domain corp.example.com
set deviceconfig system dns-setting servers primary 10.0.1.10
set deviceconfig system dns-setting servers secondary 10.0.1.11
set deviceconfig system ntp-servers primary-ntp-server ntp-server-address 0.pool.ntp.org
set deviceconfig system timezone US/Eastern
set deviceconfig system login-banner "Authorized access only. All activity is monitored."
ステップ 2: ネットワークゾーンとインターフェースの構成
セキュリティゾーンを定義し、インターフェースを割り当てます。
set zone Trust network layer3 ethernet1/1
set zone Untrust network layer3 ethernet1/2
set zone DMZ network layer3 ethernet1/3
set zone Guest network layer3 ethernet1/4
set network interface ethernet ethernet1/1 layer3 ip 10.10.0.1/24
set network interface ethernet ethernet1/1 layer3 interface-management-profile allow-ping
set network interface ethernet ethernet1/2 layer3 dhcp-client
set network virtual-router default interface [ ethernet1/1 ethernet1/2 ethernet1/3 ethernet1/4 ]
ステップ 3: ゾーン保護プロファイルの構成
ゾーンレベルで偵察攻撃および DoS 攻撃から保護します。
set network profiles zone-protection-profile Strict-ZP flood tcp-syn enable yes
set network profiles zone-protection-profile Strict-ZP flood tcp-syn alert-rate 100
set network profiles zone-protection-profile Strict-ZP flood tcp-syn activate-rate 500
set network profiles zone-protection-profile Strict-ZP flood tcp-syn maximal-rate 2000
set network profiles zone-protection-profile Strict-ZP flood tcp-syn syn-cookies enable yes
set network profiles zone-protection-profile Strict-ZP flood udp enable yes
set network profiles zone-protection-profile Strict-ZP flood icmp enable yes
set network profiles zone-protection-profile Strict-ZP scan 8003 action block-ip
set network profiles zone-protection-profile Strict-ZP scan 8003 interval 2
set network profiles zone-protection-profile Strict-ZP scan 8003 threshold 100
ステップ 4: 脅威防御プロファイルの構成
Anti-Virus、Anti-Spyware、Vulnerability Protection、URL Filtering の各プロファイルを作成します。
# Anti-Spyware Profile
set profiles spyware Strict-AS botnet-domains lists default-paloalto-dns packet-capture single-packet
set profiles spyware Strict-AS botnet-domains sinkhole ipv4-address pan-sinkhole-default-ip
set profiles spyware Strict-AS rules Block-Critical severity critical action block-ip
# Vulnerability Protection Profile
set profiles vulnerability Strict-VP rules Block-Critical-High vendor-id any severity [ critical high ] action block-ip
# URL Filtering Profile
set profiles url-filtering Strict-URL credential-enforcement mode ip-user
set profiles url-filtering Strict-URL block [ command-and-control malware phishing ]
set profiles url-filtering Strict-URL alert [ hacking proxy-avoidance-and-anonymizers ]
# File Blocking Profile
set profiles file-blocking Strict-FB rules Block-Dangerous application any file-type [ bat exe msi ps1 vbs ] direction both action block
# WildFire Analysis Profile
set profiles wildfire-analysis Strict-WF rules Forward-All application any file-type any direction both analysis public-cloud
ステップ 5: SSL 復号の構成
送信トラフィックの検査のために SSL フォワードプロキシを設定します。
# Generate Forward Trust CA certificate
request certificate generate certificate-name SSL-FP-CA algorithm RSA digest sha256 ca yes
# Create Decryption Profile
set profiles decryption Strict-Decrypt ssl-forward-proxy block-expired-certificate yes
set profiles decryption Strict-Decrypt ssl-forward-proxy block-untrusted-issuer yes
set profiles decryption Strict-Decrypt ssl-forward-proxy block-unknown-cert yes
set profiles decryption Strict-Decrypt ssl-forward-proxy restrict-cert-exts yes
# Create Decryption Policy
set rulebase decryption rules Decrypt-Outbound from Trust to Untrust source any destination any
set rulebase decryption rules Decrypt-Outbound action decrypt type ssl-forward-proxy
set rulebase decryption rules Decrypt-Outbound profile Strict-Decrypt
# Exclude sensitive categories (financial, healthcare)
set rulebase decryption rules No-Decrypt-Sensitive from Trust to Untrust
set rulebase decryption rules No-Decrypt-Sensitive category [ financial-services health-and-medicine ]
set rulebase decryption rules No-Decrypt-Sensitive action no-decrypt
ステップ 6: セキュリティポリシーの構築
セキュリティプロファイルを備えた、アプリケーションを認識するセキュリティポリシーを作成します。
# Allow business applications from Trust to Internet
set rulebase security rules Allow-Business from Trust to Untrust
set rulebase security rules Allow-Business source-user any
set rulebase security rules Allow-Business application [ office365-enterprise salesforce-base slack-base zoom ]
set rulebase security rules Allow-Business service application-default
set rulebase security rules Allow-Business action allow
set rulebase security rules Allow-Business profile-setting group Strict-Security-Profiles
# Allow web browsing with URL filtering
set rulebase security rules Allow-Web from Trust to Untrust
set rulebase security rules Allow-Web application [ web-browsing ssl ]
set rulebase security rules Allow-Web action allow
set rulebase security rules Allow-Web profile-setting profiles url-filtering Strict-URL
# Block high-risk applications
set rulebase security rules Block-HighRisk from any to any
set rulebase security rules Block-HighRisk application [ bittorrent tor anonymizer ]
set rulebase security rules Block-HighRisk action deny
set rulebase security rules Block-HighRisk log-end yes
# Default deny rule (explicit)
set rulebase security rules Deny-All from any to any source any destination any
set rulebase security rules Deny-All application any service any action deny
set rulebase security rules Deny-All log-end yes
ステップ 7: ログ記録と SIEM 連携の構成
相関分析のために、ログを SIEM へ転送します。
# Configure Syslog Server Profile
set shared log-settings syslog SIEM-Server server SIEM transport UDP port 514 server 10.0.5.100
set shared log-settings syslog SIEM-Server server SIEM facility LOG_USER
# Configure Log Forwarding Profile
set shared log-settings profiles SIEM-Forward match-list Threats log-type threat
set shared log-settings profiles SIEM-Forward match-list Threats send-syslog SIEM-Server
set shared log-settings profiles SIEM-Forward match-list Traffic log-type traffic
set shared log-settings profiles SIEM-Forward match-list Traffic send-syslog SIEM-Server
set shared log-settings profiles SIEM-Forward match-list URL log-type url
set shared log-settings profiles SIEM-Forward match-list URL send-syslog SIEM-Server
検証とテスト
- ポリシー監査 -
show running security-policyで確認し、シャドウされたルールがないかチェックします - トラフィック検証 - トラフィックログを監視し、アプリケーション分類の精度を確認します
- 脅威シミュレーション - EICAR テストファイルと既知の不正 URL を使用して、脅威プロファイルを検証します
- SSL 復号テスト - ブラウザーで証明書チェーンが Forward Trust CA と一致することを確認します
- ゾーンプロテクションテスト - 制御された SYN フラッドを実行し、SYN クッキーが有効化されることを確認します
- ポリシーオプティマイザー - ポリシーオプティマイザーを実行して、残っているポートベースのルールを特定します
# Verify active sessions
show session all filter application web-browsing
# Check threat log entries
show log threat direction equal backward
# Verify App-ID classification
show running application-override
# Check system resources
show system resources
ベストプラクティス
- 最小権限 - すべて拒否することから始め、必要なアプリケーションのみを明示的に許可します
- ポートより App-ID - ポリシーオプティマイザーを使用して、ポートベースのルールをアプリケーション固有のルールに置き換えます
- 復号の適用範囲 - 適切なプライバシー除外設定を行ったうえで、SSL トラフィックの少なくとも 80% を復号します
- セキュリティプロファイルグループ - Anti-Virus、Anti-Spyware、Vulnerability、URL Filtering、File Blocking、WildFire をグループとして適用します
- シグネチャの更新 - Applications と Threats のコンテンツを毎日自動更新するように有効化します
- HA 構成 - 本番環境では、アクティブ/パッシブの HA ペアで展開します
- コミット前の検証 - 設定をコミットする前に、必ず
validate fullで検証します