Symptoms
In Microsoft Exchange Server 2019 or Exchange Server 2016, assume that you set a web proxy server that the Exchange Server uses to reach the Internet by using the InternetWebProxy parameter and there's no direct access to the Internet. You may experience that the OAuth connectivity always fails if you test it by using the Test-OAuthConnectivity cmdlet even if the connectivity is working fine.
Cause
This issue occurs because the Test-OAuthConnectivity cmdlet does not honor the InternetWebProxy settings set on the Exchange Server. Therefore, if the Exchange Server is blocked to connect to the Internet directly, you won't correctly test the OAuth connectivity.
Status
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.
Resolution
To fix this issue, install one of the following updates:For Exchange Server 2019, install the Cumulative Update 1 for Exchange Server 2019 or a later cumulative update for Exchange Server 2019.
For Exchange Server 2016, install the Cumulative Update 12 for Exchange Server 2016 or a later cumulative update for Exchange Server 2016.
References
Learn about the terminology that Microsoft uses to describe software updates.