Exposed instances create attack vectors for unauthorized access. You can easily list all publicly accessible AWS EC2 instances synced with CloudQuery with this PostgreSQL query:
SELECT
account_id,
instance_id,
subnet_id,
vpc_id,
region,
private_ip_address,
public_ip_address,
tags
FROM aws_ec2_instances
WHERE
aws_ec2_instances.subnet_id in (select subnet_id from aws_ec2_subnets) and aws_ec2_instances.public_ip_address is not null
AND state->>'Name' = 'running'