收集 Riverbed SteelHead 日志

支持:

本文档介绍了如何使用 Bindplane 代理将 Riverbed SteelHead 日志注入 Google Security Operations。

Riverbed SteelHead 是一种 WAN 优化设备,可加速广域网上的应用性能。解析器会从 SteelHead 日志条目中提取字段,并将其映射到统一数据模型 (UDM),从而捕获网络流详细信息、身份验证事件、安全结果和系统元数据。

准备工作

请确保满足以下前提条件:

  • Google SecOps 实例
  • Windows Server 2016 或更高版本,或者具有 systemd 的 Linux 主机
  • Bindplane 代理与 Riverbed SteelHead 设备之间的网络连接
  • 如果在代理后面运行,请确保按照 Bindplane 代理要求打开防火墙端口
  • 对 Riverbed SteelHead 管理控制台的特权访问权限(具有管理员权限)

获取 Bindplane 代理的 Google SecOps 凭证

如需向 Google SecOps 验证 Bindplane 代理的身份,请选择以下方法之一:

  • 新部署:使用 Chronicle API(选项 1)。
  • 旧版部署:继续使用数据注入身份验证文件(方法 2),直到 Ingestion API 于 2027 年 7 月 20 日停用。
  1. 登录 Google Cloud 控制台,然后选择与您的 Google SecOps 实例关联的 Google Cloud 项目。
  2. 前往 IAM 和管理 > 服务账号。
  3. 点击创建服务账号。
  4. 提供以下配置详细信息:
    • 服务账号名称:输入账号的名称(例如 bindplane-ingest)。
    • 服务账号说明:输入说明(例如 Bindplane agent log ingestion)。
  5. 点击创建并继续。
  6. 在向此服务账号授予对项目的访问权限部分,点击选择角色,然后选择 Chronicle Editor。
  7. 点击继续,然后点击完成。
  8. 点击您创建的服务账号,然后前往密钥标签页。
  9. 依次点击添加密钥 > 创建新密钥。
  10. 选择 JSON,然后点击创建。密钥文件会下载到您的计算机上。
  11. 将密钥文件另存为 Bindplane 收集器目录(在 Linux 上为 /opt/observiq-otel-collector/ingestion-auth.json,在 Windows 上为 C:\Program Files\observIQ OpenTelemetry Collector\ingestion-auth.json)中的 ingestion-auth.json,或更新 config.yaml 中的 creds_file_path 以与您保存密钥文件的路径相匹配。
  12. 前往 IAM 和管理 > 设置,然后复制项目编号。您在配置导出器时需要用到该名称。

方法 2:下载数据注入身份验证文件(旧版)

  1. 登录 Google SecOps 控制台。
  2. 依次前往 SIEM 设置 > 收集代理。
  3. 下载数据注入身份验证文件。
  4. 将文件安全地保存在将要安装 Bindplane 代理的系统上。

获取 Google SecOps 客户 ID

  1. 登录 Google SecOps 控制台。
  2. 前往 SIEM 设置 > 个人资料。
  3. 复制并保存组织详细信息部分中的客户 ID。

安装 Bindplane 代理

根据以下说明,在 Windows 或 Linux 操作系统上安装 Bindplane 代理。

Windows 安装

  1. 以管理员身份打开命令提示符或 PowerShell。
  2. 运行以下命令:

    msiexec /i "https://github.com/observIQ/bindplane-agent/releases/latest/download/observiq-otel-collector.msi" /quiet
    
  3. 等待安装完成。

  4. 运行以下命令,验证安装是否成功:

    sc query observiq-otel-collector
    

    该服务应显示为 RUNNING。

Linux 安装

  1. 打开具有 root 或 sudo 权限的终端。
  2. 运行以下命令:

    sudo sh -c "$(curl -fsSlL https://github.com/observiq/bindplane-agent/releases/latest/download/install_unix.sh)" install_unix.sh
    
  3. 等待安装完成。

  4. 运行以下命令,验证安装是否成功:

    sudo systemctl status observiq-otel-collector
    

    该服务应显示为 active (running)。

其他安装资源

如需了解其他安装选项和问题排查信息,请参阅 Bindplane 代理安装指南。

配置 Bindplane 代理以注入 syslog 并将其发送到 Google SecOps

找到配置文件

  • Linux:

    sudo nano /opt/observiq-otel-collector/config.yaml
    
  • Windows:

    notepad "C:\Program Files\observIQ OpenTelemetry Collector\config.yaml"
    

修改配置文件

  • 将 config.yaml 的全部内容替换为以下配置:

    receivers:
      udplog:
        listen_address: "0.0.0.0:514"
    
    exporters:
      chronicle/steelhead:
        protocol: https
        # Region of your instance, for example us, europe, asia-southeast1
        location: <LOCATION>
        # Project number of the Google Cloud project linked to the instance
        project: '<PROJECT_NUMBER>'
        compression: gzip
        creds_file_path: '/opt/observiq-otel-collector/ingestion-auth.json'
        customer_id: '<customer_id>'
        endpoint: chronicle.googleapis.com
        log_type: STEELHEAD
        raw_log_field: body
    
    service:
      pipelines:
        logs/steelhead:
          receivers:
            - udplog
          exporters:
            - chronicle/steelhead
    

配置参数

替换以下占位符:

  • 接收器配置:

    • udplog:基于协议的接收器类型:
      • udplog(适用于 UDP syslog)
      • tcplog(适用于 TCP syslog)
      • 针对 RFC 3164/5424 syslog 的 syslog
    • 0.0.0.0:要监听的 IP 地址:
      • 0.0.0.0,以监听所有接口(推荐)
      • 要在一个接口上监听的特定 IP 地址
    • 514:要监听的端口号(例如 514、1514、6514)
  • 导出器配置:

    • <customer_id>:上一步中的客户 ID
    • location:将 <LOCATION> 替换为 Google SecOps 实例的区域(例如 us、europe 或 asia-southeast1)。导出器会使用此值作为 chronicle.googleapis.com 的前缀。如需查看完整列表,请参阅区域级端点。
    • project:将 <PROJECT_NUMBER> 替换为 IAM 和管理 > 设置中的项目编号。
    • endpoint:保持设置为 chronicle.googleapis.com。
    • 根据平台,将 creds_file_path 调整为服务账号 JSON 密钥文件的路径(选项 1):
      • Linux:/opt/observiq-otel-collector/ingestion-auth.json
      • Windows:C:\Program Files\observIQ OpenTelemetry Collector\ingestion-auth.json

旧版提取 API 导出工具

  • 如果您使用选项 2 中的数据注入身份验证文件,请将 exporters 代码块替换为以下内容。将 creds_file_path 设置为提取身份验证文件的路径,如果您的实例位于美国境外,请将 malachiteingestion-pa.googleapis.com 替换为您的区域端点(例如 europe-malachiteingestion-pa.googleapis.com)。

    exporters:
      chronicle/steelhead:
        compression: gzip
        creds_file_path: '/opt/observiq-otel-collector/ingestion-auth.json'
        customer_id: '<customer_id>'
        endpoint: malachiteingestion-pa.googleapis.com
        log_type: STEELHEAD
        raw_log_field: body
    

保存配置文件

  • 修改后,保存文件:
    • Linux:依次按 Ctrl+O、Enter 和 Ctrl+X
    • Windows:依次点击文件 > 保存

重启 Bindplane 代理以应用更改

  • 如需在 Linux 中重启 Bindplane 代理,请运行以下命令:

    sudo systemctl restart observiq-otel-collector
    
    1. 验证服务是否正在运行:

      sudo systemctl status observiq-otel-collector
      
    2. 检查日志中的错误:

      sudo journalctl -u observiq-otel-collector -f
      
  • 如需在 Windows 中重启 Bindplane 代理,请选择以下选项之一:

    • 以管理员身份运行命令提示符或 PowerShell:

      net stop observiq-otel-collector && net start observiq-otel-collector
      
    • 服务控制台:

      1. 按 Win+R,输入 services.msc,然后按 Enter 键。
      2. 找到 observIQ OpenTelemetry 收集器。
      3. 右键点击并选择重启。
      4. 验证服务是否正在运行:

        sc query observiq-otel-collector
        
      5. 检查日志中的错误:

        type "C:\Program Files\observIQ OpenTelemetry Collector\log\collector.log"
        

配置 Riverbed SteelHead syslog 转发

  1. 登录 SteelHead 管理控制台。
  2. 依次前往管理 > 系统设置 > 日志记录。
  3. 滚动到远程 Syslog 部分。
  4. 点击添加以添加新的远程 Syslog 服务器。
  5. 提供以下配置详细信息:
    • 服务器 IP 地址:输入 Bindplane 代理主机(例如 192.168.1.100)的 IP 地址。
    • 端口:输入 514(必须与 Bindplane 接收器端口一致)。
    • 协议:选择 UDP(必须与 Bindplane 接收器类型一致)。
  6. 点击应用。

UDM 映射表

日志字段 UDM 映射 逻辑
ephemeral_id_label, request_consumer_chain_label, sport_label, event_id_label, port_label, transport_label, sock_label, id_label, remote_inner_port_label, lport_label, rport_label, outer_lport_label, sfe_port_label, cfe_port_label, configuration_parameters_label, response_consumer_chain_label, client_connected_label, sportid_label, storeid_label, wan_tos_label, lan_tos_label, lan_classid_label, wan_classid_label, lan_classid_ingress_label, wan_classid_ingress_label, irm_region_label, irm_site_label, irm_environment_label, tag_labels additional.fields 合并自各种标签字段
auth_mechanism extensions.auth.mechanism 根据条件设置为“LOCAL”
extensions.auth.type 根据条件设置为“TACACS”或“AUTHTYPE_UNSPECIFIED”
host.architecture hardware.cpu_platform 设置为 host.architecture
中介、中介 3 中介 从 intermediary 和 intermediary3 合并
agent.type、agent.version intermediary.application 设置为“%{agent.type} %{agent.version}”
agent.type, agent.id intermediary.asset_id 设为“%{agent.type}: %{agent.id}”
agent.name, inter_hostname intermediary.hostname 如果 agent.name 不为空,则为 agent.name 的值,否则为 inter_hostname
@createTimestamp metadata.collected_timestamp 从 @createTimestamp 复制
descript、desc、description、netflow.tcp_control_flags metadata.description 如果 descript 不为空,则使用 descript 中的值;否则使用 desc 中的值;否则使用 description 中的值;否则设置为“TCP 控制标志:%{netflow.tcp_control_flags}”
ts, log_timestamp metadata.event_timestamp 如果存在,则从具有日期匹配的 ts 进行设置;否则,从具有日期匹配的 log_timestamp 进行设置
metadata.event_type 设置为“NETWORK_FLOW”,然后根据条件进行更改
logstash.ingest.timestamp metadata.ingested_timestamp 已使用 logstash.ingest.timestamp 中的日期匹配进行转换
event_data metadata.product_event_type 设为 event_data
log_id metadata.product_log_id 设置为 log_id
metadata.product_name 设置为“Steelhead”
metadata.vendor_name 设为“河床”
network.community_id network.community_id 设置为 network.community_id
network.direction network.direction 如果 network.direction 的值为 [BROADCAST, INBOUND, OUTBOUND],则将其设置为大写
response_code network.http.response_code 从 response_code 转换为整数
network.transport network.ip_protocol 如果不是 UNKNOWN,则设置为大写 network.transport
network.bytes network.sent_bytes 从 network.bytes 转换为 uinteger
logstash.collect.host observer.hostname 如果不是 IP,则设置为 logstash.collect.host
observer.ip、collect_ip observer.ip 来自 observer.ip 的值,如果 logstash.collect.host 为 IP,则与 collect_ip 合并
observer.port observer.port 从 observer.port 转换为整数
source.ip、log.source.address、src_ip、cfe_ip、principal_user principal.asset.ip 从各种 IP 来源合并
source.ip、log.source.address、src_ip、cfe_ip、principal_user principal.ip 从各种 IP 来源合并
src_mac principal.mac 设为 src_mac
source.port, src_port principal.port 从 source.port 或 src_port 转换为整数
cmd_line principal.process.command_line 设为 cmd_line
user_name principal.user.email_addresses 如果与电子邮件格式匹配,则设置为 user_name
user_name principal.user.user_display_name 如果不符合电子邮件格式,则设置为 user_name
userid principal.user.userid 设置为 userid
security_result security_result 从 security_result 合并
event.category security_result.category_details 从 event.category 数组合并而来
sec_description security_result.description 设置为 sec_description
syslog_severity security_result.severity 如果匹配 (?i)(DEFAULT|DEBUG|INFO|NOTICE),则设置为 INFORMATIONAL;如果匹配 (?i)ERROR,则设置为 ERROR;如果匹配 (?i)WARNING,则设置为 MEDIUM;如果匹配 (?i)(CRITICAL|ALERT|EMERGENCY),则设置为 HIGH
syslog_severity security_result.severity_details 设为 syslog_severity
硬件 target.asset.hardware 从硬件合并
主机名、host.hostname target.asset.hostname hostname 的值(如果不为空),否则为 host.hostname
destination.ip、target_ip、sfe_ip、ips target.asset.ip 从 destination.ip、target_ip、sfe_ip 和 host.ip 数组合并而来
host.id target.asset_id 设置为“Host Id: %{host.id}”
hostname, host.hostname target.hostname 如果主机名不为空,则为来自主机名的值;否则为 host.hostname
destination.ip、target_ip、sfe_ip、ips target.ip 从 destination.ip、target_ip、sfe_ip 和 host.ip 数组合并
target_mac, macs target.mac 从 target_mac 和 host.mac 数组合并而来
host.os.platform target.platform 如果 host.os.platform 与 (?i)centos 匹配,则设置为“LINUX”,否则设置为大写的 host.os.platform
host.os.kernel target.platform_patch_level 设置为 host.os.kernel
host.os.version target.platform_version 设置为 host.os.version
destination.port、target_port target.port 从 destination.port 或 target_port 转换为整数
uri target.url 设置为 URI
target_user target.user.userid 设置为 target_user
ts event.idm.read_only_udm.metadata.event_timestamp 从更新日志映射
desc event.idm.read_only_udm.metadata.description 从更新日志映射
target_user event.idm.read_only_udm.target.user.userid 从更新日志映射
principal_ip event.idm.read_only_udm.principal.ip 从更新日志映射

更新日志

查看此解析器的更新日志

需要更多帮助?获得社区成员和 Google SecOps 专业人士的解答。