Security Focus: Enable / Disable MFA on Azure AD Admin Account


Last week I presented a little function that I use to reset my Azure AD admin account passwords.

This week I want to show how to enable / disable Multi Factor Authentication on an Azure AD account.
 
Enable


$St = New-Object -TypeName Microsoft.Online.Administration.StrongAuthenticationRequirement
$St.RelyingParty = "*"
$Sta = @($St)
Set-MsolUser -UserPrincipalName ifarr@contoso.com -StrongAuthenticationRequirements $Sta 

 

Disable


$Sta = @()
Set-MsolUser -UserPrincipalName ifarr@contoso.com -StrongAuthenticationRequirements $Sta 

 

Comments (2)

  1. turbomcp says:

    Great stuff
    Thanks

  2. JosephK says:

    Exactly what i was looking for, How to Disable MFA for O365 User via Powershell.

Skip to main content