Skip to content
Export guide · SIEM

How to export your Microsoft Sentinel configuration, and what we check in it

Where you run it: Azure CLI (az rest, signed in with read access to the workspace) and jq.

In short

Microsoft Sentinel configuration export: the file Microsoft Sentinel writes of its own settings, which a configuration review reads setting by setting without connecting to Microsoft Sentinel.

How to export the Microsoft Sentinel configuration, step by step, what the review checks in the file (42 checks run), and what it does not read.

The fileJSON, one sentinel-rules.json: a list of analytics rules, each with its settings under "properties"
Checks run on it42
Highest grade its findings reachPROVEN
Feeds attack pathsYes
Not read from this export2 areas, listed below

Sources: Microsoft Sentinel documentation (1); Microsoft Sentinel documentation (2); Microsoft Sentinel documentation (3); the vendor table.

How to export it

Who can pull it
The Azure built-in role Reader on the resource group that holds the Microsoft Sentinel workspace: its one action is */read, which lets you list the workspace and read its analytics rules (Microsoft.SecurityInsights/alertRules). Microsoft Sentinel Reader on that resource group also works ("View data, incidents, workbooks, recommendations and other resources"); its definition also holds Microsoft.Insights/alertRules/*, Microsoft.Resources/deployments/* and Microsoft.Support/*, which Microsoft describes as creating and managing classic metric alerts, deployments and support tickets. Microsoft says to assign Sentinel roles at the resource group level. Azure Cloud Shell needs the Microsoft.CloudShell resource provider registered on the subscription, once; a Reader cannot register it, so if Cloud Shell will not start, ask a subscription Owner or Contributor to register it (Subscriptions → the subscription → Resource providers → Microsoft.CloudShell → Register), or run the commands with the Azure CLI on your own computer.
Time
About 10 minutes on a new setup (signing in and finding the workspace values); about 2 minutes on later runs.
The file
JSON, one sentinel-rules.json: a list of analytics rules, each with its settings under "properties"

No console export: The Microsoft Sentinel Analytics page can export rules (Analytics → select the rules → Export; Microsoft marks this export PREVIEW and it takes one page of rules at a time) to Azure_Sentinel_analytic_rule.json (Azure_Sentinel_analytic_rules.json when you export several). This guide does not use that file: the review reads the list the commands below write. Azure Cloud Shell (the Cloud Shell button in the top navigation of the Azure portal, then Bash) already has az and jq.

From the command line

  1. az login(signs you in: by default the Azure CLI uses Web Account Manager on Windows and your browser on Linux and macOS; if you have more than one Azure subscription, then run az account set --subscription "<subscription name or ID>"for the one that holds Microsoft Sentinel. In Azure Cloud Shell you are already signed in: skip az login, but still run az account set if you have more than one subscription)

    The vendor's page, checked 2026-11-11
  2. az monitor log-analytics workspace list --query "[].id" -o tsv(prints one line per workspace, shaped /subscriptions/<subscription-id>/resourceGroups/<rg>/providers/Microsoft.OperationalInsights/workspaces/<ws>; add --resource-group <rg>to list one resource group. From the line of your Microsoft Sentinel workspace, copy those three values into the next command)

    The vendor's page, checked 2026-11-11
  3. az rest --method get --url "https://management.azure.com/subscriptions/<subscription-id>/resourceGroups/<rg>/providers/Microsoft.OperationalInsights/workspaces/<ws>/providers/Microsoft.SecurityInsights/alertRules?api-version=2025-07-01-preview" > alert-rules.json

    The vendor's page, checked 2026-11-11
  4. jq '.value' alert-rules.json > sentinel-rules.json(if alert-rules.json has a nextLink, run az rest --method get --url "$(jq -r '.nextLink' alert-rules.json)" > alert-rules-2.jsonso jq writes the nextLink in and the shell never reads its $skipToken as a variable; if that answer has a nextLink too, do the same from alert-rules-2.json into alert-rules-3.json, and so on until one has none. Then write sentinel-rules.json with jq -s 'map(.value) | add' alert-rules.json alert-rules-2.json > sentinel-rules.jsoninstead, naming every page file you saved)

    The vendor's page, checked 2026-10-19
  5. In Cloud Shell, choose Manage files > Download and enter the full path of sentinel-rules.json (run realpath sentinel-rules.json to print it; if Cloud Shell started with No storage account required, download it before you close Cloud Shell, because that session deletes its files); on your own computer the file is already in the folder you ran the commands in

    The vendor's page, checked 2026-11-11

What the file looks like

JSON, one sentinel-rules.json: a list of analytics rules, each with its settings under "properties". It varies with the number of rules and the length of each rule’s query. The upload takes files up to 10 MB.

What it holds: Every analytics rule in the workspace (Scheduled, NRT, Fusion and the other kinds) with its settings, in one sentinel-rules.json.

Upload sentinel-rules.json: alert-rules.json on its own is not read. az sentinel alert-rule list is not used here: it moves each rule’s settings out of "properties", and the review then misreads which rules are on and which tactics they cover. Run these commands in bash (macOS, Linux, WSL, or Bash in Azure Cloud Shell): in Windows PowerShell 5.1, > writes UTF-16, which jq and the upload refuse.

Afterwards

Nothing to revoke: the steps create no key, token or account. After the download, run rm alert-rules*.json sentinel-rules.json and close Cloud Shell; a session started with No storage account required deletes its files when it ends. On your own computer run az logout to remove the saved sign-in. If Reader was given to you for this export, ask for it to be removed.

If the export goes wrong

What you seeThe fix
az rest answers with the error code AuthorizationFailed: your account "does not have authorization to perform action" on the analytics rules.Ask an administrator who can assign roles to give you Reader (or Microsoft Sentinel Reader) on the workspace’s resource group (Azure portal → Resource groups → that group → Access control (IAM) → Add → Add role assignment). Microsoft says a new role can take up to 10 minutes; sign out and in again (az logout, then az login) to refresh it, then repeat the az rest step.
The upload says "No Microsoft.SecurityInsights resources found in input".Upload sentinel-rules.json, the file the jq step writes. Do not upload alert-rules.json, or the file the portal’s Export button writes: Azure_Sentinel_analytic_rule.json (Azure_Sentinel_analytic_rules.json when you export several).
The terminal says it cannot find the jq or az command.Run the steps in Azure Cloud Shell (Bash), which has both, or install jq and the Azure CLI (learn.microsoft.com/cli/azure/install-azure-cli) and open a new terminal.

What we read from it

Checks run
42 + 10 guidance items, not counted
Formats read
ARM template / JSON export of analytic + automation rules
Releases
2024.1 to current

Checks run is the number of checks that reached a result on this system's own export in our tests, as the vendor table shows it.

The areas checked

  • Analytics rules: enabled or disabled, MITRE ATT&CK mapping, query period, suppression, incident creation, severity
  • The Fusion rule: whether it is turned on

The grade its findings reach

Proven A finding from this file can reach PROVEN: the stored file is read a second time by a separate reader, and the finding is found at the setting it names.

Its findings feed attack paths: each one can be a step on a path an attacker could take to your crown jewels.

Attack paths, the one change and dollar figures are MODELED. How each grade is worked out is on the method page.

What we do not read from this export

  • Custom detection rules made in the Microsoft Defender portal: not in this export
  • Automation rules and playbooks: not in the alert-rule export
  • Data connectors and their state: not in the alert-rule export
  • Workspace settings (retention, UEBA, public network access, watchlists, threat intelligence): not in the alert-rule export
  • How often each rule fired (alerts and incidents)
  • The KQL inside each rule, in depth
  • Workbooks and hunting queries
  • Whether connectors are actually receiving data

Limits of the reader

  • If your export leaves a section out, the review does not flag it as partial.
  • The checks of this system are not counted: a check counts once a test shows it firing on a file in the layout the vendor documents.

A finding never comes from what the file does not hold: live traffic, running hosts and logs are not in a configuration export.

Questions

Who can export the Microsoft Sentinel configuration?

The Azure built-in role Reader on the resource group that holds the Microsoft Sentinel workspace: its one action is */read, which lets you list the workspace and read its analytics rules (Microsoft.SecurityInsights/alertRules). Microsoft Sentinel Reader on that resource group also works ("View data, incidents, workbooks, recommendations and other resources"); its definition also holds Microsoft.Insights/alertRules/*, Microsoft.Resources/deployments/* and Microsoft.Support/*, which Microsoft describes as creating and managing classic metric alerts, deployments and support tickets. Microsoft says to assign Sentinel roles at the resource group level. Azure Cloud Shell needs the Microsoft.CloudShell resource provider registered on the subscription, once; a Reader cannot register it, so if Cloud Shell will not start, ask a subscription Owner or Contributor to register it (Subscriptions → the subscription → Resource providers → Microsoft.CloudShell → Register), or run the commands with the Azure CLI on your own computer.

Does the export change anything?

Nothing in the workspace: both Azure calls are GET (read) requests. On your side, az login saves a sign-in token on your computer and Microsoft Entra logs the sign-in, az account set changes the active subscription in your Azure CLI profile, and the steps write alert-rules.json and sentinel-rules.json.

Does the file hold passwords or keys?

No password, key or token field in Microsoft’s documented response. In clear text it holds the full query of each rule, which shows what you detect and can name internal hosts, accounts, address ranges and watchlists your team wrote in, plus rule names, descriptions, custom details, entity mappings and resource IDs with your subscription ID, resource group and workspace name. With redaction on (the default), the passwords, keys and tokens the review recognises are replaced with a placeholder before anything is stored; the check before upload shows how many it found.