12Knocksinna / Office365itpros

Office 365 for IT Pros PowerShell examples
MIT License
1.28k stars 567 forks source link

ReportMFAStatusUsers - MFA Report data is incorrect if a user has multiple auth types in methods #45

Closed kkalicharan closed 2 years ago

kkalicharan commented 2 years ago

This is what fixed it. Switch ($Methods) { 'Fido2' { $MFAStatus = "Enabled"; break } 'PhoneAuthentication' { $MFAStatus = "Enabled"; break } 'AuthenticatorApp' { $MFAStatus = "Enabled"; break } 'Passwordless' { $MFAStatus = "Enabled"; break } Default { $MFAStatus = "check!"; break } } # End Switch