收集 VMware vCenter 日志

支持的语言:

本文档介绍了如何使用 Bindplane 将 VMware vCenter 日志注入到 Google Security Operations。解析器会将原始日志转换为统一数据模型 (UDM)。它首先尝试将日志数据解析为 JSON,如果失败,则将数据视为 syslog 消息,使用 grok 模式提取字段并将其映射到 UDM 架构。

准备工作

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

  • Google SecOps 实例
  • Windows 2016 或更高版本,或者具有 systemd 的 Linux 主机
  • 如果通过代理运行,请确保防火墙端口处于开放状态
  • 对 VMware vCenter 的特权访问

获取 Google SecOps 注入身份验证文件

  1. 登录 Google SecOps 控制台。
  2. 依次前往 SIEM 设置 > 收集代理
  3. 下载注入身份验证文件。将该文件安全地保存在将要安装 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
    

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
    

其他安装资源

如需了解其他安装选项,请参阅安装指南

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

  1. 访问配置文件:
    • 找到 config.yaml 文件。通常,它位于 Linux 上的 /etc/bindplane-agent/ 目录中或 Windows 上的安装目录中。
    • 使用文本编辑器(例如 nanovi 或记事本)打开该文件。
  2. 按如下方式修改 config.yaml 文件:

    receivers:
        udplog:
            # Replace the port and IP address as required
            listen_address: "0.0.0.0:514"
    
    exporters:
        chronicle/chronicle_w_labels:
            compression: gzip
            # Adjust the path to the credentials file you downloaded in Step 1
            creds_file_path: '/path/to/ingestion-authentication-file.json'
            # Replace with your actual customer ID from Step 2
            customer_id: <customer_id>
            endpoint: malachiteingestion-pa.googleapis.com
            # Add optional ingestion labels for better organization
            log_type: 'VMWARE_VCENTER'
            raw_log_field: body
            ingestion_labels:
    
    service:
        pipelines:
            logs/source0__chronicle_w_labels-0:
                receivers:
                    - udplog
                exporters:
                    - chronicle/chronicle_w_labels
    
    • 根据基础架构的需要替换端口和 IP 地址。
    • <customer_id> 替换为实际的客户 ID。
    • /path/to/ingestion-authentication-file.json 更新为获取 Google SecOps 提取身份验证文件部分中保存身份验证文件的路径。

重启 Bindplane 代理以应用更改

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

    sudo systemctl restart bindplane-agent
    
  • 如需在 Windows 中重启 Bindplane 代理,您可以使用服务控制台,也可以输入以下命令:

    net stop BindPlaneAgent && net start BindPlaneAgent
    

为 VMware vCenter 配置 Syslog

  1. 登录 vCenter Server 管理 Web 界面。
  2. 依次前往 Syslog > Forwarding Configuration > Configure
  3. 选择创建转发配置,然后输入 Bindplane 代理 IP 地址。
  4. 协议下拉菜单中,根据实际的 Bindplane 代理配置选择 UDPTCP
  5. 端口部分,输入 Bindplane 代理端口号。
  6. 点击保存
  7. 点击发送测试消息,然后验证是否已收到该消息。

UDM 映射表

日志字段 UDM 映射 逻辑
Access Mask principal.process.access_mask 从十六进制转换为十进制。
Account Domain principal.administrative_domain
Account Name principal.user.userid
ApplicationProtocol additional.fields
Authentication Package security_result.about.resource.name
Client Address principal.ip、principal.asset.ip 解析为 IP。
Client Port principal.port 已转换为整数。
cmd target.process.command_line
date 时间戳 解析为 yyyy-MM-dd,并与时间合并为 yyyy-MM-dd HH:mm:ss,以作为日期进行解析。
date_time 时间戳 解析为采用 RFC 3339、TIMESTAMP_ISO8601、SYSLOGTIMESTAMP 格式的日期。
desc metadata.description
eventid metadata.product_event_type 与任务合并,作为 eventid - task。
host_name principal.hostname、principal.asset.hostname
http_method network.http.method
ip target.ip、target.asset.ip
kv_data1 解析为键值对。
kv_data2 解析为键值对。
kv_msg1.cipher network.tls.cipher
kv_msg1.ctladdr intermediary.labels
kv_msg1.daemon security_result.about.labels
kv_msg1.from network.email.from 如果 mail_from 不包含 @,则附加 @local。
kv_msg1.msgid network.email.mail_id
kv_msg1.proto security_result.about.labels
kv_msg1.relay intermediary.hostname、intermediary.ip 是否解析为 (HOSTNAME)?[IP] 或 HOSTNAME,如果存在 relay_domain,则设置为 intermediary.hostname;如果存在 relay_ip,则合并到 intermediary.ip。
kv_msg1.size network.sent_bytes 转换为无符号整数。
kv_msg1.stat security_result.summary
kv_msg1.verify security_result.description, security_result.action 如果 kv_msg1.verify 为 FAIL,则将 security_result.action 设置为 BLOCK。
kv_msg1.version network.tls.version
labels.log_type metadata.product_event_type
labels.net.host.ip principal.ip、principal.asset.ip
labels.net.host.port principal.port
labels.net.peer.ip target.ip、target.asset.ip
labels.net.peer.port target.port
labels.net.transport network.ip_protocol 如果 labels.net.transport 为 TCP,则为 TCP。
level security_result.severity 如果级别为 INFO/Informational/DEBUG/info/Information,则为 INFORMATIONAL;如果级别为 ERROR/error,则为 ERROR;如果级别为 WARNING,则为 LOW。
log.file.path target.process.file.full_path
logName security_result.category_details
Logon Account principal.user.userid
Logon Type extensions.auth.mechanism 如果 logon_type 为 2/Interactive,则为 INTERACTIVE;如果 logon_type 为 3/8,则为 NETWORK;如果 logon_type 为 4,则为 BATCH;如果 logon_type 为 5,则为 SERVICE;如果 logon_type 为 7,则为 UNLOCK;如果 logon_type 为 9,则为 NEW_CREDENTIALS;如果 logon_type 为 10,则为 REMOTE_INTERACTIVE;如果 logon_type 为 11,则为 CACHED_INTERACTIVE;否则为 MECHANISM_UNSPECIFIED。
mail_from network.email.from 如果 mail_from 不包含 @,则附加 @local。
mail_to network.email.to 如果 mail_to 不包含 @,则附加 @local。
message 使用 grok 模式进行解析。
namespace principal.namespace
port target.port 已转换为整数。
process_id target.process.pid
providername principal.application
Relative Target Name target.file.full_path
resource.labels.project_id src.cloud.project.id
resource.type src.labels
response_status network.http.response_code 已转换为整数。
sec_desc security_result.description
Security ID target.user.windows_sid
security_result_action_detail security_result.action_details
server_name target.hostname、target.asset.hostname
Share Name target.resource.name
Source Network Address principal.ip、principal.asset.ip 解析为 IP。
Source Port principal.port 已转换为整数。
summary security_result.summary
target_host target.hostname、target.asset.hostname
target_url target.url
target_userid target.user.userid
time 时间戳 解析为 HH:mm:ss,并与日期合并为 yyyy-MM-dd HH:mm:ss,解析为日期。
upn_name intermediary.url
URL target.url
User ID target.user.windows_sid
user_id principal.user.userid
UserAgent network.http.user_agent
metadata.event_type 如果消息包含 API_HEALTH 或 JobDispatcher,则设置为 STATUS_UPDATE;如果消息包含“logged in as”且 target_userid 不为空,则设置为 USER_LOGIN;如果消息包含“Leave Validate”,则设置为 SCAN_HOST;如果消息包含“Getting IP Address from host”,则设置为 NETWORK_UNCATEGORIZED;如果消息包含“Wrote vpxd health”,则设置为 RESOURCE_WRITTEN;如果 has_principal 和 has_target 为 true 且 application_protocol 不为空,则设置为 NETWORK_HTTP;如果 process_id 和 cmd 不为空,则设置为 PROCESS_LAUNCH;如果 user_id 不为空或 eventid 为 4776,则设置为 USER_UNCATEGORIZED;如果 eventid 为 4624/4768/4769,则设置为 USER_LOGIN;如果 eventid 为 4634/4647,则设置为 USER_LOGOUT;如果 eventid 为 5145,则设置为 USER_RESOURCE_ACCESS;如果 host_name 不为空,则设置为 STATUS_UPDATE;否则设置为 GENERIC_EVENT。
extensions.auth.type 如果 eventid 为 4624/4768/4769,则设置为 MACHINE。
metadata.log_type 设置为 VMWARE_VCENTER。
metadata.vendor_name 设置为 VMWARE。
metadata.product_name 设置为 VCENTER。
security_result.action 如果 response_status 为 200 或 action 为“允许”,则设置为 ALLOW。

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