turbot/aws_perimeter
GitHub
Loading controls...

Control: EC2 network interfaces should not have a public IP address

Description

This control checks if EC2 network interfaces are associated with any public IP.

Usage

Run the control in your terminal:

steampipe check aws_perimeter.control.ec2_network_interface_not_publicly_accessible

Snapshot and share results via Steampipe Cloud:

steampipe login
steampipe check --share aws_perimeter.control.ec2_network_interface_not_publicly_accessible

Plugins & Tables

SQL

select
network_interface_id as resource,
case
when association_public_ip is null then 'ok'
else 'alarm'
end status,
case
when association_public_ip is null then network_interface_id || ' not publicly accessible.'
else network_interface_id || ' publicly accessible.'
end reason,
region,
account_id
from
aws_ec2_network_interface;

Tags