ניהול עלויות בתשתית Azure Sentinel (טיפים + KQL)
ההבדל בין יישום מוצלח בענן לבין יישום כושל בענן הוא עלויות, ולכן רגע לפני שמיישמים פתרון בענן טוב ככל שיהיה חייבים לתכנן את העלויות, והדבר נכון גם לתכנון פתרון SIEM בענן מבוסס Azure Sentinel.
המאמר הנוכחי מתמקד במספר טיפים לניהול עלויות בתשתית Azure Sentinel עם שאילתות KQL, ומתבסס על נקודות מסוימות מתוך המאמרים הבאים מהבלוג הנוסף:
Azure Sentinel Cost Optimization KQL Tips
Azure Sentinel from the Field – The Cloud Aspect
טיפים בניהול עלויות Azure Sentinel
ישנו הבדל עצום בין תשתית SIEM בענן לבין תשתית SIEM קלאסית (או כמו שאני קורא לזה Legacy SIEM) ותשתית SIEM בענן סופרת את האבנטים אחרת, למשל EPS נספרים אחרת כי לא מדובר על אבנטים אשר שוקלים 1K ויותר אלא מדובר על JSON אשר נספרים אחרת ועם משקל של עד 500 בייטים (במקסימום).
מכיוון שתשתית SIEM בענן עובדת בצורה אחרת מאשר תשתית Legacy SIEM אפשר לראות זאת בהיבטים שונים. כמה נקודות, יתרונות ודגשים מתוך השטח לתשתית Azure Sentinel. לאחר חיבור מקורות מידע של עשרות טרה (1TB) בחודש.
עלות חיבור מקורות מידע בענן מבוססים Microsoft אל Azure Sentinel היא זולה יותר
חיבור מקורות מידע בענן מבוססים Microsoft אל Azure Sentinel מפורסרים טוב יותר
חיבור מקורות מידע בענן צד שלישי כדוגמת Salesforce, Cisco, OKTA זולים יותר ומבוססים על JSON
תהליך Onboarding של מקורות מידע ופתרונות צד שלישי היא קלה ובעלת יתרון מול Azure Sentinel
האפשרויות ניהול של מקורות המידע נעשים בצורה אוטומטית וחוסכים עלויות בניהול תשתיות SIEM
מעקב וניהול עלויות בתשתית Azure Sentinel הוא פשוט יותר וניתן למדידה שעתית
מעקב אחר עלויות
ישנם דרכים שונות ומגוונות לעקוב אחר עלויות בתשתית Azure Sentinel ותמיד אפשר לקבל הבנה ראשונית דרך ממשק Usage and estimated costs, אבל זה ממש לא מספיק כאשר רוצים להבין עלויות לעומק ובטח כאשר מתכננים עלויות של מיליוני לוגים ביום.
בכדי להבין טוב יותר מה קורה בתוך הקופסה אנו חייבים לעבוד עם KQL ולהריץ שאילתות מסוימות, אז כמה שאילתות שיכולות לסייע ביומיום.
תחילה נבין איזה טבלאות עיקריות קיימות בתשתית, ואפשר להוריד את החלק של render piechart בכדי לקבל רשימה רגילה
search *
| where TimeGenerated > ago(31d)
| summarize count() by $table
| sort by count_ desc
| render piechart
טיפ: אפשר לייצא את הרשימה לקובץ CSV
טבלאות, נתונים ועלויות – נתקדם לשאילתה הבאה והפעם אפשר להוציא רשימה עם טבלאות עיקריות, כמות המידע ועלות מוערכת לכל טבלה.
let aap = 2.20;
union isfuzzy=true withsource = tt *
| where TimeGenerated > ago(31d)
| where _IsBillable == True
| where tt in
(
“Perf”, “Event”, “DeviceEvents”, ” SecurityEvent”, ” DeviceNetworkEvents”,
“DeviceFileEvents”, ” DeviceProcessEvents”, ” DeviceFileCertificateInfo”, ” SecurityRegulatoryCompliance”,
“AADNonInteractiveUserSignInLogs”, ” AzureActivity”, ” DeviceRegistryEvents”, ” DeviceNetworkInfo”,
“ADCSV_CL”, ” AD_Metadata_CL”, ” DeviceImageLoadEvents”, ” Usage”, ” OfficeActivity”, ” Operation”,
” Heartbeat”, ” DeviceInfo”, ” DeviceLogonEvents”, ” SigninLogs”, ” DnsEvents”, ” SecurityBaseline”,
” UserPeerAnalytics”, ” AuditLogs”, ” SecurityRecommendation”, ” SecurityAlert”, ” UserAccessAnalytics”,
“SecurityIncident”, ” AADManagedIdentitySignInLogs”, ” ADDS_Metadata_CL”, ” SecureScores”,
” Update”, ” SecurityNestedRecommendation”, ” SecureScoreControls”, ” DnsInventory”, ” ProtectionStatus”,
“SecurityDetection”, ” AADServicePrincipalSignInLogs”, ” ComputerGroup”, ” UpdateSummary”, ” AD_Metadata1_CL”, ” SecurityBaselineSummary”
)
| summarize
TotalGBytes =round( sum(_BilledSize/(1024*1024*1024)),2),
EstimatedCostUSD=round(aap * sum(_BilledSize/(1024*1024*1024)),2)
by Solution=tt
| sort by TotalGBytes desc
טיפ: חשוב מאוד לשנות את הטבלאות בהתאם לרשימה מתוך השאילתה הקודמת וזאת על מנת לקבל את הרשימה העדכנית
נתונים מבוססים Nodes עם עלויות חודשיות ויומיות
find where TimeGenerated >= startofday(ago(31d)) and TimeGenerated < startofday(now())
project Computer, _IsBillable, Type, TimeGenerated
| where Type !in
(
“Perf”, “Event”, “DeviceEvents”, ” SecurityEvent”, ” DeviceNetworkEvents”,
“DeviceFileEvents”, ” DeviceProcessEvents”, ” DeviceFileCertificateInfo”, ” SecurityRegulatoryCompliance”,
“AADNonInteractiveUserSignInLogs”, ” AzureActivity”, ” DeviceRegistryEvents”, ” DeviceNetworkInfo”,
“ADCSV_CL”, ” AD_Metadata_CL”, ” DeviceImageLoadEvents”, ” Usage”, ” OfficeActivity”, ” Operation”,
” Heartbeat”, ” DeviceInfo”, ” DeviceLogonEvents”, ” SigninLogs”, ” DnsEvents”, ” SecurityBaseline”,
” UserPeerAnalytics”, ” AuditLogs”, ” SecurityRecommendation”, ” SecurityAlert”, ” UserAccessAnalytics”,
“SecurityIncident”, ” AADManagedIdentitySignInLogs”, ” ADDS_Metadata_CL”, ” SecureScores”,
” Update”, ” SecurityNestedRecommendation”, ” SecureScoreControls”, ” DnsInventory”, ” ProtectionStatus”,
“SecurityDetection”, ” AADServicePrincipalSignInLogs”, ” ComputerGroup”, ” UpdateSummary”, ” AD_Metadata1_CL”, ” SecurityBaselineSummary”
)
| extend computerName = tolower(tostring(split(Computer, ‘.’)[0]))
| where computerName != “”
| where _IsBillable == true
| summarize billableNodesPerHour=dcount(computerName) by bin(TimeGenerated, 1h)
| summarize billableNodesPerDay = sum(billableNodesPerHour)/24., billableNodeMonthsPerDay = sum(billableNodesPerHour)/24./31. by day=bin(TimeGenerated, 1d)
| sort by billableNodesPerDay desc
לכל השאילתות בקישור הבא Azure-Sentinel-4-SecOps/Cost