Contact EC2 Instance Metadata Service From Container


Description

Detects attempts to communicate with the EC2 Instance Metadata Service from a container. This detection is narrowly focused and might not apply to your environment. In addition, it could generate noise and require fine-tuning.

Query · falco

outbound and container and fd.sip="169.254.169.254" and not ec2_metadata_containers

Rule dependencies

Depends on

  • composes · Falco macro container
    A shared condition, not a detection — not indexed on this site.
  • composes · Falco macro ec2_metadata_containers
    A shared condition, not a detection — not indexed on this site.
  • composes · Falco macro outbound
    A shared condition, not a detection — not indexed on this site.

Analyst notes

Outbound connection to EC2 instance metadata service | connection=%fd.name lport=%fd.lport rport=%fd.rport fd_type=%fd.type fd_proto=%fd.l4proto evt_type=%evt.type user=%user.name user_uid=%user.uid user_loginuid=%user.loginuid process=%proc.name proc_exepath=%proc.exepath parent=%proc.pname command=%proc.cmdline terminal=%proc.tty

Raw source Contact EC2 Instance Metadata Service From Container · Falco YAML
Esc
Published by falcosecurity/rules ↗, licensed under Apache 2.0 ↗. Reproduced here unmodified.
rule: Contact EC2 Instance Metadata Service From Container
desc: 'Detects attempts to communicate with the EC2 Instance Metadata Service from
  a container. This detection is narrowly focused and might not apply to your environment.
  In addition, it could generate noise and require fine-tuning.

  '
condition: 'outbound and container and fd.sip="169.254.169.254" and not ec2_metadata_containers

  '
output: Outbound connection to EC2 instance metadata service | connection=%fd.name
  lport=%fd.lport rport=%fd.rport fd_type=%fd.type fd_proto=%fd.l4proto evt_type=%evt.type
  user=%user.name user_uid=%user.uid user_loginuid=%user.loginuid process=%proc.name
  proc_exepath=%proc.exepath parent=%proc.pname command=%proc.cmdline terminal=%proc.tty
priority: NOTICE
tags:
- maturity_incubating
- network
- aws
- container
- mitre_credential_access
- T1552.005

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.