Elastic low stable eql
Mount Execution Detected via Defend for Containers
This rule detects the use of the mount utility from inside a privileged container. The mount command is used to make a device or file system accessible to the system, and then to connect its root directory to a specified mount point on the local file system. When launched inside a privileged container--a container deployed with all the capabilities of the host machine-- an attacker can access sensitive host level files which could be used for further privilege escalation and container escapes to the host machine. Any usage of mount inside a running privileged container should be further investigated.
Detection Logic
process where host.os.type == "linux" and event.type == "start" and event.action == "exec" and (
process.name == "mount" or
(
/* account for tools that execute utilities as a subprocess, in this case the target utility name will appear as a process arg */
process.name in ("bash", "dash", "sh", "tcsh", "csh", "zsh", "ksh", "fish", "busybox") and
process.args in (
"mount", "/bin/mount", "/usr/bin/mount", "/usr/local/bin/mount"
) and
/* default exclusion list to not FP on default multi-process commands */
not process.args in (
"which", "/bin/which", "/usr/bin/which", "/usr/local/bin/which",
"man", "/bin/man", "/usr/bin/man", "/usr/local/bin/man",
"chmod", "/bin/chmod", "/usr/bin/chmod", "/usr/local/bin/chmod",
"chown", "/bin/chown", "/usr/bin/chown", "/usr/local/bin/chown"
)
)
) and container.security_context.privileged == true and container.id like "*" and
not process.parent.args in (
"docker-init", "/usr/local/bin/dind", "/bin/aws-efs-csi-driver", "/bin/aws-ebs-csi-driver", "/usr/bin/aws-ebs-csi-driver"
) Field Validations
Loading…
Comments (0)
Loading comments...