Azure中传统管理员的MFA状态

时间:2020-07-15 13:31:16

标签: azure powershell azure-active-directory

具有ServiceAdministrator,AccountAdministrator和CoAdministrator角色的用户是Azure中的经典管理员。 我们正在尝试获取这些经典管理员用户的MFA状态。但是,在PowerShell中使用' Get-MsolUser -UserPrincipalName {classicAdminSignInName} ',我们不会得到任何用户。 此外,从Azure门户在Azure AD中搜索时,找不到经典管理员用户。 关于上述情况,请您帮助我们了解一下。如何使用PowerShell获取经典管理员的MFA状态?

1 个答案:

答案 0 :(得分:0)

这不是您获得ADUser UPN的方式。 你会做的...

Get-MsolUser -UserPrincipalName SomeUserName@SomeDomain.com

...不需要括号,除非您要使用Where过滤。

Get-MsolUser | 
Where-Object { $_.isLicensed -eq "TRUE" } | 
Select UserPrincipalName

就像您通过本地ADDS中的Get-ADUser进行操作一样。

搜索用例将显示您需要了解的项目:

'get azure user mfa status'

点击率示例:

Azure Multi-Factor Authentication user states

Powershell script to fetch list of users with MFA status

identify users that were MFA configured:

Get-MsolUser -all | 
select UserPrincipalName, 
@{N="MFA Status"; E={ if( $_.StrongAuthenticationMethods.IsDefault -eq $true) {($_.StrongAuthenticationMethods|Where IsDefault -eq $True).MethodType} 
else { "Disabled"}}} | 
FT -AutoSize
相关问题