sap_ftp_session_to_unapproved_host


Description

An SAP process opened an FTP session to a host absent from the approved server list

Query · yara_l

events:
    $e.metadata.log_type = "SAP_SECURITY_AUDIT"
    $e.additional.fields["msg_1"] = "DU8"
    $e.principal.user.userid != ""
    $e.additional.fields["param1_1"] != ""

    not $e.additional.fields["param1_1"] in %sap_ftp_safe_servers.FTP_Server_Name

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

  match:
    $system_id, $user over 30m

  outcome:
    $instance = array_distinct($e.target.resource.name)
    $client_id = array_distinct($e.target.resource.attribute.labels["slgmand_1"])
    $ftp_server = array_distinct($e.additional.fields["param1_1"])
    $host = array_distinct($e.principal.hostname)
    $email = array_distinct($e.additional.fields["smtp_addr_1"])
    $reason = array_distinct($e.metadata.description)
    $risk_score = 60

  condition:
    $e
Raw source sap_ftp_session_to_unapproved_host · YARA-L
Esc
Published by chronicle/detection-rules ↗, licensed under Apache 2.0 ↗. Reproduced here unmodified.
rule sap_ftp_session_to_unapproved_host {

  meta:
    author = "Google Cloud Security"
    description = "An SAP process opened an FTP session to a host absent from the approved server list"
    severity = "medium"
    tactic = "TA0011"
    technique = "T1071.002"

  events:
    $e.metadata.log_type = "SAP_SECURITY_AUDIT"
    $e.additional.fields["msg_1"] = "DU8"
    $e.principal.user.userid != ""
    $e.additional.fields["param1_1"] != ""

    not $e.additional.fields["param1_1"] in %sap_ftp_safe_servers.FTP_Server_Name

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

  match:
    $system_id, $user over 30m

  outcome:
    $instance = array_distinct($e.target.resource.name)
    $client_id = array_distinct($e.target.resource.attribute.labels["slgmand_1"])
    $ftp_server = array_distinct($e.additional.fields["param1_1"])
    $host = array_distinct($e.principal.hostname)
    $email = array_distinct($e.additional.fields["smtp_addr_1"])
    $reason = array_distinct($e.metadata.description)
    $risk_score = 60

  condition:
    $e
}

Detection rules belong to the projects that publish them and remain under their own licenses. This site indexes and links to them; it claims no rights in them.