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

1Password - Successful anomalous sign-in

Back
Idceb20a5c-adce-4eba-9728-541361d47d87
Rulename1Password - Successful anomalous sign-in
DescriptionThis will alert when a new successful MFA confirmed sign-in has occurred from a location that was not seen within the last 14 days.

Ref: https://1password.com/

Ref: https://github.com/securehats/
SeverityLow
TacticsInitialAccess
TechniquesT1078
Required data connectors1Password
KindScheduled
Query frequency1h
Query period14d
Trigger threshold0
Trigger operatorgt
Source Urihttps://github.com/Azure/Azure-Sentinel/blob/master/Solutions/1Password/Analytics Rules/1Password - Successful anomalous sign-in.yaml
Version1.0.0
Arm templateceb20a5c-adce-4eba-9728-541361d47d87.json
Deploy To Azure
let rulefrequency = 1h;
let lookback = 14d;
let onePasswordSigninBaseline =
    OnePasswordEventLogs_CL
    | where TimeGenerated between (ago(lookback) .. now())
    | where log_source == "signinattempts"
    | where (category == "success" and action_type == "mfa_ok") or (category == "success" and action_type == "credentials_ok")
    | summarize count() by tostring(target_user.uuid), tostring(target_user.email), tostring(client.ip_address), tostring(location.country)
    | extend identifier = strcat(target_user_uuid, client_ip_address)
    | summarize make_list(identifier)
;
OnePasswordEventLogs_CL
| where TimeGenerated between (ago(rulefrequency) .. now())
| where log_source == "signinattempts"
| where (category == "success" and action_type == "mfa_ok") or (category == "success" and action_type == "credentials_ok")
// limit the amount of incident triggers by enabling and adjusting the following in order to exclude country specific sign-ins
// | where country !in~ ("CA", "US")
| extend identifier = strcat(target_user.uuid, client.ip_address)
| where identifier !in (onePasswordSigninBaseline)
| extend
    TargetUsername = target_user.email
    , SrcIpAddr = client.ip_address
id: ceb20a5c-adce-4eba-9728-541361d47d87
triggerThreshold: 0
incidentConfiguration:
  createIncident: true
  groupingConfiguration:
    lookbackDuration: 1h
    matchingMethod: AllEntities
    enabled: false
    reopenClosedIncident: false
suppressionDuration: 1h
version: 1.0.0
queryPeriod: 14d
eventGroupingSettings:
  aggregationKind: SingleAlert
name: 1Password - Successful anomalous sign-in
suppressionEnabled: false
requiredDataConnectors:
- connectorId: 1Password
  dataTypes:
  - OnePasswordEventLogs_CL
alertDetailsOverride:
  alertDynamicProperties: []
triggerOperator: gt
relevantTechniques:
- T1078
query: |-
  let rulefrequency = 1h;
  let lookback = 14d;
  let onePasswordSigninBaseline =
      OnePasswordEventLogs_CL
      | where TimeGenerated between (ago(lookback) .. now())
      | where log_source == "signinattempts"
      | where (category == "success" and action_type == "mfa_ok") or (category == "success" and action_type == "credentials_ok")
      | summarize count() by tostring(target_user.uuid), tostring(target_user.email), tostring(client.ip_address), tostring(location.country)
      | extend identifier = strcat(target_user_uuid, client_ip_address)
      | summarize make_list(identifier)
  ;
  OnePasswordEventLogs_CL
  | where TimeGenerated between (ago(rulefrequency) .. now())
  | where log_source == "signinattempts"
  | where (category == "success" and action_type == "mfa_ok") or (category == "success" and action_type == "credentials_ok")
  // limit the amount of incident triggers by enabling and adjusting the following in order to exclude country specific sign-ins
  // | where country !in~ ("CA", "US")
  | extend identifier = strcat(target_user.uuid, client.ip_address)
  | where identifier !in (onePasswordSigninBaseline)
  | extend
      TargetUsername = target_user.email
      , SrcIpAddr = client.ip_address  
queryFrequency: 1h
description: |-
  This will alert when a new successful MFA confirmed sign-in has occurred from a location that was not seen within the last 14 days.
  Ref: https://1password.com/
  Ref: https://github.com/securehats/  
entityMappings:
- entityType: Account
  fieldMappings:
  - columnName: TargetUsername
    identifier: FullName
- entityType: IP
  fieldMappings:
  - columnName: SrcIpAddr
    identifier: Address
OriginalUri: https://github.com/Azure/Azure-Sentinel/blob/master/Solutions/1Password/Analytics Rules/1Password - Successful anomalous sign-in.yaml
kind: Scheduled
severity: Low
tactics:
- InitialAccess
{
  "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
  "contentVersion": "1.0.0.0",
  "parameters": {
    "workspace": {
      "type": "String"
    }
  },
  "resources": [
    {
      "apiVersion": "2024-01-01-preview",
      "id": "[concat(resourceId('Microsoft.OperationalInsights/workspaces/providers', parameters('workspace'), 'Microsoft.SecurityInsights'),'/alertRules/ceb20a5c-adce-4eba-9728-541361d47d87')]",
      "kind": "Scheduled",
      "name": "[concat(parameters('workspace'),'/Microsoft.SecurityInsights/ceb20a5c-adce-4eba-9728-541361d47d87')]",
      "properties": {
        "alertDetailsOverride": {
          "alertDynamicProperties": []
        },
        "alertRuleTemplateName": "ceb20a5c-adce-4eba-9728-541361d47d87",
        "customDetails": null,
        "description": "This will alert when a new successful MFA confirmed sign-in has occurred from a location that was not seen within the last 14 days.\nRef: https://1password.com/\nRef: https://github.com/securehats/",
        "displayName": "1Password - Successful anomalous sign-in",
        "enabled": true,
        "entityMappings": [
          {
            "entityType": "Account",
            "fieldMappings": [
              {
                "columnName": "TargetUsername",
                "identifier": "FullName"
              }
            ]
          },
          {
            "entityType": "IP",
            "fieldMappings": [
              {
                "columnName": "SrcIpAddr",
                "identifier": "Address"
              }
            ]
          }
        ],
        "eventGroupingSettings": {
          "aggregationKind": "SingleAlert"
        },
        "incidentConfiguration": {
          "createIncident": true,
          "groupingConfiguration": {
            "enabled": false,
            "lookbackDuration": "PT1H",
            "matchingMethod": "AllEntities",
            "reopenClosedIncident": false
          }
        },
        "OriginalUri": "https://github.com/Azure/Azure-Sentinel/blob/master/Solutions/1Password/Analytics Rules/1Password - Successful anomalous sign-in.yaml",
        "query": "let rulefrequency = 1h;\nlet lookback = 14d;\nlet onePasswordSigninBaseline =\n    OnePasswordEventLogs_CL\n    | where TimeGenerated between (ago(lookback) .. now())\n    | where log_source == \"signinattempts\"\n    | where (category == \"success\" and action_type == \"mfa_ok\") or (category == \"success\" and action_type == \"credentials_ok\")\n    | summarize count() by tostring(target_user.uuid), tostring(target_user.email), tostring(client.ip_address), tostring(location.country)\n    | extend identifier = strcat(target_user_uuid, client_ip_address)\n    | summarize make_list(identifier)\n;\nOnePasswordEventLogs_CL\n| where TimeGenerated between (ago(rulefrequency) .. now())\n| where log_source == \"signinattempts\"\n| where (category == \"success\" and action_type == \"mfa_ok\") or (category == \"success\" and action_type == \"credentials_ok\")\n// limit the amount of incident triggers by enabling and adjusting the following in order to exclude country specific sign-ins\n// | where country !in~ (\"CA\", \"US\")\n| extend identifier = strcat(target_user.uuid, client.ip_address)\n| where identifier !in (onePasswordSigninBaseline)\n| extend\n    TargetUsername = target_user.email\n    , SrcIpAddr = client.ip_address",
        "queryFrequency": "PT1H",
        "queryPeriod": "P14D",
        "severity": "Low",
        "subTechniques": [],
        "suppressionDuration": "PT1H",
        "suppressionEnabled": false,
        "tactics": [
          "InitialAccess"
        ],
        "techniques": [
          "T1078"
        ],
        "templateVersion": "1.0.0",
        "triggerOperator": "GreaterThan",
        "triggerThreshold": 0
      },
      "type": "Microsoft.OperationalInsights/workspaces/providers/alertRules"
    }
  ]
}