Skip to content

Commit f1617bf

Browse files
authored
Merge pull request Azure#12816 from Azure/v-atulyadav/gsa
Fix Rule logic for abnormal protocol
2 parents cff50b4 + 3c4127e commit f1617bf

File tree

5 files changed

+24
-23
lines changed

5 files changed

+24
-23
lines changed

Solutions/Global Secure Access/Analytic Rules/SWG - Abnormal Port to Protocol.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ query: |
3838
| summarize AlertTimeCount = count() by AlertTimeDstPort = DestinationPort, AlertTimeProtocol = TransportProtocol, SourceIp, DestinationFqdn;
3939
AlertTimePortToProtocol
4040
| join kind=leftouter (LearningPortToProtocol) on $left.AlertTimeDstPort == $right.LearningTimeDstPort and $left.SourceIp == $right.SourceIp and $left.DestinationFqdn == $right.DestinationFqdn
41-
| where isnull(LearningTimeProtocol) or LearningTimeProtocol != AlertTimeProtocol
41+
| where LearningTimeProtocol != "" and AlertTimeProtocol != "" and LearningTimeProtocol != AlertTimeProtocol
4242
| project AlertTimeDstPort, AlertTimeProtocol, LearningTimeProtocol, SourceIp, DestinationFqdn
4343
| extend IPCustomEntity = SourceIp, FqdnCustomEntity = DestinationFqdn
4444
entityMappings:
@@ -50,5 +50,5 @@ entityMappings:
5050
fieldMappings:
5151
- identifier: Url
5252
columnName: FqdnCustomEntity
53-
version: 1.0.2
53+
version: 1.0.3
5454
kind: Scheduled

Solutions/Global Secure Access/Data/Solution_GlobalSecureAccess.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
],
2121
"BasePath": "C:\\git\\Azure-Sentinel\\Azure-Sentinel\\Solutions\\Global Secure Access",
22-
"Version": "3.0.0",
22+
"Version": "3.0.1",
2323
"Metadata": "SolutionMetadata.json",
2424
"TemplateSpec": true,
2525
"StaticDataConnectorIds": [
18.3 KB
Binary file not shown.

Solutions/Global Secure Access/Package/mainTemplate.json

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
"email": "[email protected]",
5050
"_email": "[variables('email')]",
5151
"_solutionName": "Global Secure Access",
52-
"_solutionVersion": "3.0.0",
52+
"_solutionVersion": "3.0.1",
5353
"solutionId": "azuresentinel.azure-sentinel-solution-globalsecureaccess",
5454
"_solutionId": "[variables('solutionId')]",
5555
"workbookVersion1": "1.0.1",
@@ -80,11 +80,11 @@
8080
"_analyticRulecontentProductId2": "[concat(take(variables('_solutionId'),50),'-','ar','-', uniqueString(concat(variables('_solutionId'),'-','AnalyticsRule','-','e3b6a9e7-4c3a-45e6-8baf-1d3bfa8e0c2b','-', '1.0.2')))]"
8181
},
8282
"analyticRuleObject3": {
83-
"analyticRuleVersion3": "1.0.2",
83+
"analyticRuleVersion3": "1.0.3",
8484
"_analyticRulecontentId3": "f6a8d6a5-3e9f-47c8-a8d5-1b2b9d3b7d6a",
8585
"analyticRuleId3": "[resourceId('Microsoft.SecurityInsights/AlertRuleTemplates', 'f6a8d6a5-3e9f-47c8-a8d5-1b2b9d3b7d6a')]",
8686
"analyticRuleTemplateSpecName3": "[concat(parameters('workspace'),'/Microsoft.SecurityInsights/',concat(parameters('workspace'),'-ar-',uniquestring('f6a8d6a5-3e9f-47c8-a8d5-1b2b9d3b7d6a')))]",
87-
"_analyticRulecontentProductId3": "[concat(take(variables('_solutionId'),50),'-','ar','-', uniqueString(concat(variables('_solutionId'),'-','AnalyticsRule','-','f6a8d6a5-3e9f-47c8-a8d5-1b2b9d3b7d6a','-', '1.0.2')))]"
87+
"_analyticRulecontentProductId3": "[concat(take(variables('_solutionId'),50),'-','ar','-', uniqueString(concat(variables('_solutionId'),'-','AnalyticsRule','-','f6a8d6a5-3e9f-47c8-a8d5-1b2b9d3b7d6a','-', '1.0.3')))]"
8888
},
8989
"analyticRuleObject4": {
9090
"analyticRuleVersion4": "1.0.2",
@@ -105,7 +105,7 @@
105105
"[extensionResourceId(resourceId('Microsoft.OperationalInsights/workspaces', parameters('workspace')), 'Microsoft.SecurityInsights/contentPackages', variables('_solutionId'))]"
106106
],
107107
"properties": {
108-
"description": "GSAM365EnrichedEvents Workbook with template version 3.0.0",
108+
"description": "GSAM365EnrichedEvents Workbook with template version 3.0.1",
109109
"mainTemplate": {
110110
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
111111
"contentVersion": "[variables('workbookVersion1')]",
@@ -189,7 +189,7 @@
189189
"[extensionResourceId(resourceId('Microsoft.OperationalInsights/workspaces', parameters('workspace')), 'Microsoft.SecurityInsights/contentPackages', variables('_solutionId'))]"
190190
],
191191
"properties": {
192-
"description": "GSANetworkTraffic Workbook with template version 3.0.0",
192+
"description": "GSANetworkTraffic Workbook with template version 3.0.1",
193193
"mainTemplate": {
194194
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
195195
"contentVersion": "[variables('workbookVersion2')]",
@@ -273,7 +273,7 @@
273273
"[extensionResourceId(resourceId('Microsoft.OperationalInsights/workspaces', parameters('workspace')), 'Microsoft.SecurityInsights/contentPackages', variables('_solutionId'))]"
274274
],
275275
"properties": {
276-
"description": "Identity - AfterHoursActivity_AnalyticalRules Analytics Rule with template version 3.0.0",
276+
"description": "Identity - AfterHoursActivity_AnalyticalRules Analytics Rule with template version 3.0.1",
277277
"mainTemplate": {
278278
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
279279
"contentVersion": "[variables('analyticRuleObject1').analyticRuleVersion1]",
@@ -301,10 +301,10 @@
301301
"status": "Available",
302302
"requiredDataConnectors": [
303303
{
304-
"connectorId": "AzureActiveDirectory",
305304
"dataTypes": [
306305
"NetworkAccessTrafficLogs"
307-
]
306+
],
307+
"connectorId": "AzureActiveDirectory"
308308
}
309309
],
310310
"tactics": [
@@ -387,7 +387,7 @@
387387
"[extensionResourceId(resourceId('Microsoft.OperationalInsights/workspaces', parameters('workspace')), 'Microsoft.SecurityInsights/contentPackages', variables('_solutionId'))]"
388388
],
389389
"properties": {
390-
"description": "SWG - Abnormal Deny Rate_AnalyticalRules Analytics Rule with template version 3.0.0",
390+
"description": "SWG - Abnormal Deny Rate_AnalyticalRules Analytics Rule with template version 3.0.1",
391391
"mainTemplate": {
392392
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
393393
"contentVersion": "[variables('analyticRuleObject2').analyticRuleVersion2]",
@@ -415,10 +415,10 @@
415415
"status": "Available",
416416
"requiredDataConnectors": [
417417
{
418-
"connectorId": "AzureActiveDirectory",
419418
"dataTypes": [
420419
"NetworkAccessTrafficLogs"
421-
]
420+
],
421+
"connectorId": "AzureActiveDirectory"
422422
}
423423
],
424424
"tactics": [
@@ -499,7 +499,7 @@
499499
"[extensionResourceId(resourceId('Microsoft.OperationalInsights/workspaces', parameters('workspace')), 'Microsoft.SecurityInsights/contentPackages', variables('_solutionId'))]"
500500
],
501501
"properties": {
502-
"description": "SWG - Abnormal Port to Protocol_AnalyticalRules Analytics Rule with template version 3.0.0",
502+
"description": "SWG - Abnormal Port to Protocol_AnalyticalRules Analytics Rule with template version 3.0.1",
503503
"mainTemplate": {
504504
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
505505
"contentVersion": "[variables('analyticRuleObject3').analyticRuleVersion3]",
@@ -516,7 +516,7 @@
516516
"description": "Identifies changes in the protocol used for specific destination ports, comparing the current runtime with a learned baseline.\nThis can indicate potential protocol misuse or configuration changes.\nConfigurable Parameters:\n- Learning period: The time range to establish the baseline. Default is set to 7 days.\n- Run time: The time range for current analysis. Default is set to 1 day.",
517517
"displayName": "GSA - Detect Protocol Changes for Destination Ports",
518518
"enabled": false,
519-
"query": "let LearningPeriod = 7d;\nlet RunTime = 1d;\nlet StartLearningPeriod = ago(LearningPeriod + RunTime);\nlet EndRunTime = ago(RunTime);\nlet LearningPortToProtocol = \n NetworkAccessTraffic\n | where TimeGenerated between (StartLearningPeriod .. EndRunTime)\n | where isnotempty(DestinationPort)\n | summarize LearningTimeCount = count() by LearningTimeDstPort = DestinationPort, LearningTimeProtocol = TransportProtocol, SourceIp, DestinationFqdn;\nlet AlertTimePortToProtocol = \n NetworkAccessTraffic\n | where TimeGenerated between (EndRunTime .. now())\n | where isnotempty(DestinationPort)\n | summarize AlertTimeCount = count() by AlertTimeDstPort = DestinationPort, AlertTimeProtocol = TransportProtocol, SourceIp, DestinationFqdn;\nAlertTimePortToProtocol\n | join kind=leftouter (LearningPortToProtocol) on $left.AlertTimeDstPort == $right.LearningTimeDstPort and $left.SourceIp == $right.SourceIp and $left.DestinationFqdn == $right.DestinationFqdn\n | where isnull(LearningTimeProtocol) or LearningTimeProtocol != AlertTimeProtocol\n | project AlertTimeDstPort, AlertTimeProtocol, LearningTimeProtocol, SourceIp, DestinationFqdn\n | extend IPCustomEntity = SourceIp, FqdnCustomEntity = DestinationFqdn\n",
519+
"query": "let LearningPeriod = 7d;\nlet RunTime = 1d;\nlet StartLearningPeriod = ago(LearningPeriod + RunTime);\nlet EndRunTime = ago(RunTime);\nlet LearningPortToProtocol = \n NetworkAccessTraffic\n | where TimeGenerated between (StartLearningPeriod .. EndRunTime)\n | where isnotempty(DestinationPort)\n | summarize LearningTimeCount = count() by LearningTimeDstPort = DestinationPort, LearningTimeProtocol = TransportProtocol, SourceIp, DestinationFqdn;\nlet AlertTimePortToProtocol = \n NetworkAccessTraffic\n | where TimeGenerated between (EndRunTime .. now())\n | where isnotempty(DestinationPort)\n | summarize AlertTimeCount = count() by AlertTimeDstPort = DestinationPort, AlertTimeProtocol = TransportProtocol, SourceIp, DestinationFqdn;\nAlertTimePortToProtocol\n | join kind=leftouter (LearningPortToProtocol) on $left.AlertTimeDstPort == $right.LearningTimeDstPort and $left.SourceIp == $right.SourceIp and $left.DestinationFqdn == $right.DestinationFqdn\n | where LearningTimeProtocol != \"\" and AlertTimeProtocol != \"\" and LearningTimeProtocol != AlertTimeProtocol\n | project AlertTimeDstPort, AlertTimeProtocol, LearningTimeProtocol, SourceIp, DestinationFqdn\n | extend IPCustomEntity = SourceIp, FqdnCustomEntity = DestinationFqdn\n",
520520
"queryFrequency": "PT1H",
521521
"queryPeriod": "P8D",
522522
"severity": "Medium",
@@ -527,10 +527,10 @@
527527
"status": "Available",
528528
"requiredDataConnectors": [
529529
{
530-
"connectorId": "AzureActiveDirectory",
531530
"dataTypes": [
532531
"NetworkAccessTrafficLogs"
533-
]
532+
],
533+
"connectorId": "AzureActiveDirectory"
534534
}
535535
],
536536
"tactics": [
@@ -611,7 +611,7 @@
611611
"[extensionResourceId(resourceId('Microsoft.OperationalInsights/workspaces', parameters('workspace')), 'Microsoft.SecurityInsights/contentPackages', variables('_solutionId'))]"
612612
],
613613
"properties": {
614-
"description": "SWG - Source IP Port Scan_AnalyticalRules Analytics Rule with template version 3.0.0",
614+
"description": "SWG - Source IP Port Scan_AnalyticalRules Analytics Rule with template version 3.0.1",
615615
"mainTemplate": {
616616
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
617617
"contentVersion": "[variables('analyticRuleObject4').analyticRuleVersion4]",
@@ -639,10 +639,10 @@
639639
"status": "Available",
640640
"requiredDataConnectors": [
641641
{
642-
"connectorId": "AzureActiveDirectory",
643642
"dataTypes": [
644643
"NetworkAccessTrafficLogs"
645-
]
644+
],
645+
"connectorId": "AzureActiveDirectory"
646646
}
647647
],
648648
"tactics": [
@@ -720,7 +720,7 @@
720720
"apiVersion": "2023-04-01-preview",
721721
"location": "[parameters('workspace-location')]",
722722
"properties": {
723-
"version": "3.0.0",
723+
"version": "3.0.1",
724724
"kind": "Solution",
725725
"contentSchemaVersion": "3.0.0",
726726
"displayName": "Global Secure Access",

Solutions/Global Secure Access/ReleaseNotes.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
| **Version** | **Date Modified (DD-MM-YYYY)** | **Change History** |
22
|-------------|--------------------------------|------------------------------------------------------------------------------------------|
3-
| 3.0.0 | 01-08-2025 | Updates to the workbook to improve the clarity and consistency of titles for visualizations |
3+
| 3.0.1 | 16-09-2025 | Made an update to the logic of the Abnormal Port-to-Protocol **Analytic Rule** |
4+
| 3.0.0 | 01-08-2025 | Updates to the workbook to improve the clarity and consistency of titles for visualizations |
45

56

67

0 commit comments

Comments
 (0)