%3CLINGO-SUB%20id%3D%22lingo-sub-1180208%22%20slang%3D%22en-US%22%3EClosing%20an%20Incident%20in%20Azure%20Sentinel%20and%20Dismissing%20an%20Alert%20in%20Azure%20Security%20Center%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1180208%22%20slang%3D%22en-US%22%3E%3CP%3EAs%20we%20are%20exploring%20automation%20scenarios%20within%20Azure%20Security%20%3CSPAN%3E%2C%3C%2FSPAN%3E%20we%20come%20across%20an%20unsolved%20mystery.%20When%20I%20use%20Azure%20Security%20Center%20connector%20into%20Azure%20Sentinel%20and%20generate%20Incidents%2C%20what%20happens%20when%20I%20close%20my%20Azure%20Sentinel%20Incident%2C%20does%20it%20close%20the%20related%20Azure%20Security%20Center%20alert%3F%3C%2FP%3E%0A%3CP%3EThe%20short%20of%20this%20is%20it%20does%20not.%20The%20Azure%20Sentinel%20Incident%20closes%20but%20the%20ASC%20Alert%20remains%20active.%20You%20have%20the%20option%20to%20then%20dismiss%20the%20ASC%20Alert%20within%20the%20ASC%20Portal.%20Sounds%20like%20an%20extra%20step%20to%20keep%20these%20systems%20synchronized.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EHere%20is%20where%20Logic%20Apps%20comes%20to%20solve%20the%20mystery.%20Within%20the%20next%20portion%20of%20the%20article%20we%20will%20setup%20stakes%2C%20go%20into%20depth%20on%20the%20problem%2C%20and%20how%20to%20solve%20for%20this.%20If%20you%20want%20to%20just%20deploy%20the%20Azure%20Sentinel%20Playbook%20to%20close%20Incident%20and%20Dismiss%20ASC%20Alert%20at%20the%20same%20time%20%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2FAzure%2FAzure-Sentinel%2Ftree%2Fmaster%2FPlaybooks%2FClose-Incident-ASCAlert%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%22%3Eclick%20here%3C%2FA%3E.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CFONT%20size%3D%225%22%3E%3CSTRONG%3ESetting%20up%20base%20configuration%20of%20Azure%20Sentinel%20and%20Azure%20Security%26nbsp%3BCenter%3C%2FSTRONG%3E%3C%2FFONT%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ETo%20get%20started%20note%20that%20Azure%20Sentinel%20is%20Microsoft%E2%80%99s%20cloud%20native%20SIEM%20and%20SOAR%20tool%2C%20within%20a%20click%20of%20the%20Azure%20portal%20you%20can%20spin%20this%20up.%20Once%20spun%20up%20one%20of%20the%20first%20things%20customers%20want%20to%20do%20is%20bring%20in%20Data%20Connectors%20to%20start%20sending%20the%20Logs%20and%20Alerts%20from%20other%203%3CSUP%3Erd%3C%2FSUP%3E%20party%20and%20Microsoft%20systems.%20One%20such%20popular%20connector%20is%20the%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fsentinel%2Fconnect-azure-security-center%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%3EAzure%20Security%20Center%20connector%3C%2FA%3E.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EAzure%20Security%20Center%20has%20two%20awesome%20pillars%20of%20securing%20your%20Azure%20investments%3CSPAN%3E%3A%20%3C%2FSPAN%3EPosture%20Management%20in%20the%20form%20of%20security%20recommendations%20and%20%3CSPAN%3Eworkload%20protection%20using%20%3C%2FSPAN%3Ethreat%20detection%20that%20alert%20off%20IaaS%20and%20PaaS%20services.%20Check%20out%20the%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fazure%2Fsecurity-center%2Falerts-reference%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%3Elink%20to%20the%20full%20list%20of%20detections%20that%20generate%20alerts%3C%2FA%3E.%20I%3CSPAN%3Et%20is%20impressive%20and%20a%20game%20changer%20for%20cloud%20security.%3C%2FSPAN%3E%20Azure%20Security%20Center%20was%20the%20first%20public%20cloud%20offering%20to%20do%20recommendations%20and%20threat%20detection%20within%20a%20public%20cloud%20provider%20for%20years%20before%20the%20other%20cloud%20vendors%20built%20a%20service.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EAfter%20the%20ASC%20connector%20is%20established%20in%20Azure%20Sentinel%2C%20you%20can%20generate%20Incidents%20based%20off%20those%20ASC%20Alerts%2C%20giving%20your%20SOC%20a%20SIEM%20and%20SOAR%20capabilities%20on%20ASC%20Alerts.%20To%20do%20this%20in%20Azure%20Sentinel%20follow%20the%20steps%20below%3A%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3COL%3E%0A%3CLI%3EGo%20to%20Analytics%20blade%20%26gt%3B%20Create%20Microsoft%20Incident%20creation%20rule%26nbsp%3B%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22Sentinelrulecreate.png%22%20style%3D%22width%3A%20493px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171788i50E2F4B42E913F67%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22Sentinelrulecreate.png%22%20alt%3D%22Sentinelrulecreate.png%22%20%2F%3E%3C%2FSPAN%3E%26nbsp%3B%3C%2FLI%3E%0A%3CLI%3E%3CP%3E%26nbsp%3BYou%20will%20be%20taken%20to%20a%20setup%20wizard%20fill%20in%20for%20your%20needs.%20To%20start%20I%20choose%20High%20and%20Medium%20Severity%20alerts%20from%20Azure%20Security%20Center%26nbsp%3B%3CBR%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22Sentinelrulecreate2.png%22%20style%3D%22width%3A%20596px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171789i23D5C37D192A512A%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22Sentinelrulecreate2.png%22%20alt%3D%22Sentinelrulecreate2.png%22%20%2F%3E%3C%2FSPAN%3E%26nbsp%3B%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%3CP%3E%3CSPAN%20style%3D%22font-family%3A%20inherit%3B%22%3E%26nbsp%3B%3C%2FSPAN%3EOn%20the%20next%20screen%20we%20will%20validate%20and%20review%20our%20choices%20before%20telling%20Azure%20Sentinel%20to%20generate%20Incidents%20on%20ASC%20Alerts.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3CBR%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22Sentinelrulecreate3.png%22%20style%3D%22width%3A%20647px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171792i139FF7ADA0BDC968%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22Sentinelrulecreate3.png%22%20alt%3D%22Sentinelrulecreate3.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3EOnce%26nbsp%3Bcreated%20I%20can%20now%20see%20our%20rule%20and%20any%20others%20I%20brought%20in%20from%20Azure%20Sentinel%E2%80%99s%20templates%20or%20from%20Microsoft%20Security%20products%20like%20Azure%20Security%20Center%20or%20Microsoft%20Defender%20ATP%20or%20others.%20Remember%20you%20can%20always%20click%20back%20on%20the%20rule%20and%20edit%20to%20tune%20these%20further.%3CP%3E%26nbsp%3B%3C%2FP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22Sentinelrulecreate4.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171790i88CE0F15E4BF8970%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22Sentinelrulecreate4.png%22%20alt%3D%22Sentinelrulecreate4.png%22%20%2F%3E%3C%2FSPAN%3E%26nbsp%3B%3C%2FLI%3E%0A%3CLI%3E%3CP%3EOn%26nbsp%3Bthe%20Azure%20Security%20Center%20side%20we%20want%20to%20ensure%20our%20Subscriptions%20are%20set%20to%20the%20Standard%20Tier.%20On%20each%20Azure%20Subscription%20Microsoft%20offers%20a%2030%20day%20opt%20out%20trial%20of%20ASC%20Standard%20tier%2C%20be%20sure%20if%20evaluating%20ASC%20you%20mark%20your%20calendar%2025%20days%20in%20advance.%26nbsp%3B%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22asc.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171791i45BD786E821283BC%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22asc.png%22%20alt%3D%22asc.png%22%20%2F%3E%3C%2FSPAN%3E%26nbsp%3B%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3EFinally%20ensure%20on%20Data%20Collection%20blade%20that%20auto%20provisioning%20is%20turned%20on.%26nbsp%3B%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22asc3.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171793i215F9CE92FFC6EF1%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22asc3.png%22%20alt%3D%22asc3.png%22%20%2F%3E%3C%2FSPAN%3E%26nbsp%3B%3C%2FLI%3E%0A%3CLI%3E%3CP%3E%26nbsp%3BFor%20testing%20purposes%20we%20will%20spin%20up%20a%20Windows%202012%20R2%20VM%20on%20Azure%20isolated%20within%20its%20own%20VNET.%20Log%20into%20the%20VM%20and%20%3CA%20href%3D%22https%3A%2F%2Fswiftsolvesstore.blob.core.windows.net%2Fstuff%2FACS.zip%22%20target%3D%22_self%22%20rel%3D%22nofollow%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%3Edownload%20the%20following%20ACS.zip%3C%2FA%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%3C%2FP%3E%0A%3C%2FLI%3E%0A%3CLI%3E%3CP%3E%3CSPAN%20style%3D%22font-family%3A%20inherit%3B%22%3EUnzip%20and%20place%20AlertGeneration%20in%20the%20root%20of%20C%3A%5C%20.%20In%20C%3A%5CAlertGeneration%20run%20the%20following%20PS%20script%20%3C%2FSPAN%3E%3CEM%20style%3D%22font-family%3A%20inherit%3B%22%3EScheduledTasksCreation.ps1%3C%2FEM%3E%3CSPAN%20style%3D%22font-family%3A%20inherit%3B%22%3E%20to%20create%20scheduled%20tasks%20that%20will%20generate%20Azure%20Security%20Center%20alerts%20every%205%20minutes.%26nbsp%3B%3C%2FSPAN%3E%3CSPAN%20style%3D%22font-family%3A%20inherit%3B%22%3E%26nbsp%3B%3C%2FSPAN%3E%3C%2FP%3E%0A%3C%2FLI%3E%0A%3C%2FOL%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22alert1.png%22%20style%3D%22width%3A%20975px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171795i1759D4A512C9206A%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22alert1.png%22%20alt%3D%22alert1.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22alert2.png%22%20style%3D%22width%3A%20975px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171796i15F925D94B377A7D%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22alert2.png%22%20alt%3D%22alert2.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20style%3D%22font-family%3A%20inherit%3B%22%3EAt%20this%20point%20we%20can%20test%20and%20close%20a%20Azure%20Sentinel%20Incident%2C%20you%20will%20observe%20that%20the%20corresponding%20ASC%20Alert%20is%20still%20active%20under%20Threats.%20You%20can%20manually%20dismiss%20the%20ASC%20Alert%20by%20clicking%20on%20the%20three%20ellipses%20and%20choosing%20%3C%2FSPAN%3E%3CSPAN%20style%3D%22font-style%3A%20normal%20!msorm%3B%22%3E%3CEM%3EDismiss%3C%2FEM%3E%3C%2FSPAN%3E%3CSPAN%20style%3D%22font-family%3A%20inherit%3B%22%3E.%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20style%3D%22font-family%3A%20inherit%3B%22%3E%3CSPAN%20style%3D%22font-family%3A%20inherit%3B%22%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22alerdismiss.png%22%20style%3D%22width%3A%20975px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171797i15AE9A5A3F448689%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22alerdismiss.png%22%20alt%3D%22alerdismiss.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EDue%20to%20this%20extra%20process%20step%20from%20a%20SOC%20Analyst%20to%20keep%20Azure%20Security%20Center%20in%20Sync%20with%20Azure%20Sentinel%2C%20I%20took%20the%20task%20to%20investigate%20how%20these%20two%20systems%20store%20information.%20If%20we%20can%20match%20on%20any%20fields%20directly%20or%20indirectly%20and%20pass%20the%20necessary%20information%20to%20the%20Azure%20Security%20Center%20Alert%20API%20to%20dismiss.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CFONT%20size%3D%225%22%3E%3CSTRONG%3ELining%20up%20data%20sources%20to%20find%20potential%20matches%3C%2FSTRONG%3E%3C%2FFONT%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWhile%20examining%20the%20Get%20Azure%20Sentinel%20Incident%20I%20noticed%20we%20had%20some%20interesting%20property%20fields%20that%20could%20be%20useful%20in%20matching.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%20class%3D%22lia-code-sample%20language-javascript%22%3E%3CCODE%3E%7B%0A%20%20%20%20%20%20%22id%22%3A%20%22%2Fsubscriptions%2F%7Bsubscriptionid%7D%2FresourceGroups%2F%7Bresourcegroupname%7D%2Fproviders%2FMicrosoft.OperationalInsights%2Fworkspaces%2F%7Bworkspacename%7D%2Fproviders%2FMicrosoft.SecurityInsights%2FCases%2F7e2100df-d301-4cac-a9f7-9a7e66903b33%22%2C%0A%20%20%20%20%20%20%22name%22%3A%20%227e2100df-d301-4cac-a9f7-9a7e66903b33%22%2C%0A%20%20%20%20%20%20%22etag%22%3A%20%22%5C%2204001f78-0000-0100-0000-5e4611150000%5C%22%22%2C%0A%20%20%20%20%20%20%22type%22%3A%20%22Microsoft.SecurityInsights%2FCases%22%2C%0A%20%20%20%20%20%20%22properties%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%22title%22%3A%20%22Suspicious%20command%20execution%22%2C%0A%20%20%20%20%20%20%20%20%22description%22%3A%20%22Machine%20logs%20indicate%20a%20suspicious%20command%20line%20execution%20by%20user%20%25%7Buser%20name%7D.%22%2C%0A%20%20%20%20%20%20%20%20%22severity%22%3A%20%22High%22%2C%0A%20%20%20%20%20%20%20%20%22status%22%3A%20%22Closed%22%2C%0A%20%20%20%20%20%20%20%20%22labels%22%3A%20%5B%5D%2C%0A%20%20%20%20%20%20%20%20%22closeReason%22%3A%20%22TruePositive%22%2C%0A%20%20%20%20%20%20%20%20%22closedReasonText%22%3A%20%22Closed%20via%20Playbook%20to%20Dismiss%20ASC%20Alert%22%2C%0A%20%20%20%20%20%20%20%20%22endTimeUtc%22%3A%20%222020-02-13T21%3A37%3A44Z%22%2C%0A%20%20%20%20%20%20%20%20%22startTimeUtc%22%3A%20%222020-02-13T21%3A37%3A44Z%22%2C%0A%20%20%20%20%20%20%20%20%22owner%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%20%20%22objectId%22%3A%20null%2C%0A%20%20%20%20%20%20%20%20%20%20%22email%22%3A%20null%2C%0A%20%20%20%20%20%20%20%20%20%20%22name%22%3A%20null%0A%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%22lastUpdatedTimeUtc%22%3A%20%222020-02-14T03%3A16%3A37Z%22%2C%0A%20%20%20%20%20%20%20%20%22createdTimeUtc%22%3A%20%222020-02-13T21%3A38%3A26.3121407Z%22%2C%0A%20%20%20%20%20%20%20%20%22relatedAlertIds%22%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%228e724b86-039c-48b1-9ef8-75b9d05c2b43%22%0A%20%20%20%20%20%20%20%20%5D%2C%0A%20%20%20%20%20%20%20%20%22relatedAlertProductNames%22%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%22Azure%20Security%20Center%22%0A%20%20%20%20%20%20%20%20%5D%2C%0A%20%20%20%20%20%20%20%20%22tactics%22%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%22Execution%22%0A%20%20%20%20%20%20%20%20%5D%2C%0A%20%20%20%20%20%20%20%20%22caseNumber%22%3A%20372%2C%0A%20%20%20%20%20%20%20%20%22lastComment%22%3A%20%22Via%20RDP%20session%20from%20IP%3A%20136.57.182.66%20Eagle%20logged%20in%20and%20enabled%20a%20task%20and%20executed%20a%20run%20runing%20cmd%20line%20script.%20Confirmed%20with%20Developer%20this%20is%20just%20a%20test.%22%2C%0A%20%20%20%20%20%20%20%20%22totalComments%22%3A%201%2C%0A%20%20%20%20%20%20%20%20%22metrics%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%20%20%22SecurityAlert%22%3A%201%0A%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%22firstAlertTimeGenerated%22%3A%20%222020-02-13T21%3A38%3A22.5983349Z%22%2C%0A%20%20%20%20%20%20%20%20%22lastAlertTimeGenerated%22%3A%20%222020-02-13T21%3A38%3A22.5983349Z%22%0A%20%20%20%20%20%20%7D%0A%20%20%20%20%7D%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3E%3CEM%3ETitle%20-%20%3C%2FEM%3E%3C%2FSTRONG%3EMatches%20the%20alertDisplayName%20of%20ASC%20Alert%20but%20is%20not%20unique%20enough%20in%20a%20larger%20context%20of%20duplicate%20alerts%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3E%3CEM%3EStatus%3C%2FEM%3E%3C%2FSTRONG%3E%20%E2%80%93%20Closed%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3E%3CEM%3ErelatedAlertProductNames%3C%2FEM%3E%3C%2FSTRONG%3E%20-%20this%20allows%20us%20to%20be%20distinctive%2C%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3E%3CEM%3EstartTimeUtc%3C%2FEM%3E%3C%2FSTRONG%3E%20-%20time%20the%20Incident%20was%20created%20in%20%3CSPAN%3EAzure%20%3C%2FSPAN%3ESentinel%2C%20this%20correlates%20fairly%20well%20against%20ASC%20detectedTimeUTC%20but%20not%20exactly.%20Can%20be%20off%20my%20milliseconds%20when%20testing%2C%20potential%20could%20be%20off%20by%20seconds%20as%20well.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3E%3CEM%3ErelatedAlertIds%3C%2FEM%3E%3C%2FSTRONG%3E%20%E2%80%93%20a%20corollary%20guid%20used%20in%20SecurityAlert%20log%20Analytics%20table.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EOn%20the%20Get%20Azure%20Security%20Center%20Alert%20we%20also%20get%20some%20interesting%20information%20from%20the%20property%20fields%20in%20the%20returned%20response.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CPRE%20class%3D%22lia-code-sample%20language-javascript%22%3E%3CCODE%3E%20%20%20%20%20%20%22id%22%3A%20%22%2Fsubscriptions%2F%7Bsubscriptionid%7D%2FresourceGroups%2F%7Bresourcegroupname%7D%2Fproviders%2FMicrosoft.Security%2Flocations%2Fcentralus%2Falerts%2F2518206709356240952_6010a57b-91e0-422f-8f35-9587f5330771%22%2C%0A%20%20%20%20%20%20%22name%22%3A%20%222518206709356240952_6010a57b-91e0-422f-8f35-9587f5330771%22%2C%0A%20%20%20%20%20%20%22type%22%3A%20%22Microsoft.Security%2FLocations%2Falerts%22%2C%0A%20%20%20%20%20%20%22properties%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%22systemSource%22%3A%20%22Azure%22%2C%0A%20%20%20%20%20%20%20%20%22vendorName%22%3A%20%22Microsoft%22%2C%0A%20%20%20%20%20%20%20%20%22alertDisplayName%22%3A%20%22Suspicious%20command%20execution%22%2C%0A%20%20%20%20%20%20%20%20%22alertName%22%3A%20%22SuspiciousCMDExecution%22%2C%0A%20%20%20%20%20%20%20%20%22detectedTimeUtc%22%3A%20%222020-02-13T21%3A37%3A44.3759047Z%22%2C%0A%20%20%20%20%20%20%20%20%22description%22%3A%20%22Machine%20logs%20indicate%20a%20suspicious%20command%20line%20execution%20by%20user%20%25%7Buser%20name%7D.%22%2C%0A%20%20%20%20%20%20%20%20%22remediationSteps%22%3A%20%221.%20Validate%20with%20'%25%7Buser%20name%7D'%20if%20this%20action%20was%20intentional.%20If%20not%2C%20Escalate%20the%20alert%20to%20the%20information%20security%20team%5Cr%5Cn2.%20Make%20sure%20the%20machine%20is%20completely%20updated%20and%20has%20an%20updated%20Anti-Virus%20installed%5Cr%5Cn3.%20Install%20and%20run%20Microsoft%E2%80%99s%20Malicious%20Software%20Removal%20Tool%20(see%20https%3A%2F%2Fwww.microsoft.com%2Fen-us%2Fdownload%2Fmalicious-software-removal-tool-details.aspx)%5Cr%5Cn4.%20Run%20Microsoft%E2%80%99s%20Autoruns%20utility%20and%20try%20to%20identify%20unknown%20applications%20that%20are%20configured%20to%20run%20at%20login%20(see%20https%3A%2F%2Ftechnet.microsoft.com%2Fen-us%2Fsysinternals%2Fbb963902.aspx)%5Cr%5Cn5.%20Run%20Process%20Explorer%20and%20try%20to%20identify%20unknown%20running%20processes%20(see%20https%3A%2F%2Ftechnet.microsoft.com%2Fen-us%2Fsysinternals%2Fbb896653.aspx)%22%2C%0A%20%20%20%20%20%20%20%20%22actionTaken%22%3A%20%22Undefined%22%2C%0A%20%20%20%20%20%20%20%20%22reportedSeverity%22%3A%20%22High%22%2C%0A%20%20%20%20%20%20%20%20%22compromisedEntity%22%3A%20%22LEVIATHAN%22%2C%0A%20%20%20%20%20%20%20%20%22associatedResource%22%3A%20%22%2Fsubscriptions%2F%7Bsubscriptionid%7D%2FresourceGroups%2FrgHacks4Claps%2Fproviders%2FMicrosoft.Compute%2FvirtualMachines%2FLeviathan%22%2C%0A%20%20%20%20%20%20%20%20%22subscriptionId%22%3A%20%22%7Bsubscriptionid%7D%22%2C%0A%20%20%20%20%20%20%20%20%22instanceId%22%3A%20%226010a57b-91e0-422f-8f35-9587f5330771%22%2C%0A%20%20%20%20%20%20%20%20%22extendedProperties%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%20%20%22user%20name%22%3A%20%22WORKGROUP%5C%5CLeviathan%24%22%2C%0A%20%20%20%20%20%20%20%20%20%20%22process%20name%22%3A%20%22c%3A%5C%5Cwindows%5C%5Csystem32%5C%5Ccmd.exe%22%2C%0A%20%20%20%20%20%20%20%20%20%20%22command%20line%22%3A%20%22c%3A%5C%5Cwindows%5C%5Csystem32%5C%5Ccmd.exe%20%2Fc%20net%20user%26amp%3Becho%20%5C%22123%5C%22%26amp%3Becho%20%5C%22open%20123%20127.0.0.1%5C%22%20%26gt%3B%20c%3A%5C%5Calertgeneration%5C%5Cdummy.txt%26amp%3Bexit%22%2C%0A%20%20%20%20%20%20%20%20%20%20%22process%20id%22%3A%20%220x398%22%2C%0A%20%20%20%20%20%20%20%20%20%20%22account%20logon%20id%22%3A%20%220x3e7%22%2C%0A%20%20%20%20%20%20%20%20%20%20%22user%20SID%22%3A%20%22S-1-5-18%22%2C%0A%20%20%20%20%20%20%20%20%20%20%22parent%20process%20id%22%3A%20%220x338%22%2C%0A%20%20%20%20%20%20%20%20%20%20%22enrichment_tas_threat__reports%22%3A%20%22%7B%5C%22Kind%5C%22%3A%5C%22MultiLink%5C%22%2C%5C%22DisplayValueToUrlDictionary%5C%22%3A%7B%5C%22Report%3A%20Suspicious%20Command%20Execution%5C%22%3A%5C%22https%3A%2F%2Finterflowwebportalext.trafficmanager.net%2Freports%2FDisplayReport%3FcallerIdentity%3Dddd5443d-e6f4-441c-b52b-5278d2f21dfa%26amp%3BreportCreateDateTime%3D2020-02-13T03%253a02%253a12%26amp%3BreportName%3DMSTI-TS-Suspicious-Command-Execution.pdf%26amp%3BtenantId%3D96d75fc3-d906-40b3-b826-52a32e91eb61%26amp%3BurlCreateDateTime%3D2020-02-13T03%253a02%253a12%26amp%3Btoken%3DLBN9K4RWKAuxbc%2520Sl05Z%2FMx1N1XRrrclhLvrIv715a0%3D%5C%22%7D%7D%22%2C%0A%20%20%20%20%20%20%20%20%20%20%22resourceType%22%3A%20%22Virtual%20Machine%22%0A%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%22state%22%3A%20%22Dismissed%22%2C%0A%20%20%20%20%20%20%20%20%22reportedTimeUtc%22%3A%20%222020-02-13T21%3A38%3A24.5447196Z%22%2C%0A%20%20%20%20%20%20%20%20%22workspaceArmId%22%3A%20%22%2Fsubscriptions%2F%7Bsubscriptionid%7D%2Fresourcegroups%2Frgswiftoperations%2Fproviders%2Fmicrosoft.operationalinsights%2Fworkspaces%2Fswiftenvlogs%22%2C%0A%20%20%20%20%20%20%20%20%22confidenceScore%22%3A%200.348%2C%0A%20%20%20%20%20%20%20%20%22confidenceReasons%22%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%22type%22%3A%20%22Process%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22reason%22%3A%20%22Suspicious%20process%20cmd.exe%20triggered%20this%20alert%20on%20multiple%20machines%20in%20this%20subscription%22%0A%20%20%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%20%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%22type%22%3A%20%22Computer%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22reason%22%3A%20%22This%20alert%20was%20triggered%20multiple%20times%20on%20machine%20LEVIATHAN%20in%20the%20last%2024%20hours%22%0A%20%20%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%20%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%22type%22%3A%20%22User%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22reason%22%3A%20%22User%20ANONYMOUS%20LOGON%20was%20involved%20in%20multiple%20alerts%20on%20machine%20LEVIATHAN%20in%20the%20last%207%20days%22%0A%20%20%20%20%20%20%20%20%20%20%7D%0A%20%20%20%20%20%20%20%20%5D%2C%0A%20%20%20%20%20%20%20%20%22canBeInvestigated%22%3A%20true%2C%0A%20%20%20%20%20%20%20%20%22isIncident%22%3A%20false%2C%0A%20%20%20%20%20%20%20%20%22entities%22%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%22%24id%22%3A%20%22centralus_551%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22dnsDomain%22%3A%20%22%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22ntDomain%22%3A%20%22%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22hostName%22%3A%20%22LEVIATHAN%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22netBiosName%22%3A%20%22LEVIATHAN%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22azureID%22%3A%20%22%2Fsubscriptions%2F%7Bsubscriptionid%7D%2FresourceGroups%2FrgHacks4Claps%2Fproviders%2FMicrosoft.Compute%2FvirtualMachines%2FLeviathan%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22omsAgentID%22%3A%20%22006d32ae-345d-480c-ae25-c6c183cca496%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22osFamily%22%3A%20%22Windows%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22osVersion%22%3A%20%22Windows%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22isDomainJoined%22%3A%20false%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22type%22%3A%20%22host%22%0A%20%20%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%20%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%22%24id%22%3A%20%22centralus_552%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22name%22%3A%20%22Leviathan%24%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22ntDomain%22%3A%20%22WORKGROUP%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22host%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%22%24ref%22%3A%20%22centralus_551%22%0A%20%20%20%20%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22sid%22%3A%20%22S-1-5-18%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22isDomainJoined%22%3A%20true%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22type%22%3A%20%22account%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22LogonId%22%3A%20%220x3e7%22%0A%20%20%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%20%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%22%24id%22%3A%20%22centralus_553%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22processId%22%3A%20%220x338%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22commandLine%22%3A%20%22%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22host%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%22%24ref%22%3A%20%22centralus_551%22%0A%20%20%20%20%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22type%22%3A%20%22process%22%0A%20%20%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%20%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%22%24id%22%3A%20%22centralus_554%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22directory%22%3A%20%22c%3A%5C%5Cwindows%5C%5Csystem32%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22name%22%3A%20%22cmd.exe%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22type%22%3A%20%22file%22%0A%20%20%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%20%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%22%24id%22%3A%20%22centralus_555%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22processId%22%3A%20%220x398%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22commandLine%22%3A%20%22c%3A%5C%5Cwindows%5C%5Csystem32%5C%5Ccmd.exe%20%2Fc%20net%20user%26amp%3Becho%20%5C%22123%5C%22%26amp%3Becho%20%5C%22open%20123%20127.0.0.1%5C%22%20%26gt%3B%20c%3A%5C%5Calertgeneration%5C%5Cdummy.txt%26amp%3Bexit%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22elevationToken%22%3A%20%22Default%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22creationTimeUtc%22%3A%20%222020-02-13T21%3A37%3A44.3759047Z%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22imageFile%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%22%24ref%22%3A%20%22centralus_554%22%0A%20%20%20%20%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22account%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%22%24ref%22%3A%20%22centralus_552%22%0A%20%20%20%20%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22parentProcess%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%22%24ref%22%3A%20%22centralus_553%22%0A%20%20%20%20%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22host%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%22%24ref%22%3A%20%22centralus_551%22%0A%20%20%20%20%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22type%22%3A%20%22process%22%0A%20%20%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%20%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%22%24id%22%3A%20%22centralus_556%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22sessionId%22%3A%20%220x3e7%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22startTimeUtc%22%3A%20%222020-02-13T21%3A37%3A44.3759047Z%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22endTimeUtc%22%3A%20%222020-02-13T21%3A37%3A44.3759047Z%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22type%22%3A%20%22host-logon-session%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22host%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%22%24ref%22%3A%20%22centralus_551%22%0A%20%20%20%20%20%20%20%20%20%20%20%20%7D%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%22account%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%22%24ref%22%3A%20%22centralus_552%22%0A%20%20%20%20%20%20%20%20%20%20%20%20%7D%0A%20%20%20%20%20%20%20%20%20%20%7D%0A%20%20%20%20%20%20%20%20%5D%0A%20%20%20%20%20%20%7D%0A%20%20%20%20%7D%3C%2FCODE%3E%3C%2FPRE%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3E%3CEM%3Ename%3C%2FEM%3E%3C%2FSTRONG%3E%20%E2%80%93%20this%20is%20the%20alert%20name%20you%20pass%20to%20dismiss%20the%20ASC%20alert%20in%20the%20API%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3E%3CEM%3EalertDisplayName%3C%2FEM%3E%3C%2FSTRONG%3E%20%E2%80%93%20Matches%20the%20title%20of%20Azure%20Sentinel%20Incident%20but%20is%20not%20unique%20enough%20in%20a%20larger%20context%20of%20duplicate%20alerts%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3E%3CEM%3EdetectedTimeUTC%20%3C%2FEM%3E%3C%2FSTRONG%3E%E2%80%93%20this%20correlates%20fairly%20well%20against%20Azure%20Setinel%E2%80%99s%20startTimeUtc%20but%20not%20exactly%20off%20by%20milliseconds%20when%20testing%2C%20potential%20could%20be%20off%20by%20seconds%20as%20well.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3E%3CEM%3EState%3C%2FEM%3E%3C%2FSTRONG%3E%20%E2%80%93%20active%20or%20dismissed%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CFONT%20size%3D%225%22%3E%3CSTRONG%3EDirect%20Match%20Conclusion%3C%2FSTRONG%3E%3C%2FFONT%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWhat%20we%20are%20left%20with%20is%20a%20non%20unique%20direct%20match%20that%20could%20have%20false%20positives.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3Etitle%20%3D%3D%20alertDisplayedName%3C%2FP%3E%0A%3CP%3EstartTimeUtc%20%3D%3D%20detectedTimeUTC%20%26lt%3B%20only%20at%20the%20minutes%3C%2FP%3E%0A%3CP%3Estatus%20%3D%3D%20state%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EDue%20to%20this%20we%20could%20build%20a%20matching%20logic%20but%20questions%20arise%20what%20if%20there%20is%20a%20delay%20in%20timestamps%2C%20they%20are%20already%20off%20by%20milliseconds%20what%20if%20off%20by%20seconds%20%3F%20How%20much%20of%20a%20time%20window%20would%20we%20use%20to%20match%201%20sec%20off%2C%203%20seconds%20off%20%3F%20The%20names%20are%20too%20generic%20on%20the%20alert%20with%20no%20unique%20resource%20or%20identifier%20within%20the%20alert%20name.%20What%20if%20there%20are%20multiples%20or%20alerts%20within%20seconds%20of%20each%20other%20with%20same%20names.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EYou%20can%20see%20that%20direct%20match%20while%20possible%20may%20not%20be%20ideal%20in%20larger%20and%20more%20complex%20environments.%20So%20how%20can%20we%20solve%20this%20mystery%2C%20perhaps%20with%20a%20indirect%20matching%20method%20%3F%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CFONT%20size%3D%225%22%3E%3CSTRONG%3EThe%20Clue%3C%2FSTRONG%3E%3C%2FFONT%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EEnter%20the%20GUI%20for%20Azure%20Sentinel%2C%20while%20clicking%20around%20in%20the%20Incident%20under%20full%20details%20I%20noticed%20it%20had%20an%20alert%20ID%2C%20the%20same%20that%20was%20in%20the%20API%20call%20as%20relatedAlertIds%20but%20didn%E2%80%99t%20show%20up%20in%20ASC%20Alert%20API%20call.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22incidentfulldetails.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171806i3A6EB6C1C47F7E7C%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22incidentfulldetails.png%22%20alt%3D%22incidentfulldetails.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3EThe%20Alert%20Id%20even%20has%20a%20link%20that%20takes%20us%20to%20Log%20Analytics%20%E2%80%93%20SecurityAlert%20table%20of%20data%20that%20both%20Azure%20Sentinel%20and%20Azure%20Security%20Center%20can%20right%20into.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWithin%20that%20generated%20KQL%20query%20laid%20the%20clue%20that%20could%20unravel%20Azure%20Sentinel%20to%20ASC%20in%20a%20more%20precise%20manner.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ESystemAlertID%20%3D%3D%20AlertLink%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22indirectmatch.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171809i81733A58245639BC%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22indirectmatch.png%22%20alt%3D%22indirectmatch.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EMany%20times%20it%20pays%20to%20go%20above%20code%20and%20look%20at%20the%20Portal%20UI%20where%20hints%20can%20be%20observed%20visually.%20Armed%20with%20this%20knowledge%20and%20some%20testing%20I%20went%20to%20work%20on%20a%20Azure%20Sentinel%20Playbook%20that%20a%20SOC%20Analyst%20can%20run%20when%20they%20are%20ready%20to%20close%20their%20Incident%20and%20then%20dismiss%20the%20corresponding%20Azure%20Security%20Center%20alert.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CFONT%20size%3D%225%22%3E%3CSTRONG%3EDesigning%20Azure%20%3C%2FSTRONG%3E%3CSTRONG%3ESentinel%20Playbook%3C%2FSTRONG%3E%3C%2FFONT%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EDesigning%20the%20Logic%20app%20took%20a%20few%20iterations%20but%20I%20finally%20landed%20on%20a%20pattern%20that%20worked%20in%20testing.%20The%20Logic%20App%20pattern%20is%20as%20follows.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22logicapp1.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171810i2D1A5C5D4A6C2E9D%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22logicapp1.png%22%20alt%3D%22logicapp1.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22logicapp2.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171811iB78548CAD7CE27BE%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22logicapp2.png%22%20alt%3D%22logicapp2.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22logicapp3.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171813i34B9E05DB9F8FFBD%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22logicapp3.png%22%20alt%3D%22logicapp3.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22logicapp4a.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171814i1D9E4DAD822F6841%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22logicapp4a.png%22%20alt%3D%22logicapp4a.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ERemember%20clicking%20on%20a%20dynamic%20content%20%5C%20expression%20will%20reveal%20the%20coded%20expression%20used%2C%20recall%20that%20the%20Parse%20JSON%20still%20gave%20us%20an%20array%20rather%20than%20foreach%20when%20we%20click%20in%20and%20select%20the%20%3CSTRONG%3E%3CEM%3Evalue%3C%2FEM%3E%3C%2FSTRONG%3E%20we%20will%20use%200%20Index%20of%20the%20array%20to%20pass%20the%20strings%20in%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3Ebody('Run_query_and_list_results')%5B'value'%5D%5B0%5D%5B'ascsubid'%5D%3C%2FP%3E%0A%3CP%3Ebody('Run_query_and_list_results')%5B'value'%5D%5B0%5D%5B'ascrgname'%5D%3C%2FP%3E%0A%3CP%3Ebody('Run_query_and_list_results')%5B'value'%5D%5B0%5D%5B'ascalertname'%5D%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22logicapp4.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171816i8A44865D6099FFC5%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22logicapp4.png%22%20alt%3D%22logicapp4.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CFONT%20size%3D%225%22%3E%3CSTRONG%3EConclusion%3C%2FSTRONG%3E%3C%2FFONT%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWhen%20designing%20or%20solving%20for%20a%20problem%20you%20should%20look%20at%20the%20data%20structures%20involved%20behind%20the%20scenes%20and%20determine%20can%20I%20make%20a%20direct%20match%20%3F%20If%20I%20can%E2%80%99t%20make%20a%20direct%20match%20can%20I%20use%20another%20source%20of%20truth%20on%20data%20table%20somewhere%20and%20indirectly%20match%20%3F%20Logic%20Apps%20are%20very%20powerful%20and%20easy%20to%20use%20to%20solve%20for%20problems.%20You%20don%E2%80%99t%20need%20to%20rely%20on%20code%20dependencies%20or%20PowerShell%20modules.%20Logic%20Apps%20can%20be%20used%20as%20a%20managed%20identity%20and%20given%20certain%20rights%20against%20the%20Azure%20Subscription%20or%20Resources%20to%20make%20it%20easy%20and%20secure%20obtaining%20authorization%20without%20having%20to%20use%20a%20ServicePrincipal%20and%20passing%20AppID%20and%20Key%20to%20obtain%20a%20bearer%20token%20to%20then%20pass%20within%20API%20call.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EIf%20you%20want%20to%20try%20this%20out%20you%20can%20deploy%20the%20Azure%20Sentinel%20playbook%20containing%20this%20logic%20from%20the%26nbsp%3B%20Repository%20on%20Github%20here%3A%26nbsp%3B%3CA%20title%3D%22Close-Incident-ASCAlert%22%20href%3D%22https%3A%2F%2Fgithub.com%2FAzure%2FAzure-Sentinel%2Ftree%2Fmaster%2FPlaybooks%2FClose-Incident-ASCAlert%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%22%3Ehttps%3A%2F%2Fgithub.com%2FAzure%2FAzure-Sentinel%2Ftree%2Fmaster%2FPlaybooks%2FClose-Incident-ASCAlert%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20image-alt%3D%22deploy.png%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F171819i3A4CF746523447CF%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%22deploy.png%22%20alt%3D%22deploy.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3E%3CFONT%3ESpecial%20thanks%20to%3A%3C%2FFONT%3E%3C%2FSTRONG%3E%3C%2FP%3E%0A%3CP%3E%3CEM%3E%3CFONT%3EYuri%20Diogenes%20for%20reviewing%20this%20post.%3C%2FFONT%3E%3C%2FEM%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1183849%22%20slang%3D%22en-US%22%3ERe%3A%20Closing%20an%20Incident%20in%20Azure%20Sentinel%20and%20Dismissing%20an%20Alert%20in%20Azure%20Security%20Center%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1183849%22%20slang%3D%22en-US%22%3E%3CP%3EAwesome%20Blogpost%20!%20Thank%20you%26nbsp%3B%3CIMG%20class%3D%22lia-deferred-image%20lia-image-emoji%22%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Fhtml%2Fimages%2Femoticons%2Fcool_40x40.gif%22%20alt%3D%22%3Acool%3A%22%20title%3D%22%3Acool%3A%22%20%2F%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1294882%22%20slang%3D%22en-US%22%3ERe%3A%20Closing%20an%20Incident%20in%20Azure%20Sentinel%20and%20Dismissing%20an%20Alert%20in%20Azure%20Security%20Center%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1294882%22%20slang%3D%22en-US%22%3E%3CP%3ECool%20%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F225494%22%20target%3D%22_blank%22%3E%40Nathan%20Swift%3C%2FA%3E%26nbsp%3Bvery%20useful!%3C%2FP%3E%0A%3CP%3EFollowing%20you%20concept%20we%20could%20create%20the%20same%20playbook%20for%20DefenderATP%2C%20AzureATP%2C%20CloudApp%20and%20third%20party%20if%20they%20expose%20API.%3C%2FP%3E%0A%3CP%3EIs%20it%20correct%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1349955%22%20slang%3D%22en-US%22%3ERe%3A%20Closing%20an%20Incident%20in%20Azure%20Sentinel%20and%20Dismissing%20an%20Alert%20in%20Azure%20Security%20Center%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1349955%22%20slang%3D%22en-US%22%3E%3CDIV%20class%3D%22user-mention-tag%22%3E%0A%3CP%20class%3D%22user-mention-tag-label%22%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F482040%22%20target%3D%22_blank%22%3E%40sifriger%3C%2FA%3E%20Thank%20you.%20That%20is%20correct%20a%20similar%20concept%20could%20be%20used%20if%20APIs%20and%20correlation%20exist%20in%20the%20Microsoft%20Security%20products%20and%20their%20alerts.%20As%20an%20example%20MDATP%20has%20an%20API%20to%20update%20alerts%20-%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fwindows%2Fsecurity%2Fthreat-protection%2Fmicrosoft-defender-atp%2Fupdate-alert%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fwindows%2Fsecurity%2Fthreat-protection%2Fmicrosoft-defender-atp%2Fupdate-alert%3C%2FA%3E%26nbsp%3B%7C%20and%20could%20be%20correlated%20by%20SecurityAlerts%20KQL%20table%3A%20%7Bfield%7D%3CSPAN%3EVendorOriginalId%20%3D%3D%20MDATP%20%7Bfield%7DId%3C%2FSPAN%3E%3C%2FP%3E%0A%3C%2FDIV%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1349966%22%20slang%3D%22en-US%22%3ERe%3A%20Closing%20an%20Incident%20in%20Azure%20Sentinel%20and%20Dismissing%20an%20Alert%20in%20Azure%20Security%20Center%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1349966%22%20slang%3D%22en-US%22%3E%3CP%3ECan%20i%20close%20manage%20Sentinel%20as%20well%3F%3C%2FP%3E%0A%3CP%3Ea%20sort%20of%20bidirectional%20if%20i%20am%20in%20defender%20i%20can%20close%20the%20incident%20in%20Sentinel%20and%20if%20i%20am%20in%20Sentinel%20i%20can%20close%20in%20Defender%3F%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1350245%22%20slang%3D%22en-US%22%3ERe%3A%20Closing%20an%20Incident%20in%20Azure%20Sentinel%20and%20Dismissing%20an%20Alert%20in%20Azure%20Security%20Center%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1350245%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F482040%22%20target%3D%22_blank%22%3E%40sifriger%3C%2FA%3E%26nbsp%3B-%20possibly%20though%20getting%20very%20complex.%20Logic%20Apps%20may%20not%20be%20best%20programming%20model%20to%20build%20that%20bidirectional%20synchronization%20via%20event%20driven%20closure%2C%20with%20a%20scenario%20across%20multiple%20products.%20Feel%20free%20to%20DM%20me%20in%20Private%20Messages%20or%20Teams%20if%20you%20would%20like%20to%20discuss%20more.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EA%20slightly%20different%20concept%20was%20explored%20though%20it%20was%20timer%20based%20one%20way%20authoritative%20sync%3A%20Sentinel%20Close%20Incident%20-%26gt%3B%20ASC%20Dismiss%20%3A%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2Fswiftsolves-msft%2FAzure-Sentinel-Playbooks%2Ftree%2Fmaster%2FIncidentClosed-Sync-ASCAlertDismiss%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%2Fswiftsolves-msft%2FAzure-Sentinel-Playbooks%2Ftree%2Fmaster%2FIncidentClosed-Sync-ASCAlertDismiss%3C%2FA%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1433329%22%20slang%3D%22en-US%22%3ERe%3A%20Closing%20an%20Incident%20in%20Azure%20Sentinel%20and%20Dismissing%20an%20Alert%20in%20Azure%20Security%20Center%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1433329%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F508015%22%20target%3D%22_blank%22%3E%40PriscilaViana%3C%2FA%3E%26nbsp%3B-%20wrote%20an%20awesome%20blog%20and%20playbook%20extending%20capability%20from%20Sentinel%20to%20Dismiss%20alerts%20generated%20from%20and%20on%20MCAS%20-%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fmedium.com%2F%40priscilaviana%2Fplaybook-for-azure-sentinel-mcas-integration-f939746d3209%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fmedium.com%2F%40priscilaviana%2Fplaybook-for-azure-sentinel-mcas-integration-f939746d3209%3C%2FA%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1579268%22%20slang%3D%22en-US%22%3ERe%3A%20Closing%20an%20Incident%20in%20Azure%20Sentinel%20and%20Dismissing%20an%20Alert%20in%20Azure%20Security%20Center%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1579268%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F225494%22%20target%3D%22_blank%22%3E%40Nathan%20Swift%3C%2FA%3E%26nbsp%3Bis%20there%20any%20plans%20to%20make%20this%20a%20background%20item%20for%20closing%20out%20alerts.%20If%20it%20is%20closed%20in%20ASC%20then%20it%20gets%20closed%20in%20the%20rest%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1579537%22%20slang%3D%22en-US%22%3ERe%3A%20Closing%20an%20Incident%20in%20Azure%20Sentinel%20and%20Dismissing%20an%20Alert%20in%20Azure%20Security%20Center%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1579537%22%20slang%3D%22en-US%22%3E%3CP%3EThanks%20I%20would%20check%20out%20the%20private%20previews%20and%20Azure%20Road%20map%20on%20this%20item.%20At%20this%20time%20I%20am%20not%20working%20on%20a%20sync%20between%20both%20systems%2C%20it%20would%20have%20to%20correlate%20and%20prevent%20race%20conditions%20between%20the%20two%20platforms%20in%20Logic%20App%20code.%20One%20might%20be%20able%20to%20build%20a%20one%20way%20sync%20the%20other%20way%20though%20scan%20dismissed%20ASC%20alerts%20or%20trigger%20off%20the%20Azure%20Activity%20Logs%20for%20dismissed%20alert%2C%20potentially%20correlate%20SecurityAlertId%20to%20AzureSentinel%20incident%20and%20close%20Sentinel%20incident.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1581621%22%20slang%3D%22en-US%22%3ERe%3A%20Closing%20an%20Incident%20in%20Azure%20Sentinel%20and%20Dismissing%20an%20Alert%20in%20Azure%20Security%20Center%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1581621%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F225494%22%20target%3D%22_blank%22%3E%40Nathan%20Swift%3C%2FA%3E%26nbsp%3BAwesome.%20I%20will%20look%20into%20building%20that%20out%20and%20testing%20what%20we%20can%20do.%3C%2FP%3E%3C%2FLINGO-BODY%3E
Microsoft

As we are exploring automation scenarios within Azure Security , we come across an unsolved mystery. When I use Azure Security Center connector into Azure Sentinel and generate Incidents, what happens when I close my Azure Sentinel Incident, does it close the related Azure Security Center alert?

The short of this is it does not. The Azure Sentinel Incident closes but the ASC Alert remains active. You have the option to then dismiss the ASC Alert within the ASC Portal. Sounds like an extra step to keep these systems synchronized.

 

Here is where Logic Apps comes to solve the mystery. Within the next portion of the article we will setup stakes, go into depth on the problem, and how to solve for this. If you want to just deploy the Azure Sentinel Playbook to close Incident and Dismiss ASC Alert at the same time click here.

 

Setting up base configuration of Azure Sentinel and Azure Security Center

 

To get started note that Azure Sentinel is Microsoft’s cloud native SIEM and SOAR tool, within a click of the Azure portal you can spin this up. Once spun up one of the first things customers want to do is bring in Data Connectors to start sending the Logs and Alerts from other 3rd party and Microsoft systems. One such popular connector is the Azure Security Center connector.

 

Azure Security Center has two awesome pillars of securing your Azure investments: Posture Management in the form of security recommendations and workload protection using threat detection that alert off IaaS and PaaS services. Check out the link to the full list of detections that generate alerts. It is impressive and a game changer for cloud security. Azure Security Center was the first public cloud offering to do recommendations and threat detection within a public cloud provider for years before the other cloud vendors built a service.

 

After the ASC connector is established in Azure Sentinel, you can generate Incidents based off those ASC Alerts, giving your SOC a SIEM and SOAR capabilities on ASC Alerts. To do this in Azure Sentinel follow the steps below:

 

  1. Go to Analytics blade > Create Microsoft Incident creation rule Sentinelrulecreate.png 
  2.  You will be taken to a setup wizard fill in for your needs. To start I choose High and Medium Severity alerts from Azure Security Center 
    Sentinelrulecreate2.png 

  3.  On the next screen we will validate and review our choices before telling Azure Sentinel to generate Incidents on ASC Alerts.

     
    Sentinelrulecreate3.png

     

  4. Once created I can now see our rule and any others I brought in from Azure Sentinel’s templates or from Microsoft Security products like Azure Security Center or Microsoft Defender ATP or others. Remember you can always click back on the rule and edit to tune these further.

     

    Sentinelrulecreate4.png 
  5. On the Azure Security Center side we want to ensure our Subscriptions are set to the Standard Tier. On each Azure Subscription Microsoft offers a 30 day opt out trial of ASC Standard tier, be sure if evaluating ASC you mark your calendar 25 days in advance. asc.png 

  6. Finally ensure on Data Collection blade that auto provisioning is turned on. asc3.png 
  7.  For testing purposes we will spin up a Windows 2012 R2 VM on Azure isolated within its own VNET. Log into the VM and download the following ACS.zip   

  8. Unzip and place AlertGeneration in the root of C:\ . In C:\AlertGeneration run the following PS script ScheduledTasksCreation.ps1 to create scheduled tasks that will generate Azure Security Center alerts every 5 minutes.  

alert1.png

alert2.png

 

At this point we can test and close a Azure Sentinel Incident, you will observe that the corresponding ASC Alert is still active under Threats. You can manually dismiss the ASC Alert by clicking on the three ellipses and choosing Dismiss.

 

alerdismiss.png

 

Due to this extra process step from a SOC Analyst to keep Azure Security Center in Sync with Azure Sentinel, I took the task to investigate how these two systems store information. If we can match on any fields directly or indirectly and pass the necessary information to the Azure Security Center Alert API to dismiss.

 

Lining up data sources to find potential matches

 

While examining the Get Azure Sentinel Incident I noticed we had some interesting property fields that could be useful in matching.

 

 

{
      "id": "/subscriptions/{subscriptionid}/resourceGroups/{resourcegroupname}/providers/Microsoft.OperationalInsights/workspaces/{workspacename}/providers/Microsoft.SecurityInsights/Cases/7e2100df-d301-4cac-a9f7-9a7e66903b33",
      "name": "7e2100df-d301-4cac-a9f7-9a7e66903b33",
      "etag": "\"04001f78-0000-0100-0000-5e4611150000\"",
      "type": "Microsoft.SecurityInsights/Cases",
      "properties": {
        "title": "Suspicious command execution",
        "description": "Machine logs indicate a suspicious command line execution by user %{user name}.",
        "severity": "High",
        "status": "Closed",
        "labels": [],
        "closeReason": "TruePositive",
        "closedReasonText": "Closed via Playbook to Dismiss ASC Alert",
        "endTimeUtc": "2020-02-13T21:37:44Z",
        "startTimeUtc": "2020-02-13T21:37:44Z",
        "owner": {
          "objectId": null,
          "email": null,
          "name": null
        },
        "lastUpdatedTimeUtc": "2020-02-14T03:16:37Z",
        "createdTimeUtc": "2020-02-13T21:38:26.3121407Z",
        "relatedAlertIds": [
          "8e724b86-039c-48b1-9ef8-75b9d05c2b43"
        ],
        "relatedAlertProductNames": [
          "Azure Security Center"
        ],
        "tactics": [
          "Execution"
        ],
        "caseNumber": 372,
        "lastComment": "Via RDP session from IP: 136.57.182.66 Eagle logged in and enabled a task and executed a run runing cmd line script. Confirmed with Developer this is just a test.",
        "totalComments": 1,
        "metrics": {
          "SecurityAlert": 1
        },
        "firstAlertTimeGenerated": "2020-02-13T21:38:22.5983349Z",
        "lastAlertTimeGenerated": "2020-02-13T21:38:22.5983349Z"
      }
    }

 

 

Title - Matches the alertDisplayName of ASC Alert but is not unique enough in a larger context of duplicate alerts

 

Status – Closed

 

relatedAlertProductNames - this allows us to be distinctive,

 

startTimeUtc - time the Incident was created in Azure Sentinel, this correlates fairly well against ASC detectedTimeUTC but not exactly. Can be off my milliseconds when testing, potential could be off by seconds as well.

 

relatedAlertIds – a corollary guid used in SecurityAlert log Analytics table.

 

On the Get Azure Security Center Alert we also get some interesting information from the property fields in the returned response.

 

 

      "id": "/subscriptions/{subscriptionid}/resourceGroups/{resourcegroupname}/providers/Microsoft.Security/locations/centralus/alerts/2518206709356240952_6010a57b-91e0-422f-8f35-9587f5330771",
      "name": "2518206709356240952_6010a57b-91e0-422f-8f35-9587f5330771",
      "type": "Microsoft.Security/Locations/alerts",
      "properties": {
        "systemSource": "Azure",
        "vendorName": "Microsoft",
        "alertDisplayName": "Suspicious command execution",
        "alertName": "SuspiciousCMDExecution",
        "detectedTimeUtc": "2020-02-13T21:37:44.3759047Z",
        "description": "Machine logs indicate a suspicious command line execution by user %{user name}.",
        "remediationSteps": "1. Validate with '%{user name}' if this action was intentional. If not, Escalate the alert to the information security team\r\n2. Make sure the machine is completely updated and has an updated Anti-Virus installed\r\n3. Install and run Microsoft’s Malicious Software Removal Tool (see https://www.microsoft.com/en-us/download/malicious-software-removal-tool-details.aspx)\r\n4. Run Microsoft’s Autoruns utility and try to identify unknown applications that are configured to run at login (see https://technet.microsoft.com/en-us/sysinternals/bb963902.aspx)\r\n5. Run Process Explorer and try to identify unknown running processes (see https://technet.microsoft.com/en-us/sysinternals/bb896653.aspx)",
        "actionTaken": "Undefined",
        "reportedSeverity": "High",
        "compromisedEntity": "LEVIATHAN",
        "associatedResource": "/subscriptions/{subscriptionid}/resourceGroups/rgHacks4Claps/providers/Microsoft.Compute/virtualMachines/Leviathan",
        "subscriptionId": "{subscriptionid}",
        "instanceId": "6010a57b-91e0-422f-8f35-9587f5330771",
        "extendedProperties": {
          "user name": "WORKGROUP\\Leviathan$",
          "process name": "c:\\windows\\system32\\cmd.exe",
          "command line": "c:\\windows\\system32\\cmd.exe /c net user&echo \"123\"&echo \"open 123 127.0.0.1\" > c:\\alertgeneration\\dummy.txt&exit",
          "process id": "0x398",
          "account logon id": "0x3e7",
          "user SID": "S-1-5-18",
          "parent process id": "0x338",
          "enrichment_tas_threat__reports": "{\"Kind\":\"MultiLink\",\"DisplayValueToUrlDictionary\":{\"Report: Suspicious Command Execution\":\"https://interflowwebportalext.trafficmanager.net/reports/DisplayReport?callerIdentity=ddd5443d-e6f4-441c-b52b-5278d2f21dfa&reportCreateDateTime=2020-02-13T03%3a02%3a12&reportName=MSTI-TS-Suspicious-Command-Execution.pdf&tenantId=96d75fc3-d906-40b3-b826-52a32e91eb61&urlCreateDateTime=2020-02-13T03%3a02%3a12&token=LBN9K4RWKAuxbc%20Sl05Z/Mx1N1XRrrclhLvrIv715a0=\"}}",
          "resourceType": "Virtual Machine"
        },
        "state": "Dismissed",
        "reportedTimeUtc": "2020-02-13T21:38:24.5447196Z",
        "workspaceArmId": "/subscriptions/{subscriptionid}/resourcegroups/rgswiftoperations/providers/microsoft.operationalinsights/workspaces/swiftenvlogs",
        "confidenceScore": 0.348,
        "confidenceReasons": [
          {
            "type": "Process",
            "reason": "Suspicious process cmd.exe triggered this alert on multiple machines in this subscription"
          },
          {
            "type": "Computer",
            "reason": "This alert was triggered multiple times on machine LEVIATHAN in the last 24 hours"
          },
          {
            "type": "User",
            "reason": "User ANONYMOUS LOGON was involved in multiple alerts on machine LEVIATHAN in the last 7 days"
          }
        ],
        "canBeInvestigated": true,
        "isIncident": false,
        "entities": [
          {
            "$id": "centralus_551",
            "dnsDomain": "",
            "ntDomain": "",
            "hostName": "LEVIATHAN",
            "netBiosName": "LEVIATHAN",
            "azureID": "/subscriptions/{subscriptionid}/resourceGroups/rgHacks4Claps/providers/Microsoft.Compute/virtualMachines/Leviathan",
            "omsAgentID": "006d32ae-345d-480c-ae25-c6c183cca496",
            "osFamily": "Windows",
            "osVersion": "Windows",
            "isDomainJoined": false,
            "type": "host"
          },
          {
            "$id": "centralus_552",
            "name": "Leviathan$",
            "ntDomain": "WORKGROUP",
            "host": {
              "$ref": "centralus_551"
            },
            "sid": "S-1-5-18",
            "isDomainJoined": true,
            "type": "account",
            "LogonId": "0x3e7"
          },
          {
            "$id": "centralus_553",
            "processId": "0x338",
            "commandLine": "",
            "host": {
              "$ref": "centralus_551"
            },
            "type": "process"
          },
          {
            "$id": "centralus_554",
            "directory": "c:\\windows\\system32",
            "name": "cmd.exe",
            "type": "file"
          },
          {
            "$id": "centralus_555",
            "processId": "0x398",
            "commandLine": "c:\\windows\\system32\\cmd.exe /c net user&echo \"123\"&echo \"open 123 127.0.0.1\" > c:\\alertgeneration\\dummy.txt&exit",
            "elevationToken": "Default",
            "creationTimeUtc": "2020-02-13T21:37:44.3759047Z",
            "imageFile": {
              "$ref": "centralus_554"
            },
            "account": {
              "$ref": "centralus_552"
            },
            "parentProcess": {
              "$ref": "centralus_553"
            },
            "host": {
              "$ref": "centralus_551"
            },
            "type": "process"
          },
          {
            "$id": "centralus_556",
            "sessionId": "0x3e7",
            "startTimeUtc": "2020-02-13T21:37:44.3759047Z",
            "endTimeUtc": "2020-02-13T21:37:44.3759047Z",
            "type": "host-logon-session",
            "host": {
              "$ref": "centralus_551"
            },
            "account": {
              "$ref": "centralus_552"
            }
          }
        ]
      }
    }

 

 

name – this is the alert name you pass to dismiss the ASC alert in the API

 

alertDisplayName – Matches the title of Azure Sentinel Incident but is not unique enough in a larger context of duplicate alerts

 

detectedTimeUTC – this correlates fairly well against Azure Setinel’s startTimeUtc but not exactly off by milliseconds when testing, potential could be off by seconds as well.

 

State – active or dismissed

 

Direct Match Conclusion

 

What we are left with is a non unique direct match that could have false positives.

 

title == alertDisplayedName

startTimeUtc == detectedTimeUTC < only at the minutes

status == state

 

Due to this we could build a matching logic but questions arise what if there is a delay in timestamps, they are already off by milliseconds what if off by seconds ? How much of a time window would we use to match 1 sec off, 3 seconds off ? The names are too generic on the alert with no unique resource or identifier within the alert name. What if there are multiples or alerts within seconds of each other with same names.

 

You can see that direct match while possible may not be ideal in larger and more complex environments. So how can we solve this mystery, perhaps with a indirect matching method ?

 

The Clue

 

Enter the GUI for Azure Sentinel, while clicking around in the Incident under full details I noticed it had an alert ID, the same that was in the API call as relatedAlertIds but didn’t show up in ASC Alert API call.

 

incidentfulldetails.png

The Alert Id even has a link that takes us to Log Analytics – SecurityAlert table of data that both Azure Sentinel and Azure Security Center can right into.

 

Within that generated KQL query laid the clue that could unravel Azure Sentinel to ASC in a more precise manner.

 

SystemAlertID == AlertLink

 

indirectmatch.png

 

Many times it pays to go above code and look at the Portal UI where hints can be observed visually. Armed with this knowledge and some testing I went to work on a Azure Sentinel Playbook that a SOC Analyst can run when they are ready to close their Incident and then dismiss the corresponding Azure Security Center alert.

 

Designing Azure Sentinel Playbook

 

Designing the Logic app took a few iterations but I finally landed on a pattern that worked in testing. The Logic App pattern is as follows.

 

logicapp1.png

 logicapp2.png

 

logicapp3.png

logicapp4a.png

 

Remember clicking on a dynamic content \ expression will reveal the coded expression used, recall that the Parse JSON still gave us an array rather than foreach when we click in and select the value we will use 0 Index of the array to pass the strings in

 

body('Run_query_and_list_results')['value'][0]['ascsubid']

body('Run_query_and_list_results')['value'][0]['ascrgname']

body('Run_query_and_list_results')['value'][0]['ascalertname']

 

logicapp4.png

 

Conclusion

 

When designing or solving for a problem you should look at the data structures involved behind the scenes and determine can I make a direct match ? If I can’t make a direct match can I use another source of truth on data table somewhere and indirectly match ? Logic Apps are very powerful and easy to use to solve for problems. You don’t need to rely on code dependencies or PowerShell modules. Logic Apps can be used as a managed identity and given certain rights against the Azure Subscription or Resources to make it easy and secure obtaining authorization without having to use a ServicePrincipal and passing AppID and Key to obtain a bearer token to then pass within API call.

 

If you want to try this out you can deploy the Azure Sentinel playbook containing this logic from the  Repository on Github here: https://github.com/Azure/Azure-Sentinel/tree/master/Playbooks/Close-Incident-ASCAlert 

 

deploy.png

 

Special thanks to:

Yuri Diogenes for reviewing this post.

 

9 Comments

Awesome Blogpost ! Thank you :cool:

Microsoft

Cool @Nathan Swift very useful!

Following your concept we could create the same playbook for DefenderATP, AzureATP, CloudApp and third party if they expose API.

Is it correct?

Microsoft

@sifriger Thank you. That is correct a similar concept could be used if APIs and correlation exist in the Microsoft Security products and their alerts. As an example MDATP has an API to update alerts - https://docs.microsoft.com/en-us/windows/security/threat-protection/microsoft-defender-atp/update-al... | and could be correlated by SecurityAlerts KQL table: {field}VendorOriginalId == MDATP {field}Id

Microsoft

Can i close manage Sentinel as well?

a sort of bidirectional if i am in defender i can close the incident in Sentinel and if i am in Sentinel i can close in Defender? 

Microsoft

@sifriger - possibly though getting very complex. Logic Apps may not be best programming model to build that bidirectional synchronization via event driven closure, with a scenario across multiple products. Feel free to DM me in Private Messages or Teams if you would like to discuss more.

 

A slightly different concept was explored though it was timer based one way authoritative sync: Sentinel Close Incident -> ASC Dismiss : https://github.com/swiftsolves-msft/Azure-Sentinel-Playbooks/tree/master/IncidentClosed-Sync-ASCAler...

Microsoft

@PriscilaViana - wrote an awesome blog and playbook extending capability from Sentinel to Dismiss alerts generated from and on MCAS - https://medium.com/@priscilaviana/playbook-for-azure-sentinel-mcas-integration-f939746d3209

Microsoft

@Nathan Swift is there any plans to make this a background item for closing out alerts. If it is closed in ASC then it gets closed in the rest?

Microsoft

Thanks I would check out the private previews and Azure Road map on this item. At this time I am not working on a sync between both systems, it would have to correlate and prevent race conditions between the two platforms in Logic App code. One might be able to build a one way sync the other way though scan dismissed ASC alerts or trigger off the Azure Activity Logs for dismissed alert, potentially correlate SecurityAlertId to AzureSentinel incident and close Sentinel incident.

Microsoft

@Nathan Swift Awesome. I will look into building that out and testing what we can do.