Google Chronicle low experimental yara-l

Hunt for Office 365 group creation success

Detects when a group is created in Office 365.

View Source

Detection Logic

/*
 * Copyright 2025 Google LLC
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     https://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES 
OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

rule o365_group_creation_success {

  meta:
    author = "Google Cloud Security"
    description = "Detects when a group is created in Office 365."
    rule_id = "mr_d35822fd-c121-46eb-a232-772f8c1290bd"
    rule_name = "Hunt for Office 365 group creation success"
    type = "hunt"
    platform = "azure"
    data_source = "o365"
    severity = "Low"
    priority = "Low"

  events:
    $group.metadata.event_type = "GROUP_CREATION"
    $group.metadata.product_event_type = "Add group."
    $group.metadata.product_name = "Office 365"
    $group.metadata.vendor_name = "Microsoft"
    $group.security_result.action = "ALLOW"
    $group.principal.user.userid = $user

  match:
    $user over 5m

  outcome:
    $risk_score = 35
    $event_count = count_distinct($group.metadata.id)
    $user_agent = array_distinct($group.network.http.user_agent)
    $security_summary = array_distinct($group.security_result.summary)
    $target_application = array_distinct($group.target.application)
    //$principal_user_userid = array_distinct($group.principal.user.userid)
    $group_name = array_distinct($group.target.group.group_display_name)
    $group_guid = array_distinct(re.replace($group.security_result.detection_fields["target_2"], `^Group_`, ""))

  condition:
    $group
}

Field Validations

Loading…

Comments (0)

Loading comments...