1 minute read

Overview

Dear all, this post will provide you an idea to go through retirement of EWS from exchange online. All of this content from refer following two documents from Microsoft.

  • Refer1:

https://learn.microsoft.com/en-us/exchange/hybrid-deployment/deploy-dedicated-hybrid-app#service-principal-clean-up-mode

  • Refer2:

https://techcommunity.microsoft.com/blog/exchange/dedicated-hybrid-app-temporary-enforcements-new-hcw-and-possible-hybrid-function/4440682

First up first, take a look at the prerequisites

  1. Classic Full or Modern Full hybrid configuration needed
  2. Exchange server version required as shown in the table image

0. Index

  1. HU
  2. Run HCW to create Dedicated hybrid app
  3. Cleanup the Service Principal Cleanup Mode
  4. Setting override
  5. Verify application
  6. NOTICE!

1. HU

  1. Check the Exchange version image

  2. Update if you need. If you have already CU15, Click the link below to update with the April 2025 HU

  • Download:

https://www.microsoft.com/en-us/download/details.aspx?id=108144

2. Run HCW to create Dedicated hybrid app

  1. Click the link below to install and run HCW(Hybrid Configuration Wizard) on your Exchange server.
    • https://aka.ms/hybridwizard
  2. Configure whatever you want but make sure to consent with the grant administrative prevelidge. image

  3. After configuration completed, go to your enterprise application from the Entra ID to check if the application created successfully. image

3. Cleanup the Service Principal Cleanup Mode

  1. Go to here and download the script
  • Download Script:

https://github.com/microsoft/CSS-Exchange/releases/latest/download/ConfigureExchangeHybridApplication.ps1

  1. To cleanup the certificate from the 1st party service principal keycredentials, execute this from your EMS(Exchange Management Shell)
    .\ConfigureExchangeHybridApplication.ps1 -ResetFirstPartyServicePrincipalKeyCredentials
    
  2. Result will be like: image

4. Setting override

To enable dedicated hybrid app feature, execute this: image

New-SettingOverride -Name "EnableExchangeHybrid3PAppFeature" -Component "Global" -Section "ExchangeOnpremAsThirdPartyAppId" -Parameters @("Enabled=true") -Reason "Enable dedicated Exchange hybrid app feature"

image

Get-ExchangeDiagnosticInfo -Process Microsoft.Exchange.Directory.TopologyService -Component VariantConfiguration -Argument Refresh | fl

image

5. Verify application

Application properties

  1. From Entra ID > App registration > Certificates & Secrets, you can see the OAuth certificate which obviously from the Exchange server image

  2. Granted to use Office 365 Exchange Online which just as we configured from HCW

image

Application logs

  1. Create a new schedule from onboard mailbox(Cake01@cake.run.place) image

  2. Query the schedule from on-premises mailbox(Cake02@cake.run.place) image

I just retrive the cake01’s schedule arround 20:20.

  1. Let’s see the logs. Go ‘Entra ID > Signin logs > Service Principal’ image

It shown as ‘2025-09-18T11:16:52Z’ and it is ‘2025-09-18 20:16:52 (KST)’

  1. Logs
    • The Dedicated hybrid app was trying to access to Exchange online image
  • From the exchange server IP address is shown image

So, the configuration looks good.

6. NOTICE!

You need to uncheck ‘Oauth, Intra Organisation Connector and Organisation Relationship’ from now on.. if not, you have to do all of this procedure again from the start.. image

image

Leave a comment