8.2 Azure Bastion Architecture & Secure Remote Access
Key Takeaways
- Azure Bastion is a fully managed PaaS remote management proxy that provides secure, browser-based and native client RDP (3389) and SSH (22) connectivity to VMs without exposing public IP addresses on target workloads.
- Azure Bastion requires a dedicated subnet named exactly 'AzureBastionSubnet' with a minimum prefix of /26 (64 IP addresses) to accommodate platform management, autoscaling, and maintenance upgrades.
- Azure Bastion is offered across Developer, Basic, Standard, and Premium SKUs; Standard adds native client support, IP-based connection, shareable links, and manual/autoscaling (up to 50 scale units), while Premium introduces session recording and private-only deployment.
- The AzureBastionSubnet enforces mandatory NSG rules: Inbound requires HTTPS 443 from Internet, HTTPS 443 from GatewayManager, HTTPS 443 from AzureLoadBalancer, and ports 5701/8080 from VirtualNetwork; Outbound requires ports 22/3389 to VirtualNetwork, port 443 to AzureCloud, ports 5701/8080 to VirtualNetwork, and port 80 to Internet for CRL/session validation.
- IP-based connection enables Bastion Standard/Premium to target virtual machines across peered VNets or on-premises networks via private IP address, eliminating the need to deploy redundant Bastion hosts in every spoke VNet.
Azure Bastion Architecture & Secure Remote Access
Traditional remote administration of cloud infrastructure often relied on deploying public-facing "jump boxes" or assigning public IP addresses directly to virtual machines. This approach exposed critical management protocols—Remote Desktop Protocol (RDP / TCP 3389) and Secure Shell (SSH / TCP 22)—to automated port scanners, brute force dictionary attacks, credential stuffing, and zero-day protocol exploits.
Azure Bastion solves this security challenge by providing a fully managed, platform-as-a-service (PaaS) bastion proxy deployed directly inside your Virtual Network. Administrators establish an encrypted TLS (HTTPS port 443) connection from their web browser or native client to the Azure Bastion host. The Bastion host terminates the TLS session and proxies the RDP or SSH stream over the private Azure SDN fabric to the target VM's private IP address.
+-----------------------------------------------------------------------------+
| AZURE BASTION ARCHITECTURE |
| |
| Administrator Workstation |
| | |
| | (1) Encrypted TLS / HTTPS (Port 443) |
| v |
| +---------------------------------------------------------------------+ |
| | Azure Virtual Network (Hub-VNet: 10.100.0.0/16) | |
| | |
| | +-------------------------------------------------------------+ |
| | | Subnet: AzureBastionSubnet (10.100.0.0/26) | |
| | | [ Azure Bastion PaaS Scale Units (Standard SKU: 2-50) ] | |
| | | - Public IP: 52.183.40.50 (TLS Ingress) | |
| | | - NSG: Mandatory Platform Inbound/Outbound Rules | |
| | +-------------------------------------------------------------+ |
| | | |
| | | (2) Private RDP (3389) / SSH (22)|
| | v |
| | +-------------------------------------------------------------+ |
| | | Subnet: Workload-Subnet (10.100.1.0/24) | |
| | | [ Target VM: 10.100.1.4 ] (NO Public IP Required!) | |
| | +-------------------------------------------------------------+ |
| +---------------------------------------------------------------------+ |
| | |
| | (3) Cross-Peered VNet Reachability |
| v |
| +---------------------------------------------------------------------+ |
| | Peered Spoke VNet (10.200.0.0/16) | |
| | [ Target VM: 10.200.1.4 ] (Accessible via IP-Based Connection) | |
| +---------------------------------------------------------------------+ |
+-----------------------------------------------------------------------------+
1. Dedicated Subnet Architecture: AzureBastionSubnet
Azure Bastion requires a dedicated, specially configured subnet within the host Virtual Network. Sizing and naming rules are strictly enforced by Azure Resource Manager:
- Subnet Name: Must be named exactly
AzureBastionSubnet(case-sensitive). Any other name will cause deployment validation to fail. - Minimum Subnet Sizing: Sized at /26 or larger (e.g.,
/26provides 64 total IP addresses,/25provides 128). Deploying in a/27(32 IPs) or/28(16 IPs) is explicitly rejected by the platform. - Workload Isolation: No other resources (such as standard VMs, load balancers, or application gateways) can be deployed inside
AzureBastionSubnet. - Route Table (UDR) Restrictions: You must not attach a User-Defined Route (UDR) to
AzureBastionSubnetthat directs0.0.0.0/0internet traffic to a firewall or Network Virtual Appliance (NVA). Forcing default route egress through an NVA breaks Azure Bastion control plane management and health probing.
2. Azure Bastion SKU Comparison Matrix
Azure Bastion is available in four feature tiers: Developer, Basic, Standard, and Premium.
| Feature / Capability | Developer SKU | Basic SKU | Standard SKU | Premium SKU |
|---|---|---|---|---|
| Architecture / Tenancy | Multi-tenant shared pool | Dedicated PaaS instance | Dedicated PaaS instance | Dedicated PaaS instance |
| Subnet & Public IP | No dedicated subnet/PIP | Requires AzureBastionSubnet (/26) + Standard PIP | Requires AzureBastionSubnet (/26) + Standard PIP | Requires AzureBastionSubnet (/26) + Standard PIP (or Private-only) |
| Scale Units (Instances) | 1 (Fixed) | 2 (Fixed) | 2 to 50 scale units (Manual / Autoscale) | 2 to 50 scale units (Manual / Autoscale) |
| Concurrent Sessions | 1 session | Up to ~20 RDP / 40 SSH | Up to ~500 RDP / 1000 SSH (at 50 units) | Up to ~500 RDP / 1000 SSH (at 50 units) |
| Web Browser Access (HTML5) | Supported | Supported | Supported | Supported |
| Native Client Support | Not supported | Not supported | Supported (az network bastion rdp/ssh, mstsc, OpenSSH) | Supported |
| IP-Based Connection | Not supported | Not supported | Supported (Target VMs across peered VNets / on-prem) | Supported |
| Shareable Links | Not supported | Not supported | Supported (One-click access without portal) | Supported |
| Custom Inbound Ports | Not supported | Not supported | Supported (Non-standard RDP/SSH ports) | Supported |
| Session Recording | Not supported | Not supported | Not supported | Supported (Video capture to Azure Blob Storage) |
| Private-Only Deployment | Not supported | Not supported | Not supported | Supported (No public IP; private access only) |
| Kerberos Authentication | Not supported | Not supported | Supported | Supported |
[!IMPORTANT] Scale Unit Capacity Planning: Each scale unit in Azure Bastion Standard and Premium supports approximately 10 concurrent RDP sessions or 20 concurrent SSH sessions. A deployment scaled to 10 scale units can handle ~100 concurrent RDP sessions or ~200 concurrent SSH sessions.
3. Advanced Bastion Capabilities Deep-Dive
Native Client Support
Standard and Premium SKUs allow administrators to connect to target virtual machines using their preferred local desktop tools—such as Windows Remote Desktop Connection (mstsc.exe), OpenSSH client, PuTTY, or Visual Studio Code Remote SSH—instead of being confined to a web browser tab.
Native client connectivity operates by leveraging the Azure CLI (az network bastion) to establish a secure local-to-remote TLS tunnel:
# Connect to a Windows VM via native RDP client through Bastion:
az network bastion rdp \
--name "Production-Bastion" \
--resource-group "RG-Networking" \
--target-resource-id "/subscriptions/.../virtualMachines/Win-Server01"
# Connect to a Linux VM using native SSH client and SSH key:
az network bastion ssh \
--name "Production-Bastion" \
--resource-group "RG-Networking" \
--target-resource-id "/subscriptions/.../virtualMachines/Linux-Worker01" \
--auth-type "ssh-key" \
--username "azureuser" \
--ssh-key "~/.ssh/id_rsa"
# Open a local tunnel for arbitrary tooling (e.g., custom RDP port mapping):
az network bastion tunnel \
--name "Production-Bastion" \
--resource-group "RG-Networking" \
--target-resource-id "/subscriptions/.../virtualMachines/Linux-Worker01" \
--resource-port 22 \
--port 50022
IP-Based Connection
In multi-VNet hub-and-spoke topologies, deploying an Azure Bastion host in every spoke VNet is cost-prohibitive. IP-Based Connection allows a centralized Azure Bastion Standard or Premium host deployed in the Hub VNet to connect to target VMs located across:
- Peered Spoke VNets (via Regional or Global VNet Peering)
- On-Premises Datacenters (reachable across ExpressRoute or Site-to-Site VPN)
- Non-Azure endpoints with routable private IP addresses
Instead of specifying an Azure Resource ID, the administrator enters the target's private IPv4 address (e.g., 10.200.1.10) directly in the Azure Portal or CLI.
Shareable Links
Shareable Links enable frictionless, secure remote access for third-party vendors, external contractors, or auditors who do not possess user accounts in your Microsoft Entra ID tenant or Azure RBAC permissions on the subscription:
- An administrator generates a unique Shareable Link for a specific target VM.
- The external user opens the URL in any standard web browser.
- The user authenticates directly against the target operating system (using local VM credentials or domain credentials) over an encrypted HTTPS session without accessing the Azure Portal.
- Administrators can view, audit, and revoke shareable links instantly at any time from the Azure Bastion management blade.
Session Recording (Premium SKU)
For highly regulated industries (such as banking, healthcare, and defense), Azure Bastion Premium provides built-in Session Recording:
- Automatically records all graphical RDP sessions and terminal SSH sessions.
- Stores recordings as append blobs directly into a designated Azure Blob Storage container in your subscription.
- Captures rich metadata (start time, session duration, username, source IP, target VM, protocol).
- Enables forensic security investigations, compliance audits, and non-repudiation verification.
4. Mandatory NSG Rules on AzureBastionSubnet
To ensure platform security, cluster synchronization, and control plane management, Azure enforces strict Network Security Group (NSG) rules on AzureBastionSubnet. If an associated NSG omits any required rule or blocks platform traffic, deployment will fail with a NetworkIntentPolicyValidationFailed error.
Inbound NSG Requirements
| Priority | Rule Name | Source | Port | Destination | Port | Protocol | Access | Technical Purpose |
|---|---|---|---|---|---|---|---|---|
| 100 | AllowHttpsInbound | Internet (or Admin Public IPs) | * | * | 443 | TCP | Allow | Ingress HTTPS traffic from administrators connecting to Bastion. |
| 110 | AllowGatewayManagerInbound | GatewayManager | * | * | 443 | TCP | Allow | Azure control plane management and health monitoring. |
| 120 | AllowAzureLoadBalancerInbound | AzureLoadBalancer | * | * | 443 | TCP | Allow | Infrastructure health probing (168.63.129.16). |
| 130 | AllowBastionHostCommunication | VirtualNetwork | * | VirtualNetwork | 5701, 8080 | TCP | Allow | Data plane clustering and session synchronization between Bastion scale units. |
| 65500 | DenyAllInBound | * | * | * | * | * | Deny | Default fallback deny. |
Outbound NSG Requirements
| Priority | Rule Name | Source | Port | Destination | Port | Protocol | Access | Technical Purpose |
|---|---|---|---|---|---|---|---|---|
| 100 | AllowSshRdpOutbound | * | * | VirtualNetwork | 22, 3389 | TCP | Allow | Egress RDP and SSH traffic to target workload VMs in local or peered VNets. |
| 110 | AllowAzureCloudOutbound | * | * | AzureCloud | 443 | TCP | Allow | Egress to Azure platform services (diagnostics, logging, metrics, telemetry). |
| 120 | AllowBastionCommunication | VirtualNetwork | * | VirtualNetwork | 5701, 8080 | TCP | Allow | Internal inter-node clustering communication across scale units. |
| 130 | AllowGetSessionInformation | * | * | Internet | 80 | TCP | Allow | Session token validation and Certificate Revocation List (CRL) PKI checks. |
| 65500 | DenyAllOutBound | * | * | * | * | * | Deny | Default fallback deny. |
[!CAUTION] The Port 80 Outbound Requirement: Administrators frequently attempt to block outbound TCP Port 80 to the Internet on
AzureBastionSubnet, believing HTTP is insecure. However, Azure Bastion requires outbound Port 80 for Certificate Revocation List (CRL) validation and session authentication. Blocking outbound Port 80 causes TLS handshakes to fail, completely disabling Bastion remote access.
An enterprise operations team wants systems administrators to connect to Linux and Windows Azure virtual machines using native desktop tools (Remote Desktop Connection 'mstsc.exe' and terminal OpenSSH via the Azure CLI) rather than the Azure Portal web browser interface. The target virtual machines are distributed across multiple peered spoke virtual networks. Which Azure Bastion configuration fulfills these requirements with minimal administrative overhead?
A cloud security engineer is hardening the Network Security Group associated with 'AzureBastionSubnet'. To enforce strict outbound filtering, the engineer removes the outbound rule permitting TCP Port 80 to the Internet, believing that only encrypted HTTPS (Port 443) and target RDP/SSH (3389/22) traffic should be allowed. Shortly after applying the change, administrators report that all Bastion connection attempts fail with session handshake timeouts. What caused this failure?
A network administrator is provisioning an Azure Bastion host in an existing virtual network. The administrator creates a dedicated subnet named 'AzureBastionSubnet' with address prefix 10.100.0.0/27 (32 total IP addresses). When executing the deployment script, Azure Resource Manager returns a deployment validation error. What modification is required to successfully deploy Azure Bastion?
A healthcare enterprise needs to grant an external compliance auditing team temporary, 48-hour access to inspect three specific Azure virtual machines hosting financial audit logs. The auditors do not have user accounts in the organization's Microsoft Entra ID tenant and must not be granted access to the Azure Portal. What is the most secure and efficient method to provide this access using Azure Bastion?