收集 Vectra Stream 日志

支持:

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

Vectra Stream 是一个网络元数据流式传输平台,可为网络连接、DNS 查询、HTTP 请求、TLS/SSL 会话、DHCP 租约、RADIUS 身份验证、SMTP 邮件和 Kerberos 事件生成 JSON 和 syslog 格式的消息。解析器会提取键值对,并将其映射到统一数据模型 (UDM)。

准备工作

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

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

获取 Bindplane 代理的 Google SecOps 凭证

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

  • 新部署:使用 Chronicle API(选项 1)。
  • 旧版部署:继续使用提取身份验证文件(方法 2),直到提取 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
    

    该服务应显示为正在运行。

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
    

    该服务应显示为有效(正在运行)。

其他安装资源

如需了解其他安装选项和问题排查信息,请参阅 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/vectra_stream:
        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: VECTRA_STREAM
        raw_log_field: body
    
    service:
      pipelines:
        logs/vectra_stream_to_chronicle:
          receivers:
            - udplog
          exporters:
            - chronicle/vectra_stream
    

配置参数

替换以下占位符:

  • 接收器配置:

    • listen_address:要监听的 IP 地址和端口:
      • 0.0.0.0,以监听所有接口(推荐)
      • 端口 514 是标准 syslog 端口(在 Linux 上需要 root 权限;对于非 root 用户,请使用 1514)
  • 导出器配置:

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

旧版提取 API

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

    exporters:
      chronicle/vectra_stream:
        compression: gzip
        creds_file_path: '/opt/observiq-otel-collector/ingestion-auth.json'
        customer_id: '<customer_id>'
        endpoint: malachiteingestion-pa.googleapis.com
        log_type: VECTRA_STREAM
        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"
        

配置 Vectra Stream 以发送 Syslog

  1. 登录 Vectra (brain) 界面。
  2. 前往设置 > 通知。
  3. 前往 Syslog 部分。
  4. 点击修改以添加或修改 syslog 配置。
  5. 提供以下配置详细信息:
    • 目标:输入 Bindplane 代理 IP 地址。
    • 端口:输入 Bindplane 代理端口号。
    • 协议:根据您的 Bindplane 代理配置选择 UDP 或 TCP。
    • 格式:选择 JSON。
    • 日志类型:选择要发送到 Google SecOps 的日志。
  6. 点击保存。
  7. 点击测试以测试配置。

UDM 映射表

日志字段 UDM 映射 逻辑
AA network.dns.authoritative 从字符串值转换为布尔值。
account_session_id network.session_id 直接映射。
account_session_time network.session_duration 从 UNIX 秒转换为时间戳。
answers network.dns.answers.data 直接映射。
assigned_ip network.dhcp.yiaddr 直接映射。
beacon_type metadata.description 直接映射。
beacon_uid network.session_id 直接映射。
calling_station_id intermediary.asset.product_object_id 直接映射。
certificate.issuer network.tls.client.certificate.issuer 直接映射。
certificate.not_valid_after network.tls.client.certificate.not_after 根据格式,从 UNIX 或 UNIX_MS 转换为时间戳。
certificate.not_valid_before network.tls.client.certificate.not_before 根据格式从 UNIX 或 UNIX_MS 转换为时间戳。
certificate.serial network.tls.client.certificate.serial 直接映射。
certificate.subject network.tls.client.certificate.subject 直接映射。
certificate.version network.tls.client.certificate.version 直接映射。
cipher network.tls.cipher 直接映射。
cipher_alg network.tls.cipher 直接映射。
client principal.application 直接映射。
client_cipher network.tls.client.supported_ciphers 直接映射。
community_id network.community_id 直接映射。
compression_alg additional.fields.value.string_value 添加到键为“compression_alg”的其他字段。
connect_info security_result.description 直接映射。
conn_state metadata.description 根据 conn_state 的值映射到说明。
cookie target.user.userid 直接映射。
curve network.tls.curve 直接映射。
dhcp_server_ip network.dhcp.giaddr 直接映射。
dns_server_ips principal.ip 数组中的每个 IP 都会添加到 principal.ip 数组中。
domain target.domain.name 直接映射。
dst_display_name target.hostname,,target.asset.hostname 直接映射。
dst_luid target.asset.product_object_id 直接映射。
duration network.session_duration.seconds 从字符串值转换为整数。
endpoint principal.application 直接映射。
established network.tls.established 从字符串值转换为布尔值。
host target.hostname,,target.asset.hostname 从“host”字段中提取了主机名。
host_key additional.fields.value.string_value 已添加到键为“host_key”的其他字段。
host_key_alg additional.fields.value.string_value 已添加到键为“host_key_alg”的其他字段。
host_multihomed additional.fields.value.string_value 已添加到其他字段,键为“host_multihomed”,值为“subnet %{host_multihomed}”。
hostname target.hostname,,target.asset.hostname 直接映射。
id.orig_h principal.ip 直接映射。
id.orig_p principal.port 从字符串值转换为整数。
id.resp_h target.ip,,target.asset.ip 直接映射。
id.resp_p target.port 从字符串值转换为整数。
issuer network.tls.client.certificate.issuer 直接映射。
ja3 network.tls.client.ja3 直接映射。
ja3s network.tls.server.ja3s 直接映射。
kex_alg additional.fields.value.string_value 已添加到键为“kex_alg”的其他字段。
lease_time network.dhcp.lease_time_seconds 从字符串值转换为无符号整数。
log_type metadata.log_type 直接映射。
mac principal.mac 直接映射。
mac_alg additional.fields.value.string_value 添加到键为“mac_alg”的其他字段。
mail_from network.email.from 直接映射。
metadata_type metadata.product_event_type 直接映射。
method network.http.method 直接映射。
name target.file.full_path 直接映射。
nas_identifier target.user.attribute.roles.name 直接映射。
next_protocol network.tls.next_protocol 直接映射。
orig_hostname principal.hostname 直接映射。
orig_ip_bytes network.sent_bytes 从字符串值转换为无符号整数。
orig_sluid principal.hostname 直接映射。
path target.file.full_path 直接映射。
proto network.ip_protocol 根据数值映射到 IP 协议名称。
proxied principal.ip 如果该值是 IP 地址,则会添加到 principal.ip 数组中。
qclass network.dns.questions.class 从字符串值转换为无符号整数。
qclass_name network.dns.questions.name 直接映射。
query network.dns.questions.name,,principal.process.command_line 直接映射。
qtype network.dns.questions.type 从字符串值转换为无符号整数。
RA network.dns.recursion_available 从字符串值转换为布尔值。
radius_type metadata.description 直接映射。
rcode network.dns.response_code 从字符串值转换为无符号整数。
RD network.dns.recursion_desired 从字符串值转换为布尔值。
rcpt_to network.email.reply_to,,network.email.to 第一个电子邮件地址会映射到 reply_to,其余地址会添加到 to 数组。
referrer network.http.referral_url 直接映射。
resp_domain target.domain.name 直接映射。
resp_hostname target.hostname,,target.asset.hostname 直接映射。
resp_ip_bytes network.received_bytes 从字符串值转换为无符号整数。
resp_mime_types target.file.mime_type 直接映射。
result security_result.description 直接映射。
result_code security_result.action_details 直接映射。
rtt network.session_duration.seconds 已从字符串值转换为整数。
security_result security_result 已与现有 security_result 对象合并。
sensor_uid observer.asset_id 格式为“Sensor_UID:%{sensor_uid}”。
server target.application 直接映射。
server_name network.tls.client.server_name 直接映射。
service target.application 直接映射。
src_display_name principal.hostname 直接映射。
src_luid principal.asset.product_object_id 直接映射。
status security_result.summary 直接映射。
status_code network.http.response_code 从字符串值转换为整数。
status_msg security_result.summary 直接映射。
subject network.email.subject 直接映射。
success security_result.action 如果为 true,则映射到“ALLOW”;如果为 false,则映射到“BLOCK”。
TC network.dns.truncated 从字符串值转换为布尔值。
trans_id network.dhcp.transaction_id,,network.dns.id 从字符串值转换为无符号整数。
ts metadata.event_timestamp 从各种格式转换为时间戳。
uid metadata.product_log_id 直接映射。
uri target.url 直接映射。
user_agent network.http.user_agent 直接映射。
username principal.user.userid 直接映射。
version network.tls.version,,principal.platform_version 直接映射。
version_num network.tls.version_protocol 直接映射。
metadata.event_type 由解析器逻辑根据日志和元数据类型确定。
metadata.vendor_name 硬编码值:“Vectra”。
metadata.product_name 硬编码值:“Vectra Stream”。
eve_json.alert.signature security_result.summary 从更新日志映射
eve_json.alert.category security_result.category_details 从更新日志映射
eve_json.alert.metadata.signature_severity security_result.severity 从更新日志映射
eve_json.alert.gid target.group.product_object_id 从更新日志映射
eve_json.alert.metadata.confidence security_result.confidence 从更新日志映射
eve_json.dest_ip" and "eve_json.flow.dest_ip target.ip 从更新日志映射
eve_json.dest_port" and "eve_json.flow.dest_port target.port 从更新日志映射
rrname dns.questions.name 从更新日志映射
eve_json.flow.bytes_toclient network.sent_bytes 从更新日志映射
eve_json.flow.bytes_toserver network.received_bytes 从更新日志映射
eve_json.flow.src_ip" and "eve_json.src_ip principal.ip 从更新日志映射
eve_json.flow.src_port" and "eve_json.src_port principal.port 从更新日志映射
idorig_h principal.ip 从更新日志映射
idorig_p principal.port 从更新日志映射
attributes additional.fields 从更新日志映射
first_orig_resp_data_pkt", "first_orig_resp_data_pkt_time", "cookie", "keyboard_layout", "name", and "query_scope additional.fields 从更新日志映射
operation security_result.action_details 从更新日志映射
qclass_name question.name 从更新日志映射

更新日志

查看此解析器的更新日志

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