Add-AzureAssessmentTask doesn't support MFA parameter

Luca Fabbri 156 Reputation points
2022-09-12T20:03:43.63+00:00

Hello,
I discovered the Add-AzureAssessmentTask doesn't support the -MFA parameter (despite I can read it referenced in documentation).

> Get-Command Add-AzureAssessmentTask  
  
CommandType     Name                                               Version    Source  
-----------     ----                                               -------    ------  
Cmdlet          Add-AzureAssessmentTask                            8.0.1.1086 Microsoft.PowerShell.Oms.Assessments  

> Get-Help Add-AzureAssessmentTask  
  
NAME  
    Add-AzureAssessmentTask  
  
SYNTAX  
    Add-AzureAssessmentTask [-WorkingDirectory] <string> -ScheduledTaskUsername <string> -ScheduledTaskPassword  
    <securestring> [-AADUsername <string>] [-AADPassword <securestring>] [-ManagementGroup <string>] [-AssessmentId  
    <guid>] [-EnvironmentName <string>] [-RunWithManagedServiceAccount <bool>]  [<CommonParameters>]  
  
  
ALIASES  
    None  
  
  
REMARKS  
    None  
  

I have installed the latest version of Microsoft Monitoring Agent (MMA) v10.20.18067.0 available in Log Analytics workspaces.

This is my fault or it doesn't support the -MFA parameter anymore ?

Thank you,
Luca

Microsoft Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
21,371 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Luca Fabbri 156 Reputation points
    2022-09-25T07:52:39.83+00:00

    Hello,
    here the Microsoft's answer:

    The -MFA handle was removed on purpose as it is no longer needed, authentication is done using the MS Assessment App cert and key,
    MFA is fully supported while creating the app, there is no need to specify any cloud account when creating the task, you can simply run the Add-AzureAssessmentTask cmdlet without the parameter and it skips the cloud user step (the app info from the registry is auto detected when OMSAssessment runs)

    Bye,
    Luca

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.