Detection rules › YARA-L

sap data changed during debugging

Severity
critical
Time window
30m
Match by
session_owner
Author
Google Cloud Security
Source
github.com/chronicle/detection-rules

Detects in-memory data changes (CUL) during an ABAP debugging session. Identifies if the debugger is the same as the session owner.

MITRE ATT&CK coverage

TacticTechniques
StealthT1564 Hide Artifacts

Rule body yaral

/*
 * Copyright 2026 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 sap_data_changed_during_debugging {

  meta:
    author = "Google Cloud Security"
    description = "Detects in-memory data changes (CUL) during an ABAP debugging session. Identifies if the debugger is the same as the session owner."
    severity = "Critical"
    tactic = "TA0005"
    technique = "T1564"

  events:
    $e.metadata.log_type = "SAP_SECURITY_AUDIT"

    $e.additional.fields["msg_1"] = "CUL"

    $debugger = $e.additional.fields["param1_1"]
    $session_owner = $e.principal.user.userid

    // exclusions
    not $debugger in %sap_admin_users.user

  match:
    $session_owner over 30m

  outcome:
    $risk_score = 90
    $target_sid = array_distinct($e.target.application)
    $debugging_user = array_distinct($debugger)
    $source_user = array_distinct($session_owner)

    $source_user_is_debugger = array_distinct(if($debugger = $session_owner, "true", "false"))

    $change_field = array_distinct($e.additional.fields["param2_1"])
    $change = array_distinct($e.additional.fields["param3_1"])
    $method = array_distinct(re.capture($e.additional.fields["paramx_1"], `Meth:(.*?),\s`))

  condition:
    $e
}

Detection logic

Fires when at least one $e event in the 30m window.

Events

$e

  • metadata.log_type = "SAP_SECURITY_AUDIT"
  • additional.fields["msg_1"] = "CUL"
  • additional.fields["param1_1"] in "%sap_admin_users.user"

Correlation

Match key
$session_owner
Within
30m

Outcome

Fields the detection emits on a match. $risk_score drives alerting; Chronicle surfaces the rest on the detection.

FieldExpression
risk_score90
target_sidarray_distinct($e.target.application)
debugging_userarray_distinct($debugger)
source_userarray_distinct($session_owner)
source_user_is_debuggerarray_distinct(if($debugger = $session_owner, "true", "false"))
change_fieldarray_distinct($e.additional.fields["param2_1"])
changearray_distinct($e.additional.fields["param3_1"])
methodarray_distinct(re.capture($e.additional.fields["paramx_1"], `Meth:(.*?),\s`))