Microsoft Sentinel Analytic Rules
cloudbrothers.infoAzure Sentinel RepoToggle Dark/Light/Auto modeToggle Dark/Light/Auto modeToggle Dark/Light/Auto modeBack to homepage

Insider Risk_Sensitive Data Access Outside Organizational Geo-location

Back
Idb81ed294-28cf-48c3-bac8-ac60dcef293b
RulenameInsider Risk_Sensitive Data Access Outside Organizational Geo-location
DescriptionThis alert joins Azure Information Protection Logs (InformationProtectionLogs_CL) with Microsoft Entra ID Sign in Logs (SigninLogs) to provide a correlation of sensitive data access by geo-location. Results include User Principal Name, Label Name, Activity, City, State, Country/Region, and Time Generated. Recommended configuration is to include (or exclude) Sign in geo-locations (City, State, Country and/or Region) for trusted organizational locations. There is an option for configuration of correlations against Microsoft Sentinel watchlists. Accessing sensitive data from a new or unauthorized geo-location warrants further review. For more information see Sign-in logs in Microsoft Entra ID: Location Filtering
SeverityHigh
TacticsExfiltration
TechniquesT1567
Required data connectorsAzureActiveDirectory
AzureInformationProtection
KindScheduled
Query frequency6h
Query period6h
Trigger threshold0
Trigger operatorgt
Source Urihttps://github.com/Azure/Azure-Sentinel/blob/master/Solutions/MicrosoftPurviewInsiderRiskManagement/Analytic Rules/InsiderRiskSensitiveDataAccessOutsideOrgGeo.yaml
Version1.1.3
Arm templateb81ed294-28cf-48c3-bac8-ac60dcef293b.json
Deploy To Azure
InformationProtectionLogs_CL
| extend UserPrincipalName = UserId_s
| where LabelName_s <> ""
| join kind=inner (SigninLogs) on UserPrincipalName
| extend City = tostring(LocationDetails.city)
// | where City <> "New York" // Configure Location Details within Organizational Requirements
| extend State = tostring(LocationDetails.state)
// | where State <> "Texas" // Configure Location Details within Organizational Requirements
| extend Country_Region = tostring(LocationDetails.countryOrRegion)
// | where Country_Region <> "US" // Configure Location Details within Organizational Requirements
// | lookup kind=inner _GetWatchlist('<Your Watchlist Name>') on $left.UserPrincipalName == $right.SearchKey
| summarize count() by UserPrincipalName, LabelName_s, Activity_s, City, State, Country_Region, TimeGenerated
| sort by count_ desc
| extend AccountName = tostring(split(UserPrincipalName, "@")[0]), AccountUPNSuffix = tostring(split(UserPrincipalName, "@")[1])
severity: High
name: Insider Risk_Sensitive Data Access Outside Organizational Geo-location
queryPeriod: 6h
eventGroupingSettings:
  aggregationKind: SingleAlert
id: b81ed294-28cf-48c3-bac8-ac60dcef293b
requiredDataConnectors:
- connectorId: AzureInformationProtection
  dataTypes:
  - InformationProtectionLogs_CL
- connectorId: AzureActiveDirectory
  dataTypes:
  - SigninLogs
kind: Scheduled
tactics:
- Exfiltration
triggerThreshold: 0
description: |
    'This alert joins Azure Information Protection Logs (InformationProtectionLogs_CL) with Microsoft Entra ID Sign in Logs (SigninLogs) to provide a correlation of sensitive data access by geo-location. Results include User Principal Name, Label Name, Activity, City, State, Country/Region, and Time Generated. Recommended configuration is to include (or exclude) Sign in geo-locations (City, State, Country and/or Region) for trusted organizational locations. There is an option for configuration of correlations against Microsoft Sentinel watchlists. Accessing sensitive data from a new or unauthorized geo-location warrants further review. For more information see [Sign-in logs in Microsoft Entra ID: Location Filtering](https://docs.microsoft.com/azure/active-directory/reports-monitoring/concept-sign-ins)'
entityMappings:
- fieldMappings:
  - columnName: UserPrincipalName
    identifier: FullName
  - columnName: AccountName
    identifier: Name
  - columnName: AccountUPNSuffix
    identifier: UPNSuffix
  entityType: Account
incidentConfiguration:
  groupingConfiguration:
    reopenClosedIncident: true
    lookbackDuration: 3d
    matchingMethod: Selected
    enabled: true
    groupByEntities:
    - Account
  createIncident: true
triggerOperator: gt
queryFrequency: 6h
relevantTechniques:
- T1567
query: |
  InformationProtectionLogs_CL
  | extend UserPrincipalName = UserId_s
  | where LabelName_s <> ""
  | join kind=inner (SigninLogs) on UserPrincipalName
  | extend City = tostring(LocationDetails.city)
  // | where City <> "New York" // Configure Location Details within Organizational Requirements
  | extend State = tostring(LocationDetails.state)
  // | where State <> "Texas" // Configure Location Details within Organizational Requirements
  | extend Country_Region = tostring(LocationDetails.countryOrRegion)
  // | where Country_Region <> "US" // Configure Location Details within Organizational Requirements
  // | lookup kind=inner _GetWatchlist('<Your Watchlist Name>') on $left.UserPrincipalName == $right.SearchKey
  | summarize count() by UserPrincipalName, LabelName_s, Activity_s, City, State, Country_Region, TimeGenerated
  | sort by count_ desc
  | extend AccountName = tostring(split(UserPrincipalName, "@")[0]), AccountUPNSuffix = tostring(split(UserPrincipalName, "@")[1])  
OriginalUri: https://github.com/Azure/Azure-Sentinel/blob/master/Solutions/MicrosoftPurviewInsiderRiskManagement/Analytic Rules/InsiderRiskSensitiveDataAccessOutsideOrgGeo.yaml
version: 1.1.3
{
  "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
  "contentVersion": "1.0.0.0",
  "parameters": {
    "workspace": {
      "type": "String"
    }
  },
  "resources": [
    {
      "apiVersion": "2023-02-01-preview",
      "id": "[concat(resourceId('Microsoft.OperationalInsights/workspaces/providers', parameters('workspace'), 'Microsoft.SecurityInsights'),'/alertRules/b81ed294-28cf-48c3-bac8-ac60dcef293b')]",
      "kind": "Scheduled",
      "name": "[concat(parameters('workspace'),'/Microsoft.SecurityInsights/b81ed294-28cf-48c3-bac8-ac60dcef293b')]",
      "properties": {
        "alertRuleTemplateName": "b81ed294-28cf-48c3-bac8-ac60dcef293b",
        "customDetails": null,
        "description": "'This alert joins Azure Information Protection Logs (InformationProtectionLogs_CL) with Microsoft Entra ID Sign in Logs (SigninLogs) to provide a correlation of sensitive data access by geo-location. Results include User Principal Name, Label Name, Activity, City, State, Country/Region, and Time Generated. Recommended configuration is to include (or exclude) Sign in geo-locations (City, State, Country and/or Region) for trusted organizational locations. There is an option for configuration of correlations against Microsoft Sentinel watchlists. Accessing sensitive data from a new or unauthorized geo-location warrants further review. For more information see [Sign-in logs in Microsoft Entra ID: Location Filtering](https://docs.microsoft.com/azure/active-directory/reports-monitoring/concept-sign-ins)'\n",
        "displayName": "Insider Risk_Sensitive Data Access Outside Organizational Geo-location",
        "enabled": true,
        "entityMappings": [
          {
            "entityType": "Account",
            "fieldMappings": [
              {
                "columnName": "UserPrincipalName",
                "identifier": "FullName"
              },
              {
                "columnName": "AccountName",
                "identifier": "Name"
              },
              {
                "columnName": "AccountUPNSuffix",
                "identifier": "UPNSuffix"
              }
            ]
          }
        ],
        "eventGroupingSettings": {
          "aggregationKind": "SingleAlert"
        },
        "incidentConfiguration": {
          "createIncident": true,
          "groupingConfiguration": {
            "enabled": true,
            "groupByEntities": [
              "Account"
            ],
            "lookbackDuration": "P3D",
            "matchingMethod": "Selected",
            "reopenClosedIncident": true
          }
        },
        "OriginalUri": "https://github.com/Azure/Azure-Sentinel/blob/master/Solutions/MicrosoftPurviewInsiderRiskManagement/Analytic Rules/InsiderRiskSensitiveDataAccessOutsideOrgGeo.yaml",
        "query": "InformationProtectionLogs_CL\n| extend UserPrincipalName = UserId_s\n| where LabelName_s <> \"\"\n| join kind=inner (SigninLogs) on UserPrincipalName\n| extend City = tostring(LocationDetails.city)\n// | where City <> \"New York\" // Configure Location Details within Organizational Requirements\n| extend State = tostring(LocationDetails.state)\n// | where State <> \"Texas\" // Configure Location Details within Organizational Requirements\n| extend Country_Region = tostring(LocationDetails.countryOrRegion)\n// | where Country_Region <> \"US\" // Configure Location Details within Organizational Requirements\n// | lookup kind=inner _GetWatchlist('<Your Watchlist Name>') on $left.UserPrincipalName == $right.SearchKey\n| summarize count() by UserPrincipalName, LabelName_s, Activity_s, City, State, Country_Region, TimeGenerated\n| sort by count_ desc\n| extend AccountName = tostring(split(UserPrincipalName, \"@\")[0]), AccountUPNSuffix = tostring(split(UserPrincipalName, \"@\")[1])\n",
        "queryFrequency": "PT6H",
        "queryPeriod": "PT6H",
        "severity": "High",
        "suppressionDuration": "PT1H",
        "suppressionEnabled": false,
        "tactics": [
          "Exfiltration"
        ],
        "techniques": [
          "T1567"
        ],
        "templateVersion": "1.1.3",
        "triggerOperator": "GreaterThan",
        "triggerThreshold": 0
      },
      "type": "Microsoft.OperationalInsights/workspaces/providers/alertRules"
    }
  ]
}