Forum Discussion
abdullahsalam
Aug 04, 2020Copper Contributor
Block Microsoft Exchange Server 2016 Exchange Admin Center (EAC) website from Internet
Hi,
As per requirements from our customer to restrict EAC from External network, We have configured Exchange 2016 servers configured with Option 2 using the article below:
As per customer security requirements, EAC/ECP website URL should not be accessible and should be blocked without impacting OWA accessibility for the users from Exchange Servers. Need help if this can be achieved using Exchange Server Configurations.
NOTE: By following the above article, EAC access is restricted but the EAC login page is still accessible by all the users.
- I would highly recommend using a reverse proxy between your perimeter firewall and your Exchange server[s]. You can configure the reverse proxy to only pass through OWA traffic and ignore/drop ECP URL requests.
Once this is properly configured, you don't need to go through the hassle of disabling ECP on your Exchange Server or even creating a separate ECP site. (Although if you've already done that work, there's no reason to undo it.) Regardless of your choice, just be sure to set your external ECP URL values to null.
Off the top of my head, two potential solutions for a reverse proxy (I'm sure there are many) might be Citrix ADC (Netscaler) or Traefik. This is essentially what AAP does, but AAP (Azure App Proxy) is running in Azure, whereas your reverse proxy could run on premises.
- BemmelenPatrickIron ContributorDear Abdullah,
I would like to suggest you take a look at a blog I wrote about using Azure App Proxy with Exchange to only allow OWA and/or ECP through the App Proxy.
This will give you the possibility to use SSO and MFA / Conditional Access to limit and secure these components:
https://www.patrickvanbemmelen.nl/securing-using-sso-for-owa-ecp-with-the-azure-app-proxy/- abdullahsalamCopper ContributorHi BemmelenPatrick,
Thanks for your reply and sharing the guide.
Is it AAP Officially supported to publish exchange services?
Also can we leverage Azure App Proxy to publish all Exchange virtual directories such as EWS, ActiveSync and Autodiscover?
I agree that it's good to have AAP to hide OWA and ECP behind AAP to get MFA support, but this leaves the other directories exposed to the public internet and we need to maintain reverse proxies on-premise etc.
Also, the AAP solution would require the customer to sync their Directory to Azure AD which as per customer won't agree for security reasons.
Also the customer is Government UAE based and may consider if Azure AD and Azure AD proxy service is available in UAE. Please correct me, as per my information Azure AD proxy isn't available in UAE region.
Is there any supported alternatives preferably using Exchange to achieve the goal?- SamErdeIron ContributorI would highly recommend using a reverse proxy between your perimeter firewall and your Exchange server[s]. You can configure the reverse proxy to only pass through OWA traffic and ignore/drop ECP URL requests.
Once this is properly configured, you don't need to go through the hassle of disabling ECP on your Exchange Server or even creating a separate ECP site. (Although if you've already done that work, there's no reason to undo it.) Regardless of your choice, just be sure to set your external ECP URL values to null.
Off the top of my head, two potential solutions for a reverse proxy (I'm sure there are many) might be Citrix ADC (Netscaler) or Traefik. This is essentially what AAP does, but AAP (Azure App Proxy) is running in Azure, whereas your reverse proxy could run on premises.
- manuphilipBrass Contributor
Hi abdullahsalam,
OWA or ECP are accessible from internet through the records pointed in public DNS. So, you may go for deleting the records like mail.domain.com from public DNS.
You can also set the OWA, ECP public urls as null in the respective virtual directories to block the internet access as an alternate way. get-owavirtualdirectory or get-ecpvirtualdirectory cmdlets should report null value for external urls. You can use internal urls in external url field also so that those urls will be unavailable from internet
- abdullahsalamCopper ContributorHi manuphilip,
Thanks for your reply.
How the users will access OWA from the internet if we delete the records? even if we delete the records, ECP default website will still be accessible using the public IP mapped to the server.
We want to make sure that OWA is accessible from the internet using https://mail.domain.com/owa but to block https://mail.domain.com/ecp URL or EAC login page.
Currently, if any user/admin access https://mail.domain.com/ecp its reachable and can access the login page from the internet which we want to restrict/block/deny access.
As mentioned earlier, if user/admin try to login to https://mail.domain.com/ecp then it gets redirected to OWA settings page which is the expected behaviour as we have disabled admin access to EAC on default ECP website. But the requirement is to block the EAC login page itself making sure OWA is accessible.
Is there any other way we can achieve this?- manuphilipBrass Contributor
Hi abdullahsalam,
I didn't notice the original request is for disabling only ECP. I think you can disable the ECP access by the following cmdlet
Get-EcpVirtualDirectory | Set-EcpVirtualDirectory -AdminEnabled $false