Home
%3CLINGO-SUB%20id%3D%22lingo-sub-407109%22%20slang%3D%22en-US%22%3ERe%3A%20IT%20Pros%20can%20now%20easily%20connect%20to%20Microsoft%20Graph%20Security%20with%20the%20PowerShell%20Module!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-407109%22%20slang%3D%22en-US%22%3E%3CP%3EPlease%20provide%20details%20instructions%20how%20to%20register%20this%20thing%20%3Asmileysad%3A%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-457962%22%20slang%3D%22en-US%22%3ERe%3A%20IT%20Pros%20can%20now%20easily%20connect%20to%20Microsoft%20Graph%20Security%20with%20the%20PowerShell%20Module!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-457962%22%20slang%3D%22en-US%22%3E%3CP%3ECan%20you%20please%20provide%20more%20details%20on%20these%20steps%20including%20screen%20shots%3F%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3COL%3E%3CLI%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fauth-v2-service%231-register-your-app%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3ERegister%20your%20application%3C%2FA%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Efor%20this%20PowerShell%20Module%20in%20Azure%20AD%20in%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Faka.ms%2Fgraphsecurityauth%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Euser-delegated%20mode%3C%2FA%3E.%3C%2FLI%3E%3CLI%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fauth-v2-service%232-configure-permissions-for-microsoft-graph%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3EConfigure%20permissions%3C%2FA%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eand%20be%20sure%20to%20add%20the%20SecurityEvents.ReadWrite.All%20permission%20to%20your%20application.%20Get%20your%20Azure%20AD%20tenant%20administrator%20to%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fauth-v2-service%233-get-administrator-consent%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Egrant%20tenant%20administrator%20consent%3C%2FA%3E%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3Eto%20your%20application.%20This%20is%20a%20one-time%20activity%20unless%20permissions%20change%20for%20the%20application.%3C%2FLI%3E%3C%2FOL%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-458178%22%20slang%3D%22en-US%22%3ERe%3A%20IT%20Pros%20can%20now%20easily%20connect%20to%20Microsoft%20Graph%20Security%20with%20the%20PowerShell%20Module!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-458178%22%20slang%3D%22en-US%22%3E%3CP%3E%3CSUP%3EThere%20are%20a%20plethora%20of%20articles%20on%20creating%20App%20Registrations%20in%20AAD%20out%20there.%20Try%20this%20one%20from%20the%2030%20days%20of%20Microsoft%20Graph%20series%26nbsp%3B%3CSUB%3E%3CA%20href%3D%22https%3A%2F%2Fdeveloper.microsoft.com%2Fen-us%2Fgraph%2Fblogs%2F30daysmsgraph-day-9-azure-ad-applications-on-v2-endpoint%2F%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdeveloper.microsoft.com%2Fen-us%2Fgraph%2Fblogs%2F30daysmsgraph-day-9-azure-ad-applications-on-v2-endpoint%2F%3C%2FA%3E%3C%2FSUB%3E%3C%2FSUP%3E%3C%2FP%3E%0A%3CP%3E%3CFONT%20size%3D%221%22%3EThis%20the%20key%20difference%20will%20be%20using%20the%20Delegated%20Permissions%20rather%20than%20App%20Permissions%20and%20the%20specific%20permissions%20you%20request%26nbsp%3B%3C%2FFONT%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-458181%22%20slang%3D%22en-US%22%3ERe%3A%20IT%20Pros%20can%20now%20easily%20connect%20to%20Microsoft%20Graph%20Security%20with%20the%20PowerShell%20Module!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-458181%22%20slang%3D%22en-US%22%3E%3CP%3EDid%20all%20that%20and%20get%20%22AADSTS50011%3A%20The%20reply%20url%20specified%20in%20the%20request%20does%20not%20match%20the%20reply%20urls%20configured%20for%20the%20application%3A%22%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-459569%22%20slang%3D%22en-US%22%3ERe%3A%20IT%20Pros%20can%20now%20easily%20connect%20to%20Microsoft%20Graph%20Security%20with%20the%20PowerShell%20Module!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-459569%22%20slang%3D%22en-US%22%3E%3CP%3EThat%20suggest%20that%20the%20reply%20url%20you%20make%20the%20request%20to%20AAD%20with%20doesn't%20match%20what%20you%20configured%20in%20the%20app%20registration%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-459953%22%20slang%3D%22en-US%22%3ERe%3A%20IT%20Pros%20can%20now%20easily%20connect%20to%20Microsoft%20Graph%20Security%20with%20the%20PowerShell%20Module!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-459953%22%20slang%3D%22en-US%22%3E%3CP%3E%22%3CSPAN%3EThat%20suggest%20that%20the%20reply%20url%20you%20make%20the%20request%20to%20AAD%20with%20doesn't%20match%20what%20you%20configured%20in%20the%20app%20registration%22%20-%20I%20still%20don%3Bt%20get%20it%3F%3F%20I%20made%20the%20request%20via%20a%20PowerShell%20console%2C%20where%20do%20I%20set%20the%20reply%20address%20there%3F%20Also%20teh%20app%20registration%20URL's%20I%20entered%20don%3Bt%20matter%20do%20they%20as%20I%20want%20to%20use%20the%20PowerShell%20console%3F%3F%20Again%2C%20I%20don't%20understand%20how%20I%20configure%20an%20app%20registration%20for%20a%20PowerShell%20console.%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-461029%22%20slang%3D%22en-US%22%3ERe%3A%20IT%20Pros%20can%20now%20easily%20connect%20to%20Microsoft%20Graph%20Security%20with%20the%20PowerShell%20Module!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-461029%22%20slang%3D%22en-US%22%3E%3CP%3EThe%20way%20the%20OAuth%20flow%20works%20providing%20a%20matching%20redirect%20uri%20is%20required%2C%20so%20yes%2C%20they%20matter%20a%20great%20deal%20in%20the%20auth%20flow%2C%20they%20don't%20actaully%20need%20to%20be%20working%20URLs%2C%20just%20valid%20URIs%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EUpon%20inspecting%20the%20%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2FMicrosoft%2FMicrosoftGraphSecurity%2Fblob%2F58e02f9dcaae3f0e14f54c0ae293517109ea78b0%2FFunctions%2FGet-GraphSecurityAuthToken.ps1%23L114%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Escript%20that%20is%20used%20under%20the%20hood%3C%2FA%3E%20you%20need%20to%20configure%20the%20redirect%20uri%20in%20the%20AAD%20Application%20as%26nbsp%3B%3CSPAN%3Eurn%3Aietf%3Awg%3Aoauth%3A2.0%3Aoob%2C%20as%20this%20has%20been%20hardcoded.%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-463411%22%20slang%3D%22en-US%22%3ERe%3A%20IT%20Pros%20can%20now%20easily%20connect%20to%20Microsoft%20Graph%20Security%20with%20the%20PowerShell%20Module!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-463411%22%20slang%3D%22en-US%22%3E%3CP%3EOk%2C%20that%20seems%20to%20have%20done%20the%20trick%20here%2C%20although%20I%20can't%20add%20it%20as%20a%20web%20request%20I%20have%20been%20able%20to%20add%20that%20another%20way%20and%20test%20that%20it%20works.%20Really%20appreciate%20that.%20I'm%20going%20to%20blog%20about%20this%20and%20make%20it%20easier%20for%20people%20who%20aren't%20devs%20to%20follow!%20But%20again%2C%20thanks.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-463632%22%20slang%3D%22en-US%22%3ERe%3A%20IT%20Pros%20can%20now%20easily%20connect%20to%20Microsoft%20Graph%20Security%20with%20the%20PowerShell%20Module!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-463632%22%20slang%3D%22en-US%22%3E%3CDIV%20class%3D%22lia-message-author-avatar%20lia-component-author-avatar%20lia-component-message-view-widget-author-avatar%20UserAvatarWrapper%22%20style%3D%22box-sizing%3A%20border-box%3B%20color%3A%20%23333333%3B%20display%3A%20inline-block%3B%20float%3A%20left%3B%20font-family%3A%20%26amp%3Bquot%3B%20segoeui%26amp%3Bquot%3B%2C%26amp%3Bquot%3Blato%26amp%3Bquot%3B%2C%26amp%3Bquot%3Bhelvetica%20neue%26amp%3Bquot%3B%2Chelvetica%2Carial%2Csans-serif%3B%20font-size%3A%2014px%3B%20font-style%3A%20normal%3B%20font-variant%3A%20normal%3B%20font-weight%3A%20300%3B%20letter-spacing%3A%20normal%3B%20orphans%3A%202%3B%20padding-right%3A%2010px%3B%20position%3A%20relative%3B%20text-align%3A%20left%3B%20text-decoration%3A%20none%3B%20text-indent%3A%200px%3B%20text-transform%3A%20none%3B%20-webkit-text-stroke-width%3A%200px%3B%20white-space%3A%20normal%3B%20word-spacing%3A%200px%3B%22%3E%0A%3CDIV%20class%3D%22UserAvatar%20lia-user-avatar%22%20style%3D%22box-sizing%3A%20border-box%3B%20font-family%3A%20%26amp%3Bquot%3B%22%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F72532%22%20target%3D%22_blank%22%3E%40Robert%20Crane%3C%2FA%3E%20%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F27468%22%20target%3D%22_blank%22%3E%40Gavin%20Barron%3C%2FA%3E%20-%26nbsp%3B%3C%2FDIV%3E%0A%3C%2FDIV%3E%0A%3CP%3EApologize%20for%20the%20clarity%20issues%20and%20inconvenience%20caused%20with%20the%20application%20registration%20process.%20The%20links%20in%20the%20steps%20point%20to%20the%20Azure%20Active%20Directory%20official%20documentation%20that%20has%20screenshots%2C%20but%20then%20I%20observed%20that%20the%20native%20app%20registration%20step%20is%20missing%20in%20that%20documentation.%20To%20get%20unblocked%20with%20this%20as%20part%20of%20'Register%20your%20application'%20step%3A%3C%2FP%3E%0A%3CP%3Ea.%20Select%20'Add%20Platform'%20(under%20Platforms)%3C%2FP%3E%0A%3CP%3Eb.%20Select%20'Native%20Application'%26nbsp%3B%3C%2FP%3E%0A%3CP%3Ec.%20Retain%20redirect%20URI%20as%20'%3CSTRONG%3E%3CSPAN%20style%3D%22text-align%3A%20left%3B%20color%3A%20%23000000%3B%20text-transform%3A%20none%3B%20text-indent%3A%200px%3B%20letter-spacing%3A%20normal%3B%20font-size%3A%20100%25%3B%20font-style%3A%20normal%3B%20font-variant%3A%20normal%3B%20text-decoration%3A%20none%3B%20word-spacing%3A%200px%3B%20display%3A%20inline%3B%20white-space%3A%20normal%3B%20box-sizing%3A%20border-box%3B%20orphans%3A%202%3B%20float%3A%20none%3B%20-webkit-text-stroke-width%3A%200px%3B%20background-color%3A%20%23ffffff%3B%22%3Eurn%3Aietf%3Awg%3Aoauth%3A2.0%3Aoob%3C%2FSPAN%3E%3C%2FSTRONG%3E'%20-%20this%20is%20needed%20for%20desktop%20application%20redirect%20to%20work.%26nbsp%3B%3C%2FP%3E%0A%3CP%3EProceed%20with%20remaining%20registration%20steps.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWe've%20updated%20the%20GitHub%20repo%20%3CFONT%20style%3D%22background-color%3A%20%23ffffff%3B%22%3E%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2FMicrosoft%2FMicrosoftGraphSecurity%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fgithub.com%2FMicrosoft%2FMicrosoftGraphSecurity%3C%2FA%3E%20%3C%2FFONT%3Eto%20reflect%20these%20steps%20and%20I'll%20update%20the%20blogpost%20to%20include%20this%20step%20as%20well.%20Thanks!%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-463779%22%20slang%3D%22en-US%22%3ERe%3A%20IT%20Pros%20can%20now%20easily%20connect%20to%20Microsoft%20Graph%20Security%20with%20the%20PowerShell%20Module!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-463779%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F164339%22%20target%3D%22_blank%22%3E%40Preeti%20Krishna%3C%2FA%3E%26nbsp%3B%26nbsp%3BHere%20is%20my%20step%20by%20step%20blog%20post%20that%20will%20probably%20help%20others%20in%20getting%20this%20working%20-%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fblog.ciaops.com%2F2019%2F04%2F17%2Fusing-interactive-powershell-to-access-the-microsoft-graph%2F%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fblog.ciaops.com%2F2019%2F04%2F17%2Fusing-interactive-powershell-to-access-the-microsoft-graph%2F%3C%2FA%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-482233%22%20slang%3D%22en-US%22%3ERe%3A%20IT%20Pros%20can%20now%20easily%20connect%20to%20Microsoft%20Graph%20Security%20with%20the%20PowerShell%20Module!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-482233%22%20slang%3D%22en-US%22%3E%3CP%3EThis%20looks%20like%20basic%20auth%20prompt.%20Am%20I%20correct%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-399308%22%20slang%3D%22en-US%22%3EIT%20Pros%20can%20now%20easily%20connect%20to%20Microsoft%20Graph%20Security%20with%20the%20PowerShell%20Module!%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-399308%22%20slang%3D%22en-US%22%3E%3CP%3EWe%20now%20have%20a%20new%20%3CA%20href%3D%22https%3A%2F%2Fwww.powershellgallery.com%2Fpackages%2FMicrosoftGraphSecurity%2F1.0.0%22%20target%3D%22_self%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3EPowerShell%20module%20for%20the%20Microsoft%20Graph%20Security%20API%3C%2FA%3E%20that%20makes%20it%20easier%20for%20IT%20Pros%20to%20connect%20with%20the%20API%20from%20a%20PowerShell%20console.%20This%20module%20is%20available%20on%20the%20PowerShell%20gallery%2C%20thanks%20to%20a%3CSPAN%3E%20%3CA%20href%3D%22https%3A%2F%2Faka.ms%2Fgraphsecurityapicode%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ecommunity%3C%2FA%3E%20contribution%20%3C%2FSPAN%3Efrom%20the%20Microsoft%20Cloud%20Security%E2%80%99s%20Customer%20Experience%20Engineering%20team.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThe%20Microsoft%20Graph%20Security%20API%20connects%20multiple%20security%20solutions%20to%20enable%20easier%20correlation%20of%20alerts%2C%20provide%20access%20to%20rich%20contextual%20information%2C%20simplify%20automations%20and%20investigations.%20This%20empowers%20organizations%20to%20quickly%20gain%20insights%20and%20take%20actions%20across%20their%20security%20products%2C%20while%20reducing%20the%20cost%20and%20complexity%20of%20building%20and%20maintaining%20multiple%20integrations.%20For%20further%20details%20on%20integrating%20with%20the%20Microsoft%20Graph%20Security%20API%2C%20%3CA%20href%3D%22https%3A%2F%2Faka.ms%2Fgraphsecuritydocs%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3Elearn%20about%20the%20API%3C%2FA%3E%20and%20%3CA%20href%3D%22https%3A%2F%2Faka.ms%2Fgraphsecurityalerts%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3Eaccess%20the%20schema%3C%2FA%3E.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CH1%20id%3D%22toc-hId-1898412546%22%20id%3D%22toc-hId-1898412546%22%3EGetting%20Started%3C%2FH1%3E%0A%3CP%3EUse%20this%20module%20to%20get%20access%20to%20security%20alerts%20and%20Secure%20Score%20information%20in%20your%20Azure%20Active%20Directory%20(Azure%20AD)%20tenant%20across%20different%20security%20products.%20Refer%20to%20the%20%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2FMicrosoft%2FMicrosoftGraphSecurity%2Ftree%2Fmaster%2FDocs%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3Edocumentation%3C%2FA%3E%20for%20further%20details.%3C%2FP%3E%0A%3COL%3E%0A%3CLI%3EEnsure%20you%20have%20PowerShell%20v5%20or%20above%20(standard%20on%20Windows%2010).%3C%2FLI%3E%0A%3CLI%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fauth-v2-service%231-register-your-app%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3ERegister%20your%20application%3C%2FA%3E%20for%20this%20PowerShell%20Module%20in%20Azure%20AD%20in%20%3CA%20href%3D%22https%3A%2F%2Faka.ms%2Fgraphsecurityauth%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3Euser-delegated%20mode%3C%2FA%3E.%20As%20part%20of%20this%2C%3CP%20style%3D%22box-sizing%3A%20border-box%3B%20color%3A%20%23333333%3B%20font-family%3A%20%26amp%3Bquot%3B%20segoeui%26amp%3Bquot%3B%2C%26amp%3Bquot%3Blato%26amp%3Bquot%3B%2C%26amp%3Bquot%3Bhelvetica%20neue%26amp%3Bquot%3B%2Chelvetica%2Carial%2Csans-serif%3B%20font-size%3A%2016px%3B%20font-style%3A%20normal%3B%20font-variant%3A%20normal%3B%20font-weight%3A%20300%3B%20letter-spacing%3A%20normal%3B%20orphans%3A%202%3B%20text-align%3A%20left%3B%20text-decoration%3A%20none%3B%20text-indent%3A%200px%3B%20text-transform%3A%20none%3B%20-webkit-text-stroke-width%3A%200px%3B%20white-space%3A%20normal%3B%20word-spacing%3A%200px%3B%20margin%3A%200px%3B%22%3Ea.%20Select%20'Add%20Platform'%20(under%20Platforms)%3C%2FP%3E%0A%3CP%20style%3D%22box-sizing%3A%20border-box%3B%20color%3A%20%23333333%3B%20font-family%3A%20%26amp%3Bquot%3B%20segoeui%26amp%3Bquot%3B%2C%26amp%3Bquot%3Blato%26amp%3Bquot%3B%2C%26amp%3Bquot%3Bhelvetica%20neue%26amp%3Bquot%3B%2Chelvetica%2Carial%2Csans-serif%3B%20font-size%3A%2016px%3B%20font-style%3A%20normal%3B%20font-variant%3A%20normal%3B%20font-weight%3A%20300%3B%20letter-spacing%3A%20normal%3B%20orphans%3A%202%3B%20text-align%3A%20left%3B%20text-decoration%3A%20none%3B%20text-indent%3A%200px%3B%20text-transform%3A%20none%3B%20-webkit-text-stroke-width%3A%200px%3B%20white-space%3A%20normal%3B%20word-spacing%3A%200px%3B%20margin%3A%200px%3B%22%3Eb.%20Select%20'Native%20Application'%26nbsp%3B%3C%2FP%3E%0A%3CP%20style%3D%22box-sizing%3A%20border-box%3B%20color%3A%20%23333333%3B%20font-family%3A%20%26amp%3Bquot%3B%20segoeui%26amp%3Bquot%3B%2C%26amp%3Bquot%3Blato%26amp%3Bquot%3B%2C%26amp%3Bquot%3Bhelvetica%20neue%26amp%3Bquot%3B%2Chelvetica%2Carial%2Csans-serif%3B%20font-size%3A%2016px%3B%20font-style%3A%20normal%3B%20font-variant%3A%20normal%3B%20font-weight%3A%20300%3B%20letter-spacing%3A%20normal%3B%20orphans%3A%202%3B%20text-align%3A%20left%3B%20text-decoration%3A%20none%3B%20text-indent%3A%200px%3B%20text-transform%3A%20none%3B%20-webkit-text-stroke-width%3A%200px%3B%20white-space%3A%20normal%3B%20word-spacing%3A%200px%3B%20margin%3A%200px%3B%22%3Ec.%20Retain%20redirect%20URI%20as%20'%3CSTRONG%20style%3D%22box-sizing%3A%20border-box%3B%20font-weight%3A%20bold%3B%22%3E%3CSPAN%20style%3D%22background-color%3A%20%23ffffff%3B%20box-sizing%3A%20border-box%3B%20color%3A%20%23000000%3B%20display%3A%20inline%3B%20float%3A%20none%3B%20font-family%3A%20%26amp%3Bquot%3B%20segoeui%26amp%3Bquot%3B%2C%26amp%3Bquot%3Blato%26amp%3Bquot%3B%2C%26amp%3Bquot%3Bhelvetica%20neue%26amp%3Bquot%3B%2Chelvetica%2Carial%2Csans-serif%3B%20font-size%3A%20100%25%3B%20font-style%3A%20normal%3B%20font-variant%3A%20normal%3B%20letter-spacing%3A%20normal%3B%20orphans%3A%202%3B%20text-align%3A%20left%3B%20text-decoration%3A%20none%3B%20text-indent%3A%200px%3B%20text-transform%3A%20none%3B%20-webkit-text-stroke-width%3A%200px%3B%20white-space%3A%20normal%3B%20word-spacing%3A%200px%3B%22%3Eurn%3Aietf%3Awg%3Aoauth%3A2.0%3Aoob%3C%2FSPAN%3E%3C%2FSTRONG%3E'%20-%20this%20is%20needed%20for%20desktop%20application%20redirect%20to%20work.%26nbsp%3B%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fauth-v2-service%232-configure-permissions-for-microsoft-graph%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3EConfigure%20permissions%3C%2FA%3E%20and%20be%20sure%20to%20add%20the%20SecurityEvents.ReadWrite.All%20permission%20to%20your%20application.%20Get%20your%20Azure%20AD%20tenant%20administrator%20to%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fgraph%2Fauth-v2-service%233-get-administrator-consent%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3Egrant%20tenant%20administrator%20consent%3C%2FA%3E%20to%20your%20application.%20This%20is%20a%20one-time%20activity%20unless%20permissions%20change%20for%20the%20application.%3C%2FLI%3E%0A%3CLI%3EOpen%20your%20PowerShell%20terminal%20as%20an%20administrator%20and%20install%20the%20module%20by%20running%20the%20%3CFONT%20color%3D%22%230000ff%22%3E%3CSTRONG%3EInstall-Module%20MicrosoftGraphSecurity%3C%2FSTRONG%3E%20%3C%2FFONT%3Ecommand%20as%20shown%20in%20the%20diagram%20below%3A%3C%2FLI%3E%0A%3C%2FOL%3E%0A%3CP%3E*If%20this%20is%20your%20first%20time%20installing%20a%20module%2C%20you%20will%20be%20prompted%20to%20install%20the%20Nuget%20Package%20Provider.%20%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F105890i703F40490D4B34A3%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22InstallPS_Module.PNG%22%20title%3D%22InstallPS_Module.PNG%22%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-caption%22%20onclick%3D%22event.preventDefault()%3B%22%3EInstall%20PowerShell%20Module%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CH1%20id%3D%22toc-hId--653744415%22%20id%3D%22toc-hId--653744415%22%3EAuthentication%3C%2FH1%3E%0A%3CP%3EYou%E2%80%99ll%20need%20to%20authenticate%20before%20you%20can%20start%20getting%20and%20updating%20data%20from%20Microsoft%20Graph%20Security%20API.%20Authentication%20will%20be%20triggered%20upon%20initial%20data%20access%20or%20when%20authentication%20expires.%3C%2FP%3E%0A%3COL%3E%0A%3CLI%3EEnter%20%3CFONT%20color%3D%22%230000ff%22%3E%3CSTRONG%3EGet-GraphSecurityAlert%3C%2FSTRONG%3E%3C%2FFONT%3E%3C%2FLI%3E%0A%3CLI%3EEnter%20your%20username%20and%20the%20application%20ID%20(from%20the%20application%20registration%20process%20in%20getting%20started%20section)%20when%20prompted%2C%20as%20illustrated%20below.%20%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F105891i3BE8DD075C781B8E%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22GetAlerts.PNG%22%20title%3D%22GetAlerts.PNG%22%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-caption%22%20onclick%3D%22event.preventDefault()%3B%22%3EAuthentication%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FLI%3E%0A%3CLI%3E%26nbsp%3BEnter%20your%20password%20when%20prompted.%20Upon%20successful%20authentication%2C%20the%20connection%20with%20Microsoft%20Graph%20Security%20API%20is%20established%20and%20you%20will%20get%20a%20list%20of%20alerts.%3CH1%20id%3D%22toc-hId-1089065920%22%20id%3D%22toc-hId-1089065920%22%3E%26nbsp%3B%3C%2FH1%3E%0A%3CH1%20id%3D%22toc-hId--1463091041%22%20id%3D%22toc-hId--1463091041%22%3EUser%20Scenarios%3C%2FH1%3E%0A%3CP%3EThis%20covers%20a%20representative%20set%20of%20scenarios.%20Refer%20to%20%3CA%20href%3D%22https%3A%2F%2Faka.ms%2Fgraphsecuritypowershellmoduledocs%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ethe%20documentation%3C%2FA%3E%20for%20the%20complete%20list%20of%20supported%20PowerShell%20command%20line%20switches%20associated%20with%20each%20command%20to%20tailor%20this%20for%20your%20scenario.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CH2%20id%3D%22toc-hId-83205789%22%20id%3D%22toc-hId-83205789%22%3EGet%20latest%20alerts%20for%20Security%20Management%3C%2FH2%3E%0A%3CP%3EYou%20can%20get%20top%20alerts%20using%20this%20module%20by%20the%20command%20%3CFONT%20color%3D%22%230000ff%22%3E%3CSTRONG%3EGet-GraphSecurityAlert%20-top%201%3C%2FSTRONG%3E%3C%2FFONT%3E.%20This%20returns%20the%20recent%20most%20alert%20received%20from%20each%20of%20the%20security%20products%20running%20in%20your%20Azure%20AD%20tenant%20%3CA%20href%3D%22https%3A%2F%2Faka.ms%2Fgraphsecurityalerts%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3Esupported%20by%20the%20Microsoft%20Graph%20Security%20API%3C%2FA%3E.%20This%20enables%20you%20to%20correlate%20recent%20suspicious%20patterns%20raised%20by%20different%20security%20products.%20%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F105892iB73EEDC808C8F6D6%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22GetAlerts_postauth.PNG%22%20title%3D%22GetAlerts_postauth.PNG%22%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-caption%22%20onclick%3D%22event.preventDefault()%3B%22%3EGet%20alerts%20for%20security%20management%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CH2%20id%3D%22toc-hId-1826016124%22%20id%3D%22toc-hId-1826016124%22%3EInvestigate%20alerts%20associated%20with%20a%20user%3C%2FH2%3E%0A%3CP%3EYou%20can%20add%20multiple%20command%20line%20switches%20to%20get%20alerts%20across%20different%20security%20products%20filtered%20by%20user%20principal%20name%2C%20for%20example%2C%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CFONT%20color%3D%22%230000ff%22%3E%3CSTRONG%3EGet-GraphSecurityAlert%20-userPrincipalName%20%3C%2FSTRONG%3E%3CEM%3E%3CENTER%20the%3D%22%22%20value%3D%22%22%3E%20%3C%2FENTER%3E%3C%2FEM%3E%3CSTRONG%3E-severity%20%3C%2FSTRONG%3E%3CEM%3Emedium%20%3C%2FEM%3E%3CSTRONG%3E-Verbose%20%7C%20select%20title%2C%20status%2C%20description%2C%20assignedTo%2C%20severity%2C%20userStates%3C%2FSTRONG%3E%3C%2FFONT%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3Eas%20illustrated%20below.%20This%20enables%20initial%20investigations%20where%20suspicious%20user%20activities%20reported%20by%20different%20security%20products%20can%20be%20plotted%20to%20understand%20where%20to%20plan%20the%20next%20level%20of%20investigations.%20%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F105893i4ECC34B938CD1D16%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22InvestigationQueries.PNG%22%20title%3D%22InvestigationQueries.PNG%22%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-caption%22%20onclick%3D%22event.preventDefault()%3B%22%3EInvestigate%20alerts%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CH2%20id%3D%22toc-hId--726140837%22%20id%3D%22toc-hId--726140837%22%3ECustomize%20get%20alerts%20to%20your%20scenario%3C%2FH2%3E%0A%3CP%3ERun%20the%20%3CFONT%20color%3D%22%230000ff%22%3E%3CSTRONG%3EGet-GraphSecurityAlert%20-%3CCTRLKEY%3E%3CSPACE%3E%3C%2FSPACE%3E%3C%2FCTRLKEY%3E%3C%2FSTRONG%3E%20%3C%2FFONT%3Ecommand%20to%20get%20a%20list%20of%20all%20properties%20that%20you%20can%20filter%20to%20get%20your%20alerts%20as%20illustrated%20in%20the%20following%20diagram.%20Navigate%20to%20know%20supported%20types%20for%20each%20of%20these%20switches%20using%20your%20arrow%20keys.%20For%20example%2C%20in%20the%20diagram%20below%20we%20can%20see%20-Version%20switch%20expects%20a%20string%20type%20value.%20You%20can%20build%20your%20commands%20using%20different%20%3CA%20href%3D%22https%3A%2F%2Faka.ms%2Fgraphsecurityalertschema%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3Eproperty%20values%3C%2FA%3E%20available%20to%20get%20alerts%20based%20on%20your%20scenario%20for%20customized%20security%20management%20and%20investigations.%20%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F105894i74A3F8F05D9AA65F%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22ListofGetAlerts.PNG%22%20title%3D%22ListofGetAlerts.PNG%22%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-caption%22%20onclick%3D%22event.preventDefault()%3B%22%3EList%20of%20switches%20for%20Get-GraphSecurityAlert%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CH2%20id%3D%22toc-hId-1016669498%22%20id%3D%22toc-hId-1016669498%22%3EUpdate%20alerts%20for%20better%20security%20management%3C%2FH2%3E%0A%3CP%3EYou%20can%20update%20alerts%20by%20the%20%3CFONT%20color%3D%22%230000ff%22%3E%3CSTRONG%3ESet-GraphSecurityAlert%20-id%20%3C%2FSTRONG%3E%3CEM%3E%3CENTER%20the%3D%22%22%20value%3D%22%22%3E%3C%2FENTER%3E%3C%2FEM%3E%20%3C%2FFONT%3Ecommand.%20You%20can%20update%20the%20status%20of%20the%20alert%20to%20resolved%20as%20shown%20in%20this%20example%20below%20or%20even%20assign%20an%20alert%20for%20investigation%20or%20tag%20alerts%20to%20filter%20those%20as%20needed%20for%20better%20security%20management.%3C%2FP%3E%0A%3CP%3ERun%20the%20%3CFONT%20color%3D%22%230000ff%22%3E%3CSTRONG%3ESet-GraphSecurityAlert%20-%3CCTRLKEY%3E%3CSPACE%3E%3C%2FSPACE%3E%3C%2FCTRLKEY%3E%3C%2FSTRONG%3E%20%3C%2FFONT%3Ecommand%20to%20get%20a%20list%20of%20all%20properties%20that%20you%20can%20use%20to%20build%20your%20update%20alert%20command.%20%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F105895iDC941AC9596AF5A6%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22SetAlerts.PNG%22%20title%3D%22SetAlerts.PNG%22%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-caption%22%20onclick%3D%22event.preventDefault()%3B%22%3EUpdate%20alert%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CH2%20id%3D%22toc-hId--1535487463%22%20id%3D%22toc-hId--1535487463%22%3EGet%20Secure%20Score%20for%20understanding%20security%20posture%3C%2FH2%3E%0A%3CP%3EYou%20can%20also%20get%20%3CA%20href%3D%22https%3A%2F%2Faka.ms%2Fgraphsecurescore%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3Esecure%20score%3C%2FA%3E%20information%20by%20the%20%3CFONT%20color%3D%22%230000ff%22%3E%3CSTRONG%3EGet-GraphSecuritySecureScore%3C%2FSTRONG%3E%20%3C%2FFONT%3Ecommand%20as%20illustrated%20below%20to%20get%20details%20on%20the%20security%20posture%20of%20your%20organization%20and%20to%20determine%20what%20remediations%20are%20needed%20to%20improve%20the%20score%20over%20time.%3C%2FP%3E%0A%3CP%3ERun%20the%20%3CFONT%20color%3D%22%230000ff%22%3E%3CSTRONG%3EGet-GraphSecuritySecureScore%20-%3CCTRLKEY%3E%3CSPACE%3E%3C%2FSPACE%3E%3C%2FCTRLKEY%3E%3C%2FSTRONG%3E%20%3C%2FFONT%3Ecommand%20to%20get%20a%20list%20of%20all%20switches%20that%20you%20can%20use%20to%20build%20your%20secure%20score%20command.%20%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F105899i087B04FAE8C891EE%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22GetSecureScore.PNG%22%20title%3D%22GetSecureScore.PNG%22%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-caption%22%20onclick%3D%22event.preventDefault()%3B%22%3EGet%20Secure%20Score%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CH1%20id%3D%22toc-hId-403836377%22%20id%3D%22toc-hId-403836377%22%3EClosing%3C%2FH1%3E%0A%3CP%3ETry%20out%20the%20new%20Microsoft%20Graph%20Security%20API%20PowerShell%20module%20and%20provide%20your%20feedback%20by%20%3CA%20href%3D%22https%3A%2F%2Faka.ms%2Fgraphsecuritypowershellmodulefileissue%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%22%3Efiling%20a%20GitHub%20issue%20in%20the%20PowerShell%20module%20repo%3C%2FA%3E.%20%26nbsp%3B%20%26nbsp%3B%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FOL%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-TEASER%20id%3D%22lingo-teaser-399308%22%20slang%3D%22en-US%22%3E%3CP%3ECheck%20out%20the%20new%20%3CA%20href%3D%22https%3A%2F%2Fwww.powershellgallery.com%2Fpackages%2FMicrosoftGraphSecurity%2F1.0.0%22%20target%3D%22_self%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%22%3EPowerShell%20module%20for%20the%20Microsoft%20Graph%20Security%20API%3C%2FA%3E%20that%20makes%20it%20easier%20for%20IT%20Pros%20to%20connect%20with%20the%20API%20from%20a%20PowerShell%20console!%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F102316i6BC900E3C9618236%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22powershell_blog_teaser.png%22%20title%3D%22powershell_blog_teaser.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-TEASER%3E%3CLINGO-LABS%20id%3D%22lingo-labs-399308%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3ESecurity%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E
Microsoft

We now have a new PowerShell module for the Microsoft Graph Security API that makes it easier for IT Pros to connect with the API from a PowerShell console. This module is available on the PowerShell gallery, thanks to a community contribution from the Microsoft Cloud Security’s Customer Experience Engineering team.

 

The Microsoft Graph Security API connects multiple security solutions to enable easier correlation of alerts, provide access to rich contextual information, simplify automations and investigations. This empowers organizations to quickly gain insights and take actions across their security products, while reducing the cost and complexity of building and maintaining multiple integrations. For further details on integrating with the Microsoft Graph Security API, learn about the API and access the schema.

 

Getting Started

Use this module to get access to security alerts and Secure Score information in your Azure Active Directory (Azure AD) tenant across different security products. Refer to the documentation for further details.

  1. Ensure you have PowerShell v5 or above (standard on Windows 10).
  2. Register your application for this PowerShell Module in Azure AD in user-delegated mode. As part of this,

    a. Select 'Add Platform' (under Platforms)

    b. Select 'Native Application' 

    c. Retain redirect URI as 'urn:ietf:wg:oauth:2.0:oob' - this is needed for desktop application redirect to work. 

  3. Configure permissions and be sure to add the SecurityEvents.ReadWrite.All permission to your application. Get your Azure AD tenant administrator to grant tenant administrator consent to your application. This is a one-time activity unless permissions change for the application.
  4. Open your PowerShell terminal as an administrator and install the module by running the Install-Module MicrosoftGraphSecurity command as shown in the diagram below:

*If this is your first time installing a module, you will be prompted to install the Nuget Package Provider.  

InstallPS_Module.PNGInstall PowerShell Module

Authentication

You’ll need to authenticate before you can start getting and updating data from Microsoft Graph Security API. Authentication will be triggered upon initial data access or when authentication expires.

  1. Enter Get-GraphSecurityAlert
  2. Enter your username and the application ID (from the application registration process in getting started section) when prompted, as illustrated below. GetAlerts.PNGAuthentication
  3.  Enter your password when prompted. Upon successful authentication, the connection with Microsoft Graph Security API is established and you will get a list of alerts.

     

    User Scenarios

    This covers a representative set of scenarios. Refer to the documentation for the complete list of supported PowerShell command line switches associated with each command to tailor this for your scenario.

     

    Get latest alerts for Security Management

    You can get top alerts using this module by the command Get-GraphSecurityAlert -top 1. This returns the recent most alert received from each of the security products running in your Azure AD tenant supported by the Microsoft Graph Security API. This enables you to correlate recent suspicious patterns raised by different security products. GetAlerts_postauth.PNGGet alerts for security management

    Investigate alerts associated with a user

    You can add multiple command line switches to get alerts across different security products filtered by user principal name, for example,

     

    Get-GraphSecurityAlert -userPrincipalName <enter the value> -severity medium -Verbose | select title, status, description, assignedTo, severity, userStates

     

    as illustrated below. This enables initial investigations where suspicious user activities reported by different security products can be plotted to understand where to plan the next level of investigations. InvestigationQueries.PNGInvestigate alerts

    Customize get alerts to your scenario

    Run the Get-GraphSecurityAlert -<ctrlkey><space> command to get a list of all properties that you can filter to get your alerts as illustrated in the following diagram. Navigate to know supported types for each of these switches using your arrow keys. For example, in the diagram below we can see -Version switch expects a string type value. You can build your commands using different property values available to get alerts based on your scenario for customized security management and investigations. ListofGetAlerts.PNGList of switches for Get-GraphSecurityAlert

    Update alerts for better security management

    You can update alerts by the Set-GraphSecurityAlert -id <enter the value> command. You can update the status of the alert to resolved as shown in this example below or even assign an alert for investigation or tag alerts to filter those as needed for better security management.

    Run the Set-GraphSecurityAlert -<ctrlkey><space> command to get a list of all properties that you can use to build your update alert command. SetAlerts.PNGUpdate alert

    Get Secure Score for understanding security posture

    You can also get secure score information by the Get-GraphSecuritySecureScore command as illustrated below to get details on the security posture of your organization and to determine what remediations are needed to improve the score over time.

    Run the Get-GraphSecuritySecureScore -<ctrlkey><space> command to get a list of all switches that you can use to build your secure score command. GetSecureScore.PNGGet Secure Score

    Closing

    Try out the new Microsoft Graph Security API PowerShell module and provide your feedback by filing a GitHub issue in the PowerShell module repo.    

 

11 Comments
Occasional Contributor

Please provide details instructions how to register this thing :smileysad:

Regular Visitor

Can you please provide more details on these steps including screen shots??

 

  1. Register your application for this PowerShell Module in Azure AD in user-delegated mode.
  2. Configure permissions and be sure to add the SecurityEvents.ReadWrite.All permission to your application. Get your Azure AD tenant administrator to grant tenant administrator consent to your application. This is a one-time activity unless permissions change for the application.

There are a plethora of articles on creating App Registrations in AAD out there. Try this one from the 30 days of Microsoft Graph series https://developer.microsoft.com/en-us/graph/blogs/30daysmsgraph-day-9-azure-ad-applications-on-v2-en...

This the key difference will be using the Delegated Permissions rather than App Permissions and the specific permissions you request 

Regular Visitor

Did all that and get "AADSTS50011: The reply url specified in the request does not match the reply urls configured for the application:"

That suggest that the reply url you make the request to AAD with doesn't match what you configured in the app registration

Regular Visitor

"That suggest that the reply url you make the request to AAD with doesn't match what you configured in the app registration" - I still don;t get it?? I made the request via a PowerShell console, where do I set the reply address there? Also teh app registration URL's I entered don;t matter do they as I want to use the PowerShell console?? Again, I don't understand how I configure an app registration for a PowerShell console.

The way the OAuth flow works providing a matching redirect uri is required, so yes, they matter a great deal in the auth flow, they don't actaully need to be working URLs, just valid URIs

 

Upon inspecting the script that is used under the hood you need to configure the redirect uri in the AAD Application as urn:ietf:wg:oauth:2.0:oob, as this has been hardcoded.

 

 

Regular Visitor

Ok, that seems to have done the trick here, although I can't add it as a web request I have been able to add that another way and test that it works. Really appreciate that. I'm going to blog about this and make it easier for people who aren't devs to follow! But again, thanks.

Microsoft

Apologize for the clarity issues and inconvenience caused with the application registration process. The links in the steps point to the Azure Active Directory official documentation that has screenshots, but then I observed that the native app registration step is missing in that documentation. To get unblocked with this as part of 'Register your application' step:

a. Select 'Add Platform' (under Platforms)

b. Select 'Native Application' 

c. Retain redirect URI as 'urn:ietf:wg:oauth:2.0:oob' - this is needed for desktop application redirect to work. 

Proceed with remaining registration steps.

 

We've updated the GitHub repo https://github.com/Microsoft/MicrosoftGraphSecurity to reflect these steps and I'll update the blogpost to include this step as well. Thanks!

 

 

Regular Visitor

@Preeti Krishna  Here is my step by step blog post that will probably help others in getting this working - https://blog.ciaops.com/2019/04/17/using-interactive-powershell-to-access-the-microsoft-graph/

This looks like basic auth prompt. Am I correct?