Files
sigma-rules/rules/linux/execution_interpreter_tty_upgrade.toml
T
Ruben Groenewoud 9f41c9f35c [New Rule] Upgrade of Non-interactive Shell (#3113)
* [New Rule] Upgrade of Non-interactive Shell

* Changed numbers to int

* Changed severity

* [New Rule] Pot. Rev Shell via Background Process

* Revert "[New Rule] Pot. Rev Shell via Background Process"

This reverts commit bbb36eae26561dbef4bf57f6c1388cebe7a8b88d.

* Update rules/linux/execution_interpreter_tty_upgrade.toml
2023-10-18 16:47:07 +02:00

58 lines
1.8 KiB
TOML

[metadata]
creation_date = "2023/09/20"
integration = ["endpoint"]
maturity = "production"
updated_date = "2023/09/20"
min_stack_comments = "New fields added: required_fields, related_integrations, setup"
min_stack_version = "8.3.0"
[rule]
author = ["Elastic"]
description = """
Identifies when a non-interactive terminal (tty) is being upgraded to a fully interactive shell. Attackers may upgrade
a simple reverse shell to a fully interactive tty after obtaining initial access to a host, in order to obtain a more
stable connection.
"""
from = "now-9m"
index = ["logs-endpoint.events.*", "endgame-*"]
language = "eql"
license = "Elastic License v2"
name = "Potential Upgrade of Non-interactive Shell"
risk_score = 47
rule_id = "84d1f8db-207f-45ab-a578-921d91c23eb2"
severity = "medium"
timestamp_override = "event.ingested"
tags = ["Domain: Endpoint",
"OS: Linux",
"Use Case: Threat Detection",
"Tactic: Execution",
"Data Source: Elastic Endgame",
"Data Source: Elastic Defend"
]
type = "eql"
query = '''
process where host.os.type == "linux" and event.action in ("exec", "exec_event") and event.type == "start" and (
(process.name == "stty" and process.args == "raw" and process.args == "-echo" and process.args_count >= 3) or
(process.name == "script" and process.args in ("-qc", "-c") and process.args == "/dev/null" and
process.args_count == 4)
)
'''
[[rule.threat]]
framework = "MITRE ATT&CK"
[[rule.threat.technique]]
id = "T1059"
name = "Command and Scripting Interpreter"
reference = "https://attack.mitre.org/techniques/T1059/"
[[rule.threat.technique.subtechnique]]
id = "T1059.004"
name = "Unix Shell"
reference = "https://attack.mitre.org/techniques/T1059/004/"
[rule.threat.tactic]
id = "TA0002"
name = "Execution"
reference = "https://attack.mitre.org/tactics/TA0002/"