55 lines
1.6 KiB
TOML
55 lines
1.6 KiB
TOML
[metadata]
|
|
creation_date = "2020/04/21"
|
|
integration = ["endpoint"]
|
|
maturity = "production"
|
|
min_stack_comments = "New fields added: required_fields, related_integrations, setup"
|
|
min_stack_version = "8.3.0"
|
|
updated_date = "2023/07/25"
|
|
|
|
[rule]
|
|
author = ["Elastic"]
|
|
description = """
|
|
Identifies file permission modifications in common writable directories by a non-root user. Adversaries often drop files
|
|
or payloads into a writable directory and change permissions prior to execution.
|
|
"""
|
|
false_positives = [
|
|
"""
|
|
Certain programs or applications may modify files or change ownership in writable directories. These can be exempted
|
|
by username.
|
|
""",
|
|
]
|
|
from = "now-9m"
|
|
index = ["auditbeat-*", "logs-endpoint.events.*"]
|
|
language = "eql"
|
|
license = "Elastic License v2"
|
|
name = "File Permission Modification in Writable Directory"
|
|
risk_score = 21
|
|
rule_id = "9f9a2a82-93a8-4b1a-8778-1780895626d4"
|
|
severity = "low"
|
|
tags = ["Domain: Endpoint", "OS: Linux", "Use Case: Threat Detection", "Tactic: Defense Evasion"]
|
|
timestamp_override = "event.ingested"
|
|
type = "eql"
|
|
|
|
query = '''
|
|
process where host.os.type == "linux" and event.type == "start"and
|
|
process.name in ("chmod", "chown", "chattr", "chgrp") and
|
|
process.working_directory in ("/tmp", "/var/tmp", "/dev/shm") and
|
|
not process.parent.name in ("update-motd-updates-available") and
|
|
not user.name == "root"
|
|
'''
|
|
|
|
|
|
[[rule.threat]]
|
|
framework = "MITRE ATT&CK"
|
|
[[rule.threat.technique]]
|
|
id = "T1222"
|
|
name = "File and Directory Permissions Modification"
|
|
reference = "https://attack.mitre.org/techniques/T1222/"
|
|
|
|
|
|
[rule.threat.tactic]
|
|
id = "TA0005"
|
|
name = "Defense Evasion"
|
|
reference = "https://attack.mitre.org/tactics/TA0005/"
|
|
|