SOLVED

Block Microsoft Exchange Server 2016 Exchange Admin Center (EAC) website from Internet

Copper Contributor

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:

 

https://docs.microsoft.com/en-us/exchange/architecture/client-access/disable-exchange-admin-center-a...

 

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.

 

 

10 Replies

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

Hi @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?

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

Hi @manuphilip,
Thanks again for your reply. Again, If you have noticed in my question (1st Post) I have mentioned that its already configured on the default ECP website but still in that case https://mail.domain.com/ecp login page is accessible which we want to block. We created a second ECP website with internal Private IP for administration purpose where -AdminEnabled:$true and default ECP website is -AdminEnabled:$false.

Hope this will clarify and you will understand the requirements :)

Hi @abdullahsalam 

The page reference clearly says the following

 

Verify that https://mail.contoso.com/ecp and https://mbx01.contoso.com/ecp return either of the following results:

  • 404 - website not found

In that case, please make sure that, the steps followed are correct.

Hi @manuphilip,
I think you need to review my previous posts.

The steps followed are correct and yes It shows show 404 error or it redirects to owa settings page AFTER USER/ADMIN LOGINS to the ecp/EAC login page.

The requirement is to restrict/block the ECP login page also.

Hope this will clarify things for you the requirements.
Dear 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/
Hi @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?
best response confirmed by abdullahsalam (Copper Contributor)
Solution
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.

HI@Sam Erde 

 

Thanks for your reply and for providing your recommendations. I would then conclude that the only solution for restricting the ECP Login Page access is using the reverse proxy solution to meet the security requirements of the customer. 

 

I have also tested the Client Access Rules on Exchange Server 2019 in my lab to block client access to the EAC but still, it shows the Exchange Admin Center Login page. Also I get the same result when I configured "IP address and Domains  Restrictions" Feature in IIS. 

1 best response

Accepted Solutions
best response confirmed by abdullahsalam (Copper Contributor)
Solution
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.

View solution in original post