let known_domains =
PingFederateEvent
| where TimeGenerated between (ago(14d) .. (1d))
| where isnotempty(DeviceCustomString1)
| extend url_parsed = parse_url(DeviceCustomString1)
| extend url_domain = extract(@'.*\.(.*\.[a-z]+)', 1, tostring(url_parsed.Host))
| summarize makeset(url_domain);
PingFederateEvent
| where isnotempty(DeviceCustomString1)
| extend url_parsed = parse_url(DeviceCustomString1)
| extend url_domain = extract(@'.*\.(.*\.[a-z]+)', 1, tostring(url_parsed.Host))
| where url_domain !in (known_domains)
| extend AccountCustomEntity = DstUserName
| extend IpCustomEntity = SrcIpAddr
name: Ping Federate - Unexpected authentication URL.
query: |
let known_domains =
PingFederateEvent
| where TimeGenerated between (ago(14d) .. (1d))
| where isnotempty(DeviceCustomString1)
| extend url_parsed = parse_url(DeviceCustomString1)
| extend url_domain = extract(@'.*\.(.*\.[a-z]+)', 1, tostring(url_parsed.Host))
| summarize makeset(url_domain);
PingFederateEvent
| where isnotempty(DeviceCustomString1)
| extend url_parsed = parse_url(DeviceCustomString1)
| extend url_domain = extract(@'.*\.(.*\.[a-z]+)', 1, tostring(url_parsed.Host))
| where url_domain !in (known_domains)
| extend AccountCustomEntity = DstUserName
| extend IpCustomEntity = SrcIpAddr
OriginalUri: https://github.com/Azure/Azure-Sentinel/blob/master/Solutions/PingFederate/Analytic Rules/PingFederateUnexpectedAuthUrl.yaml
queryFrequency: 1h
triggerThreshold: 0
requiredDataConnectors:
- dataTypes:
- PingFederateEvent
connectorId: PingFederate
version: 1.0.0
status: Available
queryPeriod: 14d
id: 9578ef7f-cbb4-4e9a-bd26-37c15c53b413
triggerOperator: gt
entityMappings:
- fieldMappings:
- identifier: Name
columnName: AccountCustomEntity
entityType: Account
- fieldMappings:
- identifier: Address
columnName: IpCustomEntity
entityType: IP
relevantTechniques:
- T1078
severity: Medium
description: |
'Detects unexpected authentication URL.'
kind: Scheduled
tactics:
- InitialAccess
{
"$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
"contentVersion": "1.0.0.0",
"parameters": {
"workspace": {
"type": "String"
}
},
"resources": [
{
"id": "[concat(resourceId('Microsoft.OperationalInsights/workspaces/providers', parameters('workspace'), 'Microsoft.SecurityInsights'),'/alertRules/9578ef7f-cbb4-4e9a-bd26-37c15c53b413')]",
"name": "[concat(parameters('workspace'),'/Microsoft.SecurityInsights/9578ef7f-cbb4-4e9a-bd26-37c15c53b413')]",
"type": "Microsoft.OperationalInsights/workspaces/providers/alertRules",
"kind": "Scheduled",
"apiVersion": "2022-11-01",
"properties": {
"displayName": "Ping Federate - Unexpected authentication URL.",
"description": "'Detects unexpected authentication URL.'\n",
"severity": "Medium",
"enabled": true,
"query": "let known_domains = \nPingFederateEvent\n| where TimeGenerated between (ago(14d) .. (1d))\n| where isnotempty(DeviceCustomString1)\n| extend url_parsed = parse_url(DeviceCustomString1)\n| extend url_domain = extract(@'.*\\.(.*\\.[a-z]+)', 1, tostring(url_parsed.Host))\n| summarize makeset(url_domain);\nPingFederateEvent\n| where isnotempty(DeviceCustomString1)\n| extend url_parsed = parse_url(DeviceCustomString1)\n| extend url_domain = extract(@'.*\\.(.*\\.[a-z]+)', 1, tostring(url_parsed.Host))\n| where url_domain !in (known_domains)\n| extend AccountCustomEntity = DstUserName\n| extend IpCustomEntity = SrcIpAddr\n",
"queryFrequency": "PT1H",
"queryPeriod": "P14D",
"triggerOperator": "GreaterThan",
"triggerThreshold": 0,
"suppressionDuration": "PT1H",
"suppressionEnabled": false,
"tactics": [
"InitialAccess"
],
"techniques": [
"T1078"
],
"alertRuleTemplateName": "9578ef7f-cbb4-4e9a-bd26-37c15c53b413",
"customDetails": null,
"entityMappings": [
{
"fieldMappings": [
{
"identifier": "Name",
"columnName": "AccountCustomEntity"
}
],
"entityType": "Account"
},
{
"fieldMappings": [
{
"identifier": "Address",
"columnName": "IpCustomEntity"
}
],
"entityType": "IP"
}
],
"status": "Available",
"templateVersion": "1.0.0",
"OriginalUri": "https://github.com/Azure/Azure-Sentinel/blob/master/Solutions/PingFederate/Analytic Rules/PingFederateUnexpectedAuthUrl.yaml"
}
}
]
}