%3CLINGO-SUB%20id%3D%22lingo-sub-1411515%22%20slang%3D%22en-US%22%3EDeliver%20a%20Security%20Score%20weekly%20briefing%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1411515%22%20slang%3D%22en-US%22%3E%3CP%3EDuring%20Build%202020%20Microsoft%20released%20some%20new%20features%20within%20Azure%20Security%20Center.%20Of%20those%20was%20a%20feature%20much%20desired%20by%20our%20customers%2C%20the%20ability%20to%20obtain%20the%20Security%20Score%20of%20subscriptions%20and%20details%20around%20the%20Security%20Controls%20and%20definitions%20using%20an%20API%20call.%20Cloud%20security%20posture%20management%20(CSPM)%20has%20been%20traditionally%20delivered%20as%20a%20point%20in%20time%20view%20of%20your%20organization%20security%20posture.%20Now%20with%20the%20ability%20to%20export%20the%20score%20and%20security%20control%20details%2C%20one%20of%20the%20exciting%20things%20we%20can%20do%20is%20build%20a%20historical%20baseline%20of%20the%20score%20in%20your%20organization.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EBy%20leveraging%20a%20Microsoft%20Logic%20App%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2FAzure%2FAzure-Security-Center%2Ftree%2Fmaster%2FSecure%2520Score%2FGet-SecureScoreData%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3EGet-SecureScoreData%3C%2FA%3E%26nbsp%3Byou%20can%20export%20the%20Security%20Score%20and%20control%20details%20as%20daily%20snapshots%20into%26nbsp%3BLog%20Analytics%20Workspace.%26nbsp%3BWith%20the%20historical%20data%20being%20kept%20we%20can%20build%20dashboards%2C%20search%20through%20and%20do%20advanced%20triggering%20on%20multiple%20recommendations%2C%20and%20even%20build%20end%20of%20month%20forecasted%20scores%20using%20time%20series%20insights.%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThe%20focus%20here%20will%20be%20another%20way%20you%20can%20leverage%20the%20historical%20data%20and%20deliver%20with%20Logic%20Apps%20a%20Security%20Score%20weekly%20briefing%20to%20your%20compliance%2C%20audit%2C%20and%20security%20teams.%20Weekly%20briefings%20can%20be%20great%20and%20useful%20as%20your%20team%20and%20others%20in%20the%20organization%20start%20the%20week%20looking%20to%20drive%20Security%20Score%2C%20reducing%20risk%20and%20closing%20security%20gaps%20due%20to%20misconfiguration%20of%20cloud%20resources.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ETo%20deliver%20this%20example%20you%20can%20check%20out%20the%26nbsp%3BLogic%20App%20sample%20here%20-ERR%3AREF-NOT-FOUND-Send-SecureScoreBriefing%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ELet%E2%80%99s%20walkthrough%20what%20we%20can%20do%20with%26nbsp%3BLogic%20Apps%26nbsp%3Bto%20store%20historical%20data%20of%20Secure%20Score%20and%20Security%20Control%20details.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CFONT%20size%3D%225%22%3E%3CU%3E%3CFONT%20color%3D%22%233366FF%22%3EBuilding%20the%20Logic%20App%3C%2FFONT%3E%3C%2FU%3E%3C%2FFONT%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ETo%20deliver%20a%20Weekly%20briefing%20you%20want%20to%20start%20with%20a%20trigger%20that%20runs%20weekly%2C%20or%20in%20a%20different%20frequency%20for%20your%20team's%20needs%2C%20as%20shown%20in%20the%20sample%20below%3A%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%221.png%22%20style%3D%22width%3A%20641px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F193869i467EB6A924877193%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%221.png%22%20alt%3D%221.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThere%20are%20some%20nice%20abilities%20as%20well%20like%20setting%20the%20trigger%20to%20a%20time%20zone%20your%20compliance%20and%20security%20teams%20operate%20in%20or%20on%20a%20specific%20minute%20of%20the%20hour%20so%209%3A45%20AM.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ENext%2C%20you%20need%20to%20create%26nbsp%3Bthe%20visualization%20from%20the%20Log%20Analytics%20workspace.%20The%26nbsp%3B-ERR%3AREF-NOT-FOUND-Azure%20Monitor%20Connector%20has%20a%20great%20feature%20to%20do%20that%20%E2%80%93%20%3CEM%3Erun%20query%20and%20visualize%20results%3C%2FEM%3E%20as%20shown%20below%3A%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%222.png%22%20style%3D%22width%3A%20654px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F193870iC38304727C4EC87D%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%222.png%22%20alt%3D%222.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EYou%20will%20get%20an%20easy%20to%20use%20input%20box%20where%20you%20can%20fill%20in%20the%20query%20to%20produce%20a%20desired%20visualization.%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%223.png%22%20style%3D%22width%3A%20937px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F193871i2FD032573F0FA186%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%223.png%22%20alt%3D%223.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EYou%20need%20to%20go%20to%20the%20Log%20Analytics%20workspace%20where%20the%20Secure%20Score%20data%20is%20being%20ingested%20and%20test%20a%20few%20queries%20to%20make%20sure%20you%20have%20the%20desired%20result.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CEM%3E*Note%20you%20can%20choose%26nbsp%3Bthe%20time%20range%20and%20chart%20type%20and%20will%20not%20have%20to%20put%20them%20in%20the%20final%20query.%3C%2FEM%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWithin%20Log%20Analytics%2C%26nbsp%3Bquery%20the%20Custom%20Log%20DataTables%26nbsp%3Busing%20%3CEM%3E%3CSTRONG%3ESecureScore_CL%3C%2FSTRONG%3E%3C%2FEM%3E%26nbsp%3Bor%20%3CEM%3E%3CSTRONG%3ESecureScoreControls_CL%3C%2FSTRONG%3E%3C%2FEM%3E%20as%20shown%20in%20the%20example%20below%3A%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%224.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%2F193873i5AD623F895C675C8%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%224.png%22%20alt%3D%224.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EYou%20can%20see%20that%20the%20data%20coming%20in%20from%20the%20Secure%20Score%20API%20has%20a%20%3CEM%3ECurrent%20Score%3C%2FEM%3E%20and%20%3CEM%3EMax%20Score%3C%2FEM%3E%20per%20subscription.%20This%20is%20not%20the%20percentage%20we%20are%20used%20to%20seeing%20in%20the%20Azure%20Security%20Center%20dashboard%2C%20as%20shown%20in%20the%20example%20below%3A%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%225.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%2F193875i6C9D67C3305F9292%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%225.png%22%20alt%3D%225.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EUsing%26nbsp%3BKusto%20Query%20Language%20(KQL)%26nbsp%3Byou%20can%20use%20some%20functions%20to%20round%20up%20and%20some%20math%20to%20produce%20the%20percentages%20in%20the%20Time%20Series%20Graph%20we%20want%20to%20produce.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CEM%3E%3CSTRONG%3ESecureScore_CL%3C%2FSTRONG%3E%3C%2FEM%3E%3C%2FP%3E%0A%3CP%3E%3CEM%3E%3CSTRONG%3E%7C%20extend%20ScorePrecent%20%3D%20round((round(properties_score_current_d%2C%200)*100)%2Fproperties_score_max_d%2C%200)%2C%20Subscription%20%3D%20strcat(split(id_s%2C%20'%2F')%5B2%5D)%3C%2FSTRONG%3E%3C%2FEM%3E%3C%2FP%3E%0A%3CP%3E%3CEM%3E%3CSTRONG%3E%7C%20summarize%20by%20TimeGenerated%2C%20ScorePrecent%2C%20Subscription%3C%2FSTRONG%3E%3C%2FEM%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EYou%26nbsp%3Balso%20want%20to%20clean%20up%20the%20column%20names%20and%20pulling%20just%20the%20Subscription%20ID%20from%20the%20long%20string%2C%20to%20accomplish%20that%2C%20use%26nbsp%3B%3CEM%3Estrcat%3C%2FEM%3E%20and%20%3CEM%3Esplit%3C%2FEM%3E.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EFinally%2C%20you%20need%20to%20to%20summarize%20the%20result.%20Since%26nbsp%3Bthis%20is%20a%20time%20series%20graph%2C%20you%20need%20to%20start%20with%20%3CEM%3E%3CSTRONG%3ETimeGenerated%3C%2FSTRONG%3E%3C%2FEM%3E%20first%2C%20then%20%3CEM%3E%3CSTRONG%3EScorePercentage%3C%2FSTRONG%3E%3C%2FEM%3E%2C%20and%20finally%20group%20them%20by%20%3CEM%3E%3CSTRONG%3ESubscription%3C%2FSTRONG%3E%3C%2FEM%3E.%26nbsp%3BThe%20nice%20result%20is%20shown%20in%20the%20sample%20below%3A%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%226.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%2F193879i11D3547B2FFE8D7D%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%226.png%22%20alt%3D%226.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EYou%20can%20see%20that%20this%20organization%20has%20been%20making%20great%20progress%20to%20improve%20their%20security%20posture%2C%20but%20on%20one%26nbsp%3Bsubscription%20not%20so%20much%20it%20is%20a%20flat%20line.%20You%20need%20to%20work%20with%20the%20business%20unit%2C%20IT%20teams%2C%20and%20developers%20to%20improve%20that%20score%20next%20week.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ENow%20that%20you%20have%20the%20query%2C%20you%20can%20place%20it%20in%20the%20Logic%20App%20and%20define%20the%20time%20range%2C%20since%20this%20is%20a%20weekly%20briefing%20you%20want%20to%20look%20back%207%20days%2C%20as%20shown%20in%20the%20example%20below%3A%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%227.png%22%20style%3D%22width%3A%20888px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F193880i4C6F5A81C132D033%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%227.png%22%20alt%3D%227.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EMake%20sure%20to%20also%20configure%20the%20chart%20type%20for%20Time%20Series%2C%20as%20shown%20below%3A%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%228.png%22%20style%3D%22width%3A%20699px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F193881i7FEE1F541D93D956%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%228.png%22%20alt%3D%228.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ESince%20you%20will%20be%20embedding%20the%20image%20generated%20into%20an%20email%2C%20you%20need%20to%20initialize%20a%20variable%20as%20a%20string%20and%20define%20in%20HTML%20the%20attachment%20name%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%2210.png%22%20style%3D%22width%3A%20723px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F193883iD25ECAA41B10DE5E%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%2210.png%22%20alt%3D%2210.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EIf%20you%20want%20a%20nice%20HTML%20Table%20as%20well%20after%20the%20trending%20graph%20to%20infer%20what%20Security%20Controls%20they%20want%20to%20target%20to%20drive%20the%20score%20further%2C%20select%20Html%20Table%20under%20Chart%20Type%3A%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%2211.png%22%20style%3D%22width%3A%20620px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F193884i00F0F68F45C218AD%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%2211.png%22%20alt%3D%2211.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3ETo%20send%20an%20email%20you%20will%20use%20the%20initialized%20variable%20plus%20the%20attachment%20to%20deliver%20the%20time%20series%20chart.%20For%20the%20HTML%20Table%2C%20because%20it%20is%20HTML%2C%20you%20can%20just%20reference%20it%20within%20the%20body%20of%20the%20email%20as%20the%20attachment%20content.%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%2212.png%22%20style%3D%22width%3A%20626px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F193885i9579514F0BE2F3D3%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%2212.png%22%20alt%3D%2212.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EIn%20addition%2C%20you%20want%20to%20add%20a%20nice%20hyperlink%20back%20to%20the%20Azure%20Security%20Center%20%E2%80%93%20Secure%20Score%20blade%20in%20the%20event%20our%20compliance%20team%20wants%20to%20dig%20into%20the%20details%20of%20the%20Security%20Controls%20further.%3C%2FP%3E%0A%3CP%3EThe%20screenshot%20below%20reflects%20the%20Security%20Score%20weekly%20briefing%20email%20sample%3A%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%2213.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%2F193886i313F4038A4541ED2%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20title%3D%2213.png%22%20alt%3D%2213.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWe%20learned%20we%20can%20use%20the%20Secure%20Score%20API%20in%20some%20interesting%20ways.%20One%20such%20way%20is%20to%20build%20visualizations%20that%20show%20our%20daily%20progress%20for%20the%20week%20and%20areas%20we%20should%20tackle%20next%20by%20delivering%20an%20email%20that%20acts%20as%20a%20weekly%20briefing.%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3ESpecial%20thanks%20to%3A%3C%2FSTRONG%3E%3C%2FP%3E%0A%3CP%3E%40YuriDiogenes%20for%20reviewing%20this%20port%3C%2FP%3E%0A%3CP%3E%40NicholasDiCola%20for%20creating%20the%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fgithub.com%2FAzure%2FAzure-Security-Center%2Ftree%2Fmaster%2FSecure%2520Score%2FGet-SecureScoreData%22%20target%3D%22_self%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3EGet-SecureScoreData%3C%2FA%3E%20Logic%20App%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWhat%20will%20you%20build%20with%20Secure%20Score%20API%20%3F%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-TEASER%20id%3D%22lingo-teaser-1411515%22%20slang%3D%22en-US%22%3E%3CP%3EDuring%20Build%202020%20Microsoft%20released%20some%20new%20features%20within%20Azure%20Security%20Center.%20Of%20those%20was%20a%20feature%20much%20desired%20by%20our%20customers%2C%20the%20ability%20to%20obtain%20the%20Security%20Score%20of%20subscriptions%20and%20details%20around%20the%20Security%20Controls%20and%20definitions%20using%20an%20API%20call.%20Cloud%20security%20posture%20management%20(CSPM)%20has%20been%20traditionally%20delivered%20as%20a%20point%20in%20time%20view%20of%20your%20organization%20security%20posture.%20Now%20with%20the%20ability%20to%20export%20the%20score%20and%20security%20control%20details%2C%20one%20of%20the%20exciting%20things%20we%20can%20do%20is%20build%20a%20historical%20baseline%20of%20the%20score%20in%20your%20organization.%3C%2FP%3E%3C%2FLINGO-TEASER%3E
Microsoft

During Build 2020 Microsoft released some new features within Azure Security Center. Of those was a feature much desired by our customers, the ability to obtain the Security Score of subscriptions and details around the Security Controls and definitions using an API call. Cloud security posture management (CSPM) has been traditionally delivered as a point in time view of your organization security posture. Now with the ability to export the score and security control details, one of the exciting things we can do is build a historical baseline of the score in your organization.

 

By leveraging a Microsoft Logic App Get-SecureScoreData you can export the Security Score and control details as daily snapshots into Log Analytics Workspace. With the historical data being kept we can build dashboards, search through and do advanced triggering on multiple recommendations, and even build end of month forecasted scores using time series insights. 

 

The focus here will be another way you can leverage the historical data and deliver with Logic Apps a Security Score weekly briefing to your compliance, audit, and security teams. Weekly briefings can be great and useful as your team and others in the organization start the week looking to drive Security Score, reducing risk and closing security gaps due to misconfiguration of cloud resources.

 

To deliver this example you can check out the Logic App sample here Send-SecureScoreBriefing

 

Let’s walkthrough what we can do with Logic Apps to store historical data of Secure Score and Security Control details.

 

Building the Logic App

 

To deliver a Weekly briefing you want to start with a trigger that runs weekly, or in a different frequency for your team's needs, as shown in the sample below:

 

1.png

 

There are some nice abilities as well like setting the trigger to a time zone your compliance and security teams operate in or on a specific minute of the hour so 9:45 AM.

 

Next, you need to create the visualization from the Log Analytics workspace. The Azure Monitor Connector has a great feature to do that – run query and visualize results as shown below:

 

2.png

 

You will get an easy to use input box where you can fill in the query to produce a desired visualization.

 

3.png

 

You need to go to the Log Analytics workspace where the Secure Score data is being ingested and test a few queries to make sure you have the desired result.

 

*Note you can choose the time range and chart type and will not have to put them in the final query.

 

Within Log Analytics, query the Custom Log DataTables using SecureScore_CL or SecureScoreControls_CL as shown in the example below:

 

4.png

 

You can see that the data coming in from the Secure Score API has a Current Score and Max Score per subscription. This is not the percentage we are used to seeing in the Azure Security Center dashboard, as shown in the example below:

 

5.png

 

Using Kusto Query Language (KQL) you can use some functions to round up and some math to produce the percentages in the Time Series Graph we want to produce.

 

SecureScore_CL

| extend ScorePrecent = round((round(properties_score_current_d, 0)*100)/properties_score_max_d, 0), Subscription = strcat(split(id_s, '/')[2])

| summarize by TimeGenerated, ScorePrecent, Subscription

 

You also want to clean up the column names and pulling just the Subscription ID from the long string, to accomplish that, use strcat and split.

 

Finally, you need to to summarize the result. Since this is a time series graph, you need to start with TimeGenerated first, then ScorePercentage, and finally group them by Subscription. The nice result is shown in the sample below:

 

6.png

 

You can see that this organization has been making great progress to improve their security posture, but on one subscription not so much it is a flat line. You need to work with the business unit, IT teams, and developers to improve that score next week.

 

Now that you have the query, you can place it in the Logic App and define the time range, since this is a weekly briefing you want to look back 7 days, as shown in the example below:

 

7.png

 

Make sure to also configure the chart type for Time Series, as shown below:

 

8.png

 

 

Since you will be embedding the image generated into an email, you need to initialize a variable as a string and define in HTML the attachment name

 

10.png

 

If you want a nice HTML Table as well after the trending graph to infer what Security Controls they want to target to drive the score further, select Html Table under Chart Type:

 

11.png

 

To send an email you will use the initialized variable plus the attachment to deliver the time series chart. For the HTML Table, because it is HTML, you can just reference it within the body of the email as the attachment content.

 

12.png

 

In addition, you want to add a nice hyperlink back to the Azure Security Center – Secure Score blade in the event our compliance team wants to dig into the details of the Security Controls further.

The screenshot below reflects the Security Score weekly briefing email sample:

 

13.png

 

We learned we can use the Secure Score API in some interesting ways. One such way is to build visualizations that show our daily progress for the week and areas we should tackle next by delivering an email that acts as a weekly briefing.

 

Special thanks to:

@YuriDiogenes for reviewing this port

@NicholasDiCola for creating the Get-SecureScoreData Logic App

 

What will you build with Secure Score API ?