Skip to content

Forge-UserAgent : The term 'Forge-UserAgent' is not recognized as the name of a cmdlet, function, script file, or operable program.  #14

@mezzofix

Description

@mezzofix

When executing Invoke-DumpOWAMailboxViaMSGraphApi getting:

Forge-UserAgent : The term 'Forge-UserAgent' is not recognized as the name of a cmdlet, function, script file, or operable program. 
Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
At C:\Users\me\OneDrive\Pulpit\device_code\TokenTactics\modules\OutlookEmailAbuse.ps1:108 char:30
+                 $UserAgent = Forge-UserAgent -Device $Device
+                              ~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (Forge-UserAgent:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

Invoke-RestMethod : Object reference not set to an instance of an object.
At C:\Users\me\OneDrive\Pulpit\device_code\TokenTactics\modules\OutlookEmailAbuse.ps1:133 char:21
+ ... $response = Invoke-RestMethod -Uri $url -ContentType "application/jso ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [Invoke-RestMethod], NullReferenceException
    + FullyQualifiedErrorId : System.NullReferenceException,Microsoft.PowerShell.Commands.InvokeRestMethodCommand

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions