Ask Learn
Preview
Ask Learn is an AI assistant that can answer questions, clarify concepts, and define terms using trusted Microsoft documentation.
Please sign in to use Ask Learn.
Sign inThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
A question I see periodically is how to restrict RDP access for PaaS services to specific network IP addresses. In the past this has always been difficult to do and the typical solution was to use a Startup task to configure firewall rules (ie. using Set-NetFirewallRule or netsh advfirewall per https://msdn.microsoft.com/en-us/library/azure/jj156208.aspx). This technique generally works fine, but it introduces the extra complexity of a startup task and is not built into the Azure platform itself.
With the (relatively) recent introduction of network ACLs it becomes much easier to robustly secure an input endpoint on a cloud service. My colleague Walter Myers has a great blog post about how to enable network ACLs for PaaS roles at https://blogs.msdn.com/b/walterm/archive/2014/04/22/windows-azure-paas-acls-are-here.aspx. To apply a network ACL to the RDP endpoint it is simply a matter of defining your ACL rules targeting the role which imports the RemoteForwarder plugin, and specifying the name of the RDP endpoint in the endPoint attribute.
Here is the resulting NetworkConfiguration section to add to the CSCFG file:
<NetworkConfiguration>
<AccessControls>
<AccessControl name="RDPRestrict">
<Rule action="permit" description="PermitRDP" order="100" remoteSubnet="167.220.26.0/24" />
<Rule action="deny" description="DenyRDP" order="200" remoteSubnet="0.0.0.0/0" />
</AccessControl>
</AccessControls>
<EndpointAcls>
<EndpointAcl role="WebRole1" endPoint="Microsoft.WindowsAzure.Plugins.RemoteForwarder.RdpInput" accessControl="RDPRestrict" />
</EndpointAcls>
</NetworkConfiguration>
Important information:
Ask Learn is an AI assistant that can answer questions, clarify concepts, and define terms using trusted Microsoft documentation.
Please sign in to use Ask Learn.
Sign in