A bastion host exposed to the internet becomes a direct target for brute-force attacks and exploit attempts. If SSH is open to everyone, attackers can probe credentials and service weaknesses continuously. Limiting inbound access to approved source IPs narrows the attack surface, reduces opportunistic scanning, and makes the bastion a managed access control rather than a public entry point.
Why SSH on a bastion host changes the risk profile
A bastion host is a deliberate choke point, so leaving SSH open to the internet turns it into a high-value, continuously probed access path. That exposure increases the chance of password guessing, key theft abuse, and exploitation of the SSH service itself. In a cloud environment, the consequence is larger because the bastion often sits close to privileged network segments and managed resources.
The real issue is not simply that SSH exists, but that a broadly reachable login service invites repeated authentication attempts and expands the opportunity for an attacker to test weaknesses at machine speed. Once that host is compromised, the bastion can become a bridge into otherwise segmented cloud workloads, admin planes, or internal services.
- Internet exposure increases the attack surface and makes the bastion visible to opportunistic scanning.
- Open SSH supports credential attacks, especially password spraying and brute force against weak or reused credentials.
- If the bastion has broad reach, a single compromise can create disproportionate blast radius.
Why source-IP restriction matters in cloud access paths
Restricting inbound SSH to approved source IPs narrows who can even attempt the connection, which removes a large amount of background noise from scanning and reduces the chance of casual exploitation. It also forces access through a known egress path, such as a corporate VPN or tightly managed admin network, which is easier to monitor and govern.
That control does not make SSH inherently safe, but it changes the problem from public exposure to controlled access. In practice, it is one layer that helps the bastion function as an administrative control point rather than an always-on public login surface. For cloud environments, that distinction matters because cloud assets are often reachable from multiple routes unless ingress is deliberately constrained.
- Approved source ranges make traffic easier to attribute and investigate.
- Limiting exposure reduces opportunistic attack volume before authentication is even attempted.
- The control works best when paired with MFA, key-based authentication, and short-lived access methods.
Risk and Threat Considerations
Leaving SSH open on a bastion host increases both exposure and attacker opportunity. The main failure mode is not a single exotic exploit, but steady adversarial pressure against a public login service that can be reached from anywhere on the internet. In cloud environments, that matters because a bastion is often trusted to reach more sensitive systems than an ordinary server.
Failure mechanism: Attackers use continuous scanning, password spraying, stolen key abuse, or SSH service exploitation to gain a foothold on the bastion, then pivot to downstream cloud resources that inherit its network reach and trust.
Impact: A successful compromise can expose administrative access, enable lateral movement into private subnets, and widen the blast radius far beyond the bastion itself.
Standards & Framework Alignment
This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.
OWASP Non-Human Identity Top 10 address the attack and risk surface, while CIS Controls v8, NIST CSF 2.0 and NIST Zero Trust (SP 800-207) set the governance and control requirements practitioners need to meet.
| Framework | Control / Reference | Relevance |
|---|---|---|
| CIS Controls v8 | 6 — Access Control Management | Restricting SSH ingress and admin reach is access control management for a cloud bastion. |
| 8 — Audit Log Management | Bastion SSH sessions should be logged to detect probing and misuse of privileged access. | |
| 4 — Secure Configuration of Enterprise Assets and Software | Exposed SSH on a bastion is a configuration exposure that should be minimized and hardened. | |
| Recommendation — Limit inbound SSH to approved admin sources and remove unnecessary public access paths. Centralize bastion SSH logs and alert on repeated failures or unusual source activity. Harden the bastion configuration and disable unnecessary public exposure by default. | ||
| NIST CSF 2.0 | PR.AC — Identity Management, Authentication, and Access Control | SSH restriction and controlled admin access directly support access control for a bastion host. |
| PR.PS — Platform Security | A bastion exposed to the internet is a platform security exposure that should be reduced. | |
| Recommendation — Enforce restricted administrative access paths for the bastion. Reduce the bastion attack surface by limiting exposed services and inbound reach. | ||
| NIST Zero Trust (SP 800-207) | PL-2 — Zero Trust Architecture | A bastion with source-IP restriction fits zero trust principles of explicit, bounded access. |
| PA-2 — Device and User Authentication | SSH access to a bastion should be tied to strong authentication before privileged reach is granted. | |
| Recommendation — Treat the bastion as a verified access broker with explicit trust conditions. Require strong authentication before allowing administrative SSH access. | ||
| OWASP Non-Human Identity Top 10 | NHI-01 — Secrets and Credential Management | SSH keys and related credentials used on a bastion are identity-bearing material that must be tightly managed. |
| NHI-03 — Least Privilege and Access Control | A bastion should expose only the minimum SSH access needed for administration. | |
| Recommendation — Protect SSH credentials with tight storage, rotation, and access restriction. Restrict bastion SSH access to the minimum set of approved operators and hosts. | ||
Practitioner Guidance
What to verify: Confirm that SSH ingress is limited to known admin source networks, and that no rule still allows broad internet access under the guise of temporary troubleshooting. If the bastion is reachable from anywhere, treat it as a high-priority exposure until proven otherwise.
Decision rule: If SSH is needed for administration, require a constrained path, strong authentication, and an audit trail for every session; if it is not needed, remove it rather than hardening a public service that should not be public.
Practitioner takeaway: The goal is not to eliminate bastions, but to ensure the bastion is a controlled access boundary with measurable trust, not a universally reachable entry point.
Related resources from NHI Mgmt Group
- Why do serverless environment variables increase the risk of credential exposure in cloud workloads?
- Why does leaving cloud storage encryption disabled increase operational risk?
- Why does managing SSH key files for cloud instance access increase security risk?
- Why does a firewall vulnerability in a cloud environment increase the risk of data exposure and account compromise?