Google Cloud Platform log format and field mapping

Prev Next

There are multiple log categories each with different fields. Google Workspace audit log entries include the following objects:

  • logName contains the organization ID and audit log type.

  • resource contains the target of the audited operation.

  • timeStamp contains the time of the audited operation.

  • protoPayload contains the Google Workspace audit log in its metadata field. The protoPayload.metadata field holds the audited Google Workspace information.

Log sample

The following is an example of a Login Audit log:

{
  "protoPayload": {
    "@type": "type.googleapis.com/google.cloud.audit.AuditLog",
    "authenticationInfo": {
      "principalEmail": "test-user@example.net"
    },
    "requestMetadata": {
      "callerIp": "2001:db8:ffff:ffff:ffff:ffff:ffff:ffff",
      "requestAttributes": {},
      "destinationAttributes": {}
    },
    "serviceName": "login.googleapis.com",
    "methodName": "google.login.LoginService.loginFailure",
    "resourceName": "organizations/123",
    "metadata": {
      "event": [
        {
          "eventName": "login_failure",
          "eventType": "login",
          "parameter": [
            {
              "value": "google_password",
              "type": "TYPE_STRING",
              "name": "login_type",
            },
            {
              "name": "login_challenge_method",
              "type": "TYPE_STRING",
              "label": "LABEL_REPEATED",
              "multiStrValue": [
                "password",
                "idv_preregistered_phone",
                "idv_preregistered_phone"
              ]
            },
          ]
        }
      ],
      "activityId": {
        "uniqQualifier": "358068855354",
        "timeUsec": "1632500217183212"
      },
      "@type": "type.googleapis.com/ccc_hosted_reporting.ActivityProto"
    }
  },
  "insertId": "-nahbepd4l1x",
  "resource": {
    "type": "audited_resource",
    "labels": {
      "method": "google.login.LoginService.loginFailure",
      "service": "login.googleapis.com"
    }
  },
  "timestamp": "2021-09-24T16:16:57.183212Z",
  "severity": "NOTICE",
  "logName": "organizations/123/logs/cloudaudit.googleapis.com%2Fdata_access",
  "receiveTimestamp": "2021-09-24T17:51:25.034361197Z"
}

Field mapping

Field mappings might vary based on the category or type of log. Some field mapping examples are listed below.

Log fields

Trellix ESM fields

protoPayload.status.code

action

timestamp

firsttime, lasttime

host

HostID

protoPayload.authenticationInfo.principalEmail

HostID

protoPayload.status.message

Message_Text

protoPayload.@type

Message_Text

severity

severity

protoPayload.authorizationInfo.0.permissionType

Privileges

protoPayload.requestMetadata.callerIp

src_ip

protoPayload.serviceName

Service_Name

protoPayload.methodName

Method

protoPayload.resourceName

Source_Context

protoPayload.requestMetadata.callerSuppliedUserAgent

User_Agent

protoPayload.authenticationInfo.principalEmail

UserIDSrc