Check ID:
Provider: AWS
Service:
Severity: CRITICAL
Categories:
Resource type:
ec2_instance_port_ssh_exposed_to_internetProvider: AWS
Service:
ec2Severity: CRITICAL
Categories:
internet-exposedResource type:
AwsEc2InstanceWhat this check verifies
EC2 instances with SSH (TCP 22) exposed to the Internet via security group inbound rules allowing0.0.0.0/0 or ::/0.
Exposure is qualified using the instance’s public IP status and subnet reachability.
Risk
Internet-exposed SSH invites brute force and credential stuffing. A successful sign-in grants remote shell, enabling data exfiltration, tampering of workloads, and lateral movement within the VPC, degrading confidentiality, integrity, and availability.Recommendation
Apply least privilege on SSH:- Restrict ingress to trusted IPs; avoid
0.0.0.0/0and::/0 - Prefer Session Manager or a hardened bastion behind VPN
- Use key-based auth; disable passwords
- Add defense in depth with network controls and monitor access logs
Remediation
- CLI
- Terraform
- Native IaC
- Dashboard steps
References
- https://docs.aws.amazon.com/vpc/latest/userguide/VPC_SecurityGroups.html
- https://www.trendmicro.com/trendaivisiononecloudriskmanagement/knowledge-base/aws/EC2/unrestricted-ssh-access.html
Where this check fires
This check runs on every scheduled scan against your AWS account. Findings appear at Cloud Security → Findings filterable byCheck ID = ec2_instance_port_ssh_exposed_to_internet. To re-evaluate after a fix, hit Run now on the account’s schedule under Cloud Security → Schedules — the next scan re-checks this control and marks the finding fixed or keeps it persistent.
← Back to AWS checks