收集 Forcepoint Web Security 日志
本文档介绍了如何使用 Bindplane 代理将 Forcepoint Web Security 日志注入到 Google Security Operations。
Forcepoint Web Security 是一种 Web 代理和安全网关,可针对 Web 访问、安全事件、身份验证和政策执行生成 CEF(通用事件格式)syslog 消息。解析器会从 CEF 和 syslog 格式的日志中提取字段,并将其映射到统一数据模型 (UDM)。
准备工作
请确保满足以下前提条件:
- Google SecOps 实例
- Windows Server 2016 或更高版本,或者具有
systemd的 Linux 主机 - Bindplane 代理与 Forcepoint Web Security 之间的网络连接
- 如果通过代理运行,请确保防火墙端口已根据 Bindplane 代理要求打开
- 对 Forcepoint Security Manager 或设备管理界面的管理访问权限
获取 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" /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)" install_unix.sh等待安装完成。
运行以下命令,验证安装是否成功:
sudo systemctl status observiq-otel-collector该服务应显示为有效(正在运行)。
其他安装资源
如需了解其他安装选项和问题排查信息,请参阅 Bindplane 代理安装指南。
配置 Bindplane 代理以注入 syslog 并将其发送到 Google SecOps
您可以将 Bindplane 代理配置为通过 TCP(推荐)或 UDP 接收 syslog 消息。
找到配置文件
Linux:
sudo nano /etc/bindplane-agent/config.yamlWindows:
notepad "C:\Program Files\observIQ OpenTelemetry Collector\config.yaml"
修改配置文件
将 config.yaml 的全部内容替换为您所选协议的配置:
选项 A:TCP 配置(推荐)
receivers: tcplog: listen_address: "0.0.0.0:514" exporters: chronicle/forcepoint_webproxy: compression: gzip creds_file_path: '/etc/bindplane-agent/ingestion-auth.json' customer_id: '<customer_id>' endpoint: malachiteingestion-pa.googleapis.com log_type: FORCEPOINT_WEBPROXY raw_log_field: body service: pipelines: logs/forcepoint_tcp_to_chronicle: receivers: - tcplog exporters: - chronicle/forcepoint_webproxy方案 B:UDP 配置
receivers: udplog: listen_address: "0.0.0.0:514" exporters: chronicle/forcepoint_webproxy: compression: gzip creds_file_path: '/etc/bindplane-agent/ingestion-auth.json' customer_id: '<customer_id>' endpoint: malachiteingestion-pa.googleapis.com log_type: FORCEPOINT_WEBPROXY raw_log_field: body service: pipelines: logs/forcepoint_udp_to_chronicle: receivers: - udplog exporters: - chronicle/forcepoint_webproxy
配置参数
替换以下占位符:
接收器配置:
listen_address:要监听的 IP 地址和端口:0.0.0.0侦听所有接口(推荐)- 端口
514是标准 syslog 端口(在 Linux 上需要 root 权限;对于非 root 用户,请使用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 控制台复制的客户 IDendpoint:区域端点网址:- 美国:
malachiteingestion-pa.googleapis.com - 欧洲:
europe-malachiteingestion-pa.googleapis.com - 亚洲:
asia-southeast1-malachiteingestion-pa.googleapis.com - 如需查看完整列表,请参阅区域级端点
- 美国:
保存配置文件
- 修改后,保存文件:
- Linux:依次按
Ctrl+O、Enter和Ctrl+X - Windows:依次点击文件 > 保存
- Linux:依次按
重启 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 收集器。
- 右键点击并选择重新启动。
验证服务是否正在运行:
sc query observiq-otel-collector检查日志是否存在错误:
type "C:\Program Files\observIQ OpenTelemetry Collector\log\collector.log"
- 按
在 Forcepoint Web Security 上配置 syslog 转发
将 Forcepoint Web Security 配置为以 CEF(通用事件格式)格式将日志转发到 Bindplane 代理。
使用 Forcepoint Security Manager
- 使用管理员凭据登录 Forcepoint Security Manager。
- 前往设置 > 日志记录。
- 在左侧导航栏中,选择日志服务器。
- 点击添加以创建新的日志服务器配置。
- 提供以下配置详细信息:
- 服务器类型:选择 Syslog 服务器或 CEF 服务器。
- 名称:输入一个描述性名称(例如
Google Security Operations Bindplane CEF)。 - 主机:输入 Bindplane 代理的 IP 地址或主机名。
- 端口:输入 Bindplane 代理端口号(例如
514)。 - 协议:选择与您的 Bindplane 配置相符的协议:
- 如果您在 Bindplane 中配置了
tcplog接收器,请选择 TCP(推荐)。 - 如果您在 Bindplane 中配置了
udplog接收器,请选择 UDP。
- 如果您在 Bindplane 中配置了
- 格式:选择 CEF(通用事件格式)。
- 设备:选择 Local0(或其他可用设备)。
- 严重程度:选择信息(以捕获所有日志级别)。
- 在日志类别或事件类型下,选择要转发的事件:
- Web 访问日志(交易日志)
- 安全性事件(威胁检测)
- 身份验证事件(用户登录/退出)
- 系统事件(系统和配置更改)
- 或者,选择所有事件以转发所有可用的日志类型。
- 可选:配置其他设置:
- 批次大小:设置为
1可实现实时转发,设置为更高的值可实现批处理。 - 消息格式:确保已选择 CEF 格式。
- 包含用户信息:启用此选项可在日志中包含用户身份信息。
- 批次大小:设置为
- 点击测试连接,验证与 Bindplane 代理的连接。
- 点击保存以应用配置。
- 点击 Deploy 将配置推送到所有 Forcepoint Web Security 网关。
使用 Forcepoint Web Security Appliance(直接配置)
如果您直接在设备上进行配置,请执行以下操作:
- 登录 Forcepoint Web Security Appliance 管理界面。
- 依次前往系统 > 日志服务器。
- 点击添加或修改以创建或修改日志服务器。
- 提供以下配置详细信息:
- 服务器地址:输入 Bindplane 代理 IP 地址。
- 端口:输入
514(或您的自定义端口)。 - 协议:选择 TCP 或 UDP,以与您的 Bindplane 配置相匹配。
- 格式:选择 CEF 或 Common Event Format。
- 设备:选择 Local0。
- 在日志类型下,选择要转发的日志:
- 访问日志
- 安全日志
- 管理员日志
- 点击应用或保存。
- 如果使用多台设备,请在每台设备上重复此配置。
UDM 映射表
| 日志字段 | UDM 映射 | 逻辑 |
|---|---|---|
action |
security_result.summary |
如果 action_msg 不为空,则映射到 security_result.summary。否则,如果 action 不为空,则将其映射到 security_result.summary。否则,如果 act 不为空,则将其映射到 security_result.summary。 |
action_msg |
security_result.summary |
如果 action_msg 不为空,则映射到 security_result.summary。否则,如果 action 不为空,则将其映射到 security_result.summary。否则,如果 act 不为空,则将其映射到 security_result.summary。 |
app |
target.application |
如果 destinationServiceName 不为空,则映射到 app_name。否则,如果 app 不为空且不包含 http 或 HTTP,则将其映射到 app_name。最后,app_name 映射到 target.application。 |
bytes_in |
network.received_bytes |
如果 in 不为空,则映射到 bytes_in。最后,bytes_in 映射到 network.received_bytes。 |
bytes_out |
network.sent_bytes |
如果 out 不为空,则映射到 bytes_out。最后,bytes_out 映射到 network.sent_bytes。 |
cat |
security_result.category_details |
如果 cat 不为空,则映射到 category。最后,category 映射到 security_result.category_details。 |
category_no |
security_result.detection_fields.value |
如果 category_no 不为空,则会映射到键为 Category Number 的 security_result.detection_fields.value。 |
cn1 |
security_result.detection_fields.value |
如果 cn1 不为空,则会映射到键为 Disposition Number 的 security_result.detection_fields.value。 |
ContentType |
target.file.mime_type |
如果 contentType 不为空,则映射到 ContentType。最后,ContentType 映射到 target.file.mime_type。 |
cs1 |
target_role.description |
cs1 映射到 target_role.description。 |
cs2 |
security_result.category_details |
如果 cs2 不为空且不是 0,则会映射到 security_result.category_details,并带有前缀 Dynamic Category:。 |
cs3 |
target.file.mime_type |
cs3 映射到 target.file.mime_type。 |
description |
metadata.description |
如果 description 不为空,则映射到 metadata.description。 |
destinationServiceName |
target.application |
如果 destinationServiceName 不为空,则映射到 app_name。最后,app_name 映射到 target.application。 |
deviceFacility |
metadata.product_event_type |
如果 product_event 和 deviceFacility 不为空,则使用 - 将它们串联起来,并映射到 metadata.product_event_type。否则,product_event 会映射到 metadata.product_event_type。 |
disposition |
security_result.detection_fields.value |
如果 disposition 不为空,则会映射到键为 Disposition Number 的 security_result.detection_fields.value。 |
dst |
target.ip |
如果 dst 不为空且 dvchost 为空,则映射到 dst_ip。最后,dst_ip 映射到 target.ip。 |
dst_host |
target.hostname |
如果 dst 不为空且 dvchost 为空,则映射到 dst_host。最后,dst_host 映射到 target.hostname。 |
dst_ip |
target.ip |
如果 dst 不为空且 dvchost 为空,则映射到 dst_ip。最后,dst_ip 映射到 target.ip。 |
dst_port |
target.port |
如果 dst 不为空且 dvchost 为空,则映射到 dst_port。最后,dst_port 映射到 target.port。 |
duration |
network.session_duration.seconds |
如果 duration 不为空且不为 0,则映射到 network.session_duration.seconds。 |
dvchost |
intermediary.ip |
如果 dvchost 不为空,则映射到 int_ip。最后,如果 int_ip 是有效的 IP 地址,则将其映射到 intermediary.ip,否则将其映射到 intermediary.hostname。 |
file_path |
target.file.full_path |
如果 file_path 不为空,则映射到 target.file.full_path。 |
host |
principal.ip |
如果 host 不为空,则映射到 src。最后,src 映射到 principal.ip。 |
http_method |
network.http.method |
如果 requestMethod 不为空,则映射到 http_method。否则,如果 method 不为空,则将其映射到 http_method。最后,http_method 映射到 network.http.method。 |
http_proxy_status_code |
network.http.response_code |
如果 http_response 为空或 0 或 -,且 http_proxy_status_code 不为空,则映射到 network.http.response_code。 |
http_response |
network.http.response_code |
如果 http_response 不为空且不是 0 也不是 -,则映射到 network.http.response_code。 |
http_user_agent |
network.http.user_agent |
如果 http_user_agent 不为空且不为 -,则映射到 network.http.user_agent。 |
in |
network.received_bytes |
如果 in 不为空,则映射到 bytes_in。最后,bytes_in 映射到 network.received_bytes。 |
int_host |
intermediary.hostname |
如果 int_ip 不为空,且 int_host 不为空且与 int_ip 不同,则映射到 intermediary.hostname。 |
int_ip |
intermediary.ip |
如果 dvchost 不为空,则映射到 int_ip。最后,如果 int_ip 是有效的 IP 地址,则将其映射到 intermediary.ip,否则将其映射到 intermediary.hostname。 |
level |
target_role.name |
如果 level 不为空且 role 为空,则映射到 role。最后,role 映射到 target_role.name。 |
log_level |
security_result.severity |
如果 severity 为 1 或 log_level 包含 info 或 message 包含 notice,则 security_result.severity 设置为 INFORMATIONAL。如果 severity 为 7,则 security_result.severity 设置为 HIGH。 |
loginID |
principal.user.userid |
如果 loginID 不为空,则映射到 user。最后,如果 user 不为空且不为 -,并且不包含 LDAP,则将其映射到 principal.user.userid。 |
method |
network.http.method |
如果 requestMethod 不为空,则映射到 http_method。否则,如果 method 不为空,则将其映射到 http_method。最后,http_method 映射到 network.http.method。 |
NatRuleId |
security_result.detection_fields.value |
如果 NatRuleId 不为空,则会映射到键为 NatRuleId 的 security_result.detection_fields.value。 |
out |
network.sent_bytes |
如果 out 不为空,则映射到 bytes_out。最后,bytes_out 映射到 network.sent_bytes。 |
pid |
target.process.pid |
如果 pid 不为空,则映射到 target.process.pid。 |
policy |
target_role.description |
如果 Policy 不为空,则映射到 policy。如果 policy 不为空且不为 -,则映射到 target_role.description。 |
Policy |
target_role.description |
如果 Policy 不为空,则映射到 policy。如果 policy 不为空且不为 -,则映射到 target_role.description。 |
product_event |
metadata.product_event_type |
如果 product 不为空,则映射到 product_event。如果 product_event 和 deviceFacility 不为空,则使用 - 将它们串联起来,并映射到 metadata.product_event_type。否则,product_event 会映射到 metadata.product_event_type。 |
proxyStatus-code |
network.http.response_code |
如果 http_response 为空或 0/-,且 http_proxy_status_code 为空但 proxyStatus-code 不为空,则映射到 network.http.response_code。 |
refererUrl |
network.http.referral_url |
如果 refererUrl 不为空且不为 -,则映射到 network.http.referral_url。 |
requestClientApplication |
network.http.user_agent |
如果 requestMethod 不为空,则映射到 http_user_agent。最后,http_user_agent 映射到 network.http.user_agent。 |
requestMethod |
network.http.method |
如果 requestMethod 不为空,则映射到 http_method。最后,http_method 映射到 network.http.method。 |
role |
target_role.name |
如果 level 不为空且 role 为空,则映射到 role。最后,role 映射到 target_role.name。 |
RuleID |
security_result.rule_id |
如果 RuleID 不为空,则映射到 security_result.rule_id。 |
serverStatus-code |
network.http.response_code |
如果 http_response 为空或 0/-,且 http_proxy_status_code 为空但 proxyStatus-code 不为空,则映射到 network.http.response_code。 |
severity |
security_result.severity |
如果 severity 为 1 或 log_level 包含 info 或 message 包含 notice,则 security_result.severity 设置为 INFORMATIONAL。如果 severity 为 7,则 security_result.severity 设置为 HIGH。 |
spt |
principal.port |
如果 spt 不为空,则映射到 src_port。最后,src_port 映射到 principal.port。 |
src |
principal.ip |
如果 src_host 不为空,则映射到 source_ip_temp。如果 source_ip_temp 是有效的 IP 地址且 src 为空,则将其映射到 src。如果 host 不为空,则映射到 src。最后,src 映射到 principal.ip。 |
src_host |
principal.hostname |
如果 src_host 不为空,则映射到 source_ip_temp。如果 source_ip_temp 不是有效的 IP 地址,则会映射到 principal.hostname。如果 source_ip_temp 是有效的 IP 地址且 src 为空,则将其映射到 src。最后,src 映射到 principal.ip。 |
src_port |
principal.port |
如果 src_port 不为空,则映射到 principal.port。 |
suser |
principal.user.userid |
如果 loginID 不为空,则映射到 user。如果 suser 不为空,则映射到 user。最后,如果 user 不为空且不为 -,并且不包含 LDAP,则将其映射到 principal.user.userid。 |
url |
target.url |
如果 url 不为空,则映射到 target.url。 |
user |
principal.user.userid |
如果 loginID 不为空,则映射到 user。如果 suser 不为空,则映射到 user。否则,如果 usrName 不为空,则将其映射到 user。最后,如果 user 不为空且不为 -,并且不包含 LDAP,则将其映射到 principal.user.userid。 |
usrName |
principal.user.userid |
如果 loginID 不为空,则映射到 user。如果 suser 不为空,则映射到 user。否则,如果 usrName 不为空,则将其映射到 user。最后,如果 user 不为空且不为 -,并且不包含 LDAP,则将其映射到 principal.user.userid。 |
when |
metadata.event_timestamp |
如果 when 不为空,系统会对其进行解析并将其映射到 metadata.event_timestamp。 |
| 不适用 | metadata.log_type |
值 FORCEPOINT_WEBPROXY 已硬编码到 metadata.log_type 中。 |
| 不适用 | metadata.product_name |
值 Forcepoint Webproxy 已硬编码到 metadata.product_name 中。 |
| 不适用 | metadata.vendor_name |
值 Forcepoint 已硬编码到 metadata.vendor_name 中。 |
| 不适用 | network.application_protocol |
如果 dst_port 为 80,则 network.application_protocol 设置为 HTTP。如果 dst_port 为 443,则 network.application_protocol 设置为 HTTPS。 |
| 不适用 | principal.user.group_identifiers |
如果 user 不为空且不是 -,并且包含 LDAP,则提取用户字符串的 OU 部分并将其映射到 principal.user.group_identifiers。 |
| 不适用 | principal.user.user_display_name |
如果 user 不为空且不为 -,并且包含 LDAP,则提取用户字符串的用户名部分并将其映射到 principal.user.user_display_name。 |
| 不适用 | security_result.action |
如果 action_msg、action 或 act 不为空,则根据它们的值将 sec_action 设置为 ALLOW 或 BLOCK。最后,sec_action 映射到 security_result.action。 |
| 不适用 | security_result.detection_fields.key |
在映射 disposition 或 cn1 时,值 Disposition Number 会硬编码到 security_result.detection_fields.key 中。在映射 NatRuleId 时,值 NatRuleId 会硬编码到 security_result.detection_fields.key 中。在映射 category_no 时,值 Category Number 会硬编码到 security_result.detection_fields.key 中。 |
需要更多帮助?获得社区成员和 Google SecOps 专业人士的解答。