收集 Fortinet FortiAnalyzer 記錄
本指南說明如何使用 Bindplane,將 Fortinet FortiAnalyzer 記錄檔擷取至 Google Security Operations。
Fortinet FortiAnalyzer 是集中式記錄管理、分析和報表平台,適用於 Fortinet Security Fabric 裝置。這項服務會彙整 FortiGate 防火牆、FortiMail、FortiWeb、FortiSandbox 和其他 Fortinet 產品的記錄,提供統一的能見度、事件關聯性和法規遵循報告。FortiAnalyzer 可以透過系統記錄將匯總記錄轉送至外部 SIEM 平台,以供進一步分析。
事前準備
請確認您已完成下列事前準備事項:
- Google SecOps 執行個體。
- Windows Server 2016 以上版本,或搭載
systemd的 Linux 主機。 - Bindplane 代理程式與 FortiAnalyzer 設備之間的網路連線。
- 如果透過 Proxy 執行,請確保防火牆通訊埠已根據 Bindplane 代理程式需求開啟。
- 具備 Fortinet FortiAnalyzer 管理控制台的特殊存取權 (Super_User 或同等管理員角色)。
取得 Google SecOps 擷取驗證檔案
- 登入 Google SecOps 控制台。
- 依序前往「SIEM 設定」>「收集代理程式」。
- 下載擷取驗證檔案。
- 將檔案安全地儲存在要安裝 Bindplane 的系統上。
取得 Google SecOps 客戶 ID
- 登入 Google SecOps 控制台。
- 依序前往「SIEM 設定」>「設定檔」。
- 複製並儲存「機構詳細資料」部分中的客戶 ID。
安裝 Bindplane 代理程式
請按照下列操作說明,在 Windows 或 Linux 作業系統上安裝 Bindplane 代理程式。
Windows 安裝
- 以管理員身分開啟「命令提示字元」或「PowerShell」。
執行下列指令:
msiexec /i "[https://github.com/observIQ/bindplane-agent/releases/latest/download/observiq-otel-collector.msi](https://github.com/observIQ/bindplane-agent/releases/latest/download/observiq-otel-collector.msi)" /quiet等待安裝完成。
執行下列指令,確認安裝成功:
sc query observiq-otel-collector服務應顯示為「RUNNING」。
Linux 安裝
- 開啟具備 root 或 sudo 權限的終端機。
執行下列指令:
sudo sh -c "$(curl -fsSlL [https://github.com/observiq/bindplane-agent/releases/latest/download/install_unix.sh](https://github.com/observiq/bindplane-agent/releases/latest/download/install_unix.sh))" install_unix.sh等待安裝完成。
執行下列指令,確認安裝成功:
sudo systemctl status observiq-otel-collector
服務應顯示為有效 (執行中)。
其他安裝資源
如需其他安裝選項和疑難排解資訊,請參閱 Bindplane 代理程式安裝指南。
設定 Bindplane 代理程式,擷取系統記錄檔並傳送至 Google SecOps
找出設定檔
- Linux:
bash sudo nano /opt/observiq-otel-collector/config.yaml - Windows:
cmd notepad "C:\Program Files\observIQ OpenTelemetry Collector\config.yaml"
編輯設定檔
將
config.yaml的所有內容替換為下列設定:receivers: tcplog: # Replace the port and IP address as required listen_address: "0.0.0.0:514" exporters: chronicle/fortianalyzer: compression: gzip # Adjust the path to the credentials file you downloaded in Step 1 creds_file_path: '/etc/bindplane-agent/ingestion-auth.json' # Replace with your actual customer ID from Step 2 customer_id: 'your-customer-id-here' endpoint: malachiteingestion-pa.googleapis.com log_type: FORTINET_FORTIANALYZER raw_log_field: body ingestion_labels: env: production service: pipelines: logs/fortianalyzer_to_chronicle: receivers: - tcplog exporters: - chronicle/fortianalyzer
設定參數
- 接收器設定:
listen_address:要接聽的 IP 位址和通訊埠。如要接聽所有介面,請使用0.0.0.0。視需要變更通訊埠 (例如1514)。
- 匯出工具設定:
creds_file_path:擷取驗證檔案的完整路徑:- Linux:
/etc/bindplane-agent/ingestion-auth.json - Windows:
C:\Program Files\observIQ OpenTelemetry Collector\ingestion-auth.json
- Linux:
customer_id:您的 Google SecOps 客戶 ID。endpoint:區域端點網址 (例如malachiteingestion-pa.googleapis.com)。ingestion_labels:YAML 格式的選用標籤 (例如env: production)。
儲存設定檔
編輯完成後,請儲存檔案:
- Linux:依序按下
Ctrl+O、Enter和Ctrl+X鍵。 - Windows:依序點選「檔案」「儲存」。
重新啟動 Bindplane 代理程式,以套用變更
如要在 Linux 中重新啟動 Bindplane 代理程式,請執行下列步驟:
執行下列指令:
sudo systemctl restart observiq-otel-collector確認服務正在執行:
sudo systemctl status observiq-otel-collector檢查記錄中是否有錯誤:
sudo journalctl -u observiq-otel-collector -f
如要在 Windows 中重新啟動 Bindplane 代理程式,請按照下列步驟操作:
您可以選擇下列其中一個選項:
- 以管理員身分開啟命令提示字元或 PowerShell:
net stop observiq-otel-collector && net start observiq-otel-collector- 服務控制台:
- 按下
Win+R,輸入services.msc,然後按下 Enter 鍵。 - 找出 observIQ OpenTelemetry Collector。
- 按一下滑鼠右鍵,然後選取「重新啟動」。
- 按下
確認服務正在執行:
sc query observiq-otel-collector檢查記錄中是否有錯誤:
type "C:\Program Files\observIQ OpenTelemetry Collector\log\collector.log"
設定 FortiAnalyzer 系統記錄檔轉送
設定 FortiAnalyzer,使用系統記錄輸出將記錄轉送至 Bindplane 代理程式。
在 FortiAnalyzer 中設定 Syslog 伺服器
- 登入 FortiAnalyzer 網頁介面。
- 依序前往「系統設定」>「記錄轉送」。
- 按一下「建立新規則」,新增記錄轉送規則。
- 請提供下列設定詳細資料:
- 名稱:輸入描述性名稱 (例如
Chronicle-Bindplane)。 - 狀態:選取「啟用」。
- 遠端伺服器類型:選取「系統記錄檔」。
- 伺服器 IP/FQDN:輸入 Bindplane 代理程式主機的 IP 位址。
- 伺服器通訊埠:輸入
514(或在 Bindplane 代理程式中設定的通訊埠)。 - 可靠的系統記錄檔 (RFC 6587):選取「啟用」即可使用 TCP 傳輸。
- 記錄轉送格式:根據需求選取「預設」或「CEF」。
- 名稱:輸入描述性名稱 (例如
- 在「記錄篩選器」部分,設定要轉送的記錄類型:
- 選取要轉送記錄檔的 ADOM (管理網域)。
- 選取要納入的裝置類型和記錄類別 (流量、事件、安全性、DNS、SSH、SSL 記錄)。
- 按一下「確定」儲存設定。
確認記錄轉送
- 依序前往「系統設定」>「記錄轉送」。
- 確認轉送規則的狀態為「已啟用」Enabled。
- 監控「統計資料」欄,確認記錄已轉送。
- 查看 Bindplane 代理程式記錄,確認系統是否收到記錄。
UDM 對應表
| 記錄欄位 | UDM 對應 | 邏輯 |
|---|---|---|
devname |
principal.hostname |
取自 devname。 |
srcip |
principal.ip |
取自 srcip。 |
srcport |
principal.port |
已轉換為整數。 |
srcintf |
additional.fields |
金鑰:srcintf。 |
dstip |
target.ip |
取自 dstip。 |
dstport |
target.port |
已轉換為整數。 |
dstintf |
additional.fields |
金鑰:dstintf。 |
proto |
network.ip_protocol |
已對應 (6=TCP、17=UDP、1=ICMP)。 |
action |
security_result.action |
accept/pass → 允許;deny/drop/block → 封鎖。 |
policyid |
security_result.rule_id |
取自 policyid。 |
policyname |
security_result.rule_name |
取自 policyname。 |
user |
principal.user.userid |
取自 user。 |
app |
target.application |
取自 app。 |
sentbyte |
network.sent_bytes |
已轉換為無正負號整數。 |
rcvdbyte |
network.received_bytes |
已轉換為無正負號整數。 |
severity |
security_result.severity |
information → INFORMATIONAL、warning → MEDIUM、error → ERROR、critical/alert/emergency → HIGH。 |
logid |
metadata.product_log_id |
取自 logid。 |
type |
metadata.product_event_type |
取自 type。 |
subtype |
metadata.product_event_type |
已附加至類型。 |
level |
security_result.severity_details |
取自 level。 |
| 不適用 | metadata.vendor_name |
設為 Fortinet。 |
| 不適用 | metadata.product_name |
設為 FortiAnalyzer。 |
變更記錄
還有其他問題嗎?向社群成員和 Google SecOps 專業人員尋求答案。