Overview
An Exchange authentication policy can specify which protocols are available for allowing user to sign-in to access various services. To avoid brute password spray attacks that identify password validity by monitoring Exchange server response to sign-in attempts, many organizations are opting to disable legacy POP, IMAP, SMTP, etc protocol authentication methods.The process described in this article will allow you to assign an existing policy to a user in your Azure Active Directory domain.
Prerequisites
Prior to attempting this operation, you must have the following:- Installed Exchange Online PowerShell V2
- Created authentication policy
- Have access to an administrative account with sufficient privileges to modify user objects
Description
Replace [strings in brackets] with actual values for your organization- Run Exchange PowerShell V2
- Sign in to the tenant with the following command:
- connect-exopssession -userprincipalname [adminaccount@company.onmicrosoft.com]
- Verify user's current authentication policy
- get-user [alias@company.org] | ft name,authenticationpolicy
- Set user's desired authentication policy (["authentication policy name"])
- set-user -identity [alias@company.org] -authenticationpolicy ["authentication policy name"]
- Verify policy change took place:
- get-user [alias@company.org] | ft name,authenticationpolicy
Note that typical policy changes take effect within 24 hours. To make changes immediate, run the following script:
Set-User -Identity [alias@company.org] -STSRefreshTokensValidFrom $([System.DateTime]::UtcNow)