Detection rules › YARA-L

sap deactivation of security audit log

Severity
critical
Time window
1h
Match by
sid
Author
Google Cloud Security
Source
github.com/chronicle/detection-rules

Detects the deactivation of the SAP Security Audit Log (AUJ). This is a critical event as it stops further security logging.

MITRE ATT&CK coverage

TacticTechniques
Defense Impairment

Rule body

// Copyright 2026 Google LLC. Licensed under Apache-2.0.

rule sap_deactivation_of_security_audit_log {
  meta:
    author = "Google Cloud Security"
    description = "Detects the deactivation of the SAP Security Audit Log (AUJ). This is a critical event as it stops further security logging."
    severity = "Critical"
    tactic = "TA0005"
    technique = "T1562"

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

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

    $e.additional.fields["param1_1"] = "0"

    $sid = $e.target.application
    $user = $e.principal.user.userid

  match:
    $sid over 1h

  outcome:
    $risk_score = 95
    $source_user = array_distinct($user)
    $terminal_ip = array_distinct($e.principal.ip)
    $target_sid = array_distinct($sid)
    $client = array_distinct($e.target.resource.attribute.labels["slgmand_1"])
    $instance = array_distinct($e.target.resource.name)
    $report_name = array_distinct($e.principal.process.file.names)
    $log_description = array_distinct($e.metadata.description)

  condition:
    $e
}

YARA-L rule structure

Condition

Fires when at least one $e event in the 1h window.

Events

$e

  • metadata.log_type = "SAP_SECURITY_AUDIT"
  • additional.fields["msg_1"] = "AUJ"
  • additional.fields["param1_1"] = "0"

Match and correlation

Match key
$sid
Within
1h

Outcome

Outcome variables add context to a detection. When the rule generates an alert, $risk_score is displayed with it.

FieldExpression
risk_score95
source_userarray_distinct($user)
terminal_iparray_distinct($e.principal.ip)
target_sidarray_distinct($sid)
clientarray_distinct($e.target.resource.attribute.labels["slgmand_1"])
instancearray_distinct($e.target.resource.name)
report_namearray_distinct($e.principal.process.file.names)
log_descriptionarray_distinct($e.metadata.description)