Microsoft Sentinel

Bring Microsoft Sentinel detections into RegScale. The integration turns Sentinel incidents and alerts into RegScale issues, turns the machines and cloud resources they reference into RegScale assets, files forensic artifacts as evidence, and documents how your Sentinel workspace is configured so auditors can see what you are monitoring for, not only what was found.

Contents

  1. What the integration does
  2. How it works
  3. Prerequisites
  4. Azure permissions
  5. Configuration
  6. Authentication
  7. Azure Government and sovereign clouds
  8. Multiple workspaces
  9. TLS and corporate proxies
  10. Quick start
  11. Command reference
  12. Incremental sync
  13. How Sentinel data maps to RegScale
  14. Writing status back to Sentinel
  15. Documenting workspace configuration
  16. Scheduling
  17. Exit codes
  18. Security and data handling
  19. Troubleshooting

What the integration does

CapabilityCommandReads / writes Azure
Verify configuration and connectivitytest_connectionRead
Import assets referenced by incidentssync_assetsRead
Import incidents as RegScale issuessync_findingsRead
Import alerts (including alerts no incident groups) as issuessync_alertsRead
Import assets referenced by alertssync_alert_assetsRead
Run ad-hoc KQL against the workspacequeryRead
Document rules, connectors, watchlists, threat intelligencesync_contentRead
Close Sentinel incidents when the RegScale issue is resolvedsync_statusWrite (opt-in)

Every command except sync_status only reads from Azure. sync_status is the only
command that changes anything in Sentinel, and it does nothing until you turn it on
explicitly (see Writing status back to Sentinel).

The CLI talks to Azure directly through the official Azure SDK. No intermediary
service or third-party connector sits between your Sentinel workspace and RegScale.

How it works

Microsoft Sentinel workspace
   │  incidents, alerts, entities (management API)
   │  SecurityAlert / SentinelHealth tables (Log Analytics KQL)
   ▼
RegScale CLI  ── normalizes each incident to an OCSF "Detection Finding" ──┐
   │                                                                       │
   ├─► Issues        one per incident (or per alert)                       │
   ├─► Assets        hosts, IPs, Azure resources, accounts, apps           │
   ├─► Evidence      files, hashes, URLs, processes, malware               │
   └─► Data records  rules, connectors, watchlists, threat intelligence    │
                                                                           ▼
                                                    RegScale security plan (or other parent record)

Incidents are normalized to the Open Cybersecurity Schema Framework (OCSF)
Detection Finding class before they become RegScale records. You do not need to
know OCSF to use the integration; it is the reason the same RegScale mapping rules
apply consistently across every incident.

Two Azure endpoints are involved, and they are different services with different
token audiences:

  • Management API (Azure Resource Manager): incidents, entities, rules,
    connectors, watchlists, bookmarks, threat-intelligence indicators.
    Addresses a workspace by subscription / resource group / name.
  • Log Analytics query API: raw tables such as SecurityAlert and
    SentinelHealth, and anything you query with query.
    Addresses a workspace by its GUID.

Incident sync needs only the first. Alert sync, query and connector-health
collection also need the second, which is why workspace_id is optional for some
commands and required for others.

Prerequisites

#RequirementNeeded for
1Microsoft Sentinel enabled on a Log Analytics workspaceEverything
2A credential that can read that workspace (service principal, or managed identity / Azure CLI login)Everything
3The Microsoft Sentinel Reader role on the workspace or its resource groupRead commands
4The Microsoft Sentinel Responder rolesync_status only
5The workspace's subscription id, resource group and nameEverything
6The workspace GUID ("Workspace ID")sync_alerts, sync_alert_assets, query, connector health
7A RegScale security plan (or other parent record) idAll sync_* commands
8azure-monitor-query Python packageAlert sync, query, connector health

The Azure SDK packages for the management API (azure-mgmt-securityinsight,
azure-identity) ship with the CLI. If you run from a stripped-down environment
and see an "Azure SDK" error, install them:

pip install azure-mgmt-securityinsight azure-identity

Log Analytics queries use a separate SDK:

pip install azure-monitor-query

Optionally install azure-mgmt-loganalytics and the CLI will look the workspace
GUID up for you from the workspace name, so you do not have to set workspace_id
by hand. It is also what lets sync_content collect hunting queries.

Finding your workspace coordinates

In the Azure portal open Microsoft Sentinel → your workspace. The Overview
shows the subscription, resource group, workspace name and Workspace ID (the
GUID). From the Azure CLI:

az monitor log-analytics workspace list \
  --query "[].{name:name, resourceGroup:resourceGroup, id:id, customerId:customerId}" -o table

customerId is the value for workspace_id.

Azure permissions

RoleScopeLets the integration
Microsoft Sentinel ReaderWorkspace or its resource groupList incidents, alerts and entities; read rules, connectors, watchlists, bookmarks, TI indicators; run KQL
Microsoft Sentinel ResponderWorkspace or its resource groupEverything above, plus update incident status and add comments (sync_status)

Grant the narrowest role that covers what you run. Reader is sufficient for every
command except sync_status. A role assigned only at the app-registration level
confers nothing on the workspace: the assignment must be on the workspace (or its
resource group).

Reading threat-intelligence indicators can require a role that your Reader
assignment does not include. sync_content handles this gracefully: that one
content type is reported as not collected and the rest of the run continues.

Configuration

Add a sentinel block to init.yaml:

sentinel:
  tenant_id: "00000000-0000-0000-0000-000000000000"
  client_id: "00000000-0000-0000-0000-000000000000"
  client_secret: "your-service-principal-secret"
  cloud: commercial            # commercial | government
  subscription_id: "00000000-0000-0000-0000-000000000000"
  resource_group: "my-resource-group"
  workspace_name: "my-log-analytics-workspace"
  workspace_id: "11111111-1111-1111-1111-111111111111"
  timeout: 60
  page_size: 50
  days_back: 30
  include_closed: false
  enable_write_back: false

Run regscale init to add the block to an existing init.yaml without
overwriting your other settings.

Setting reference

KeyRequiredDefaultDescription
tenant_idWith a service principal—Entra ID (Azure AD) tenant id
client_idWith a service principal—App registration (client) id
client_secretWith a service principal—App registration secret. Treat as a password
cloudNocommercialcommercial or government (details)
subscription_idYes—Subscription that holds the workspace
resource_groupYes—Resource group that holds the workspace
workspace_nameYes—Log Analytics workspace name
workspace_idFor alert sync, query, connector health—Workspace GUID, not the name
workspacesNo—Several workspaces (details). When present, the three required keys above become defaults, not individually required
timeoutNo60Per-request timeout in seconds. Must be greater than 0
page_sizeNo50Incidents per API page. Must be 1–1000
days_backNo30How far back to look. Must be greater than 0
include_closedNofalseInclude incidents Sentinel has closed. By default only New and Active sync
enable_write_backNofalseAllows sync_status to modify Sentinel incidents

Settings are validated before any command runs. A missing or out-of-range value
fails immediately and names the setting.

Authentication

What you put in init.yamlHow the CLI authenticates
tenant_id, client_id and client_secret all setService principal (client secret)
All three omittedDefaultAzureCredential: environment variables (AZURE_TENANT_ID, AZURE_CLIENT_ID, AZURE_CLIENT_SECRET), then managed identity, then an Azure CLI login
One or two of the three setRejected with an error naming the missing key(s)

A partly configured service principal is an error rather than a fallback on
purpose. If the CLI quietly fell back to DefaultAzureCredential it could
authenticate as a different identity from the one you meant, which is far harder
to diagnose than a missing secret.

Recommendation: when the CLI runs inside Azure (a VM, container app, AKS pod,
or Azure Function), use a managed identity and omit all three keys. There is no
secret to store or rotate. Outside Azure, use a service principal with a
short-lived secret, and keep the secret out of source control.

Azure Government

Set one key:

sentinel:
  cloud: government

That single setting switches the sign-in authority, the Azure Resource Manager
endpoint, the Log Analytics endpoint and the OAuth token scopes together.

cloudAlso acceptedSign-in authorityResource ManagerLog Analytics
commercial (default)public, global, azurecloud, azurepubliccloudlogin.microsoftonline.commanagement.azure.comapi.loganalytics.io
governmentgov, govcloud, usgov, usgovernment, azureusgovernment, fairfaxlogin.microsoftonline.usmanagement.usgovcloudapi.netapi.loganalytics.us

An unrecognized value fails at configuration time and lists the accepted names.
It is never silently treated as commercial, because a Government workspace
reached through commercial endpoints fails with an unhelpful authentication error.
Incident links written into RegScale use the matching portal
(portal.azure.com or portal.azure.us).

Multiple workspaces

List additional workspaces under workspaces:

sentinel:
  subscription_id: "00000000-0000-0000-0000-000000000000"
  resource_group: "default-rg"
  workspace_name: "default-sentinel"
  workspaces:
    - resource_group: "east-rg"
      workspace_name: "east-sentinel"
      workspace_id: "11111111-1111-1111-1111-111111111111"
    - subscription_id: "99999999-9999-9999-9999-999999999999"
      resource_group: "west-rg"
      workspace_name: "west-sentinel"
  • Each entry inherits any key it leaves out from the top level, so a
    single-subscription tenant only repeats resource_group and workspace_name.
  • When workspaces is present, the top-level coordinates act only as
    defaults
    . They are not synced as an extra workspace. List the default
    workspace in workspaces too if you want it synced.
  • Each workspace keeps its own sync position (see
    Incremental sync). Adding a workspace never disturbs the
    others, and a workspace that fails mid-run keeps its previous position so the
    next run re-reads what it missed.
  • --limit caps the whole run, not each workspace. --limit 10 across three
    workspaces yields ten items in total, and later workspaces may not be read.
  • test_connection checks every workspace and fails if any one is
    unreachable.
  • query and sync_content accept --workspace resource-group/workspace-name
    (the bare workspace name also works) to target one. query defaults to the
    first workspace; sync_content defaults to all of them.

TLS and corporate certificate authorities

There is deliberately no Sentinel-specific TLS setting. The integration uses the
two CLI-wide settings in init.yaml:

SettingEffect
sslVerifytrue (default) verifies certificates; false disables verification (not recommended)
customCaCertPath to a CA bundle. Takes priority when set and keeps verification on

If the CLI runs behind a TLS-inspecting proxy, or your organization uses a
private or DoD certificate chain, point customCaCert at your bundle. A path that
does not exist raises an error naming the setting; it never silently falls back to
the system trust store.

Quick start

  1. Create credentials. Register an app in Entra ID (or enable a managed
    identity) and assign Microsoft Sentinel Reader on the workspace.

  2. Configure. Add the sentinel block to init.yaml.

  3. Verify.

    regscale sentinel test_connection
    

    Success reports the most recent incident's title and id. A workspace that
    answers but has no incidents in the window is reported with a warning and still
    counts as connected.

  4. Preview without writing.

    regscale sentinel sync_assets --regscale_id 123 --dry-run
    
  5. Import assets, then findings. On a first import run assets first so the
    issues can link to them:

    regscale sentinel sync_assets --regscale_id 123
    regscale sentinel sync_findings --regscale_id 123
    
  6. Schedule the two commands (see Scheduling).

123 is the id of the RegScale security plan the records are created under.

Command reference

All commands are under regscale sentinel. Option names are shown in the
underscore form used throughout this guide; the hyphenated form
(for example --days-back) is equivalent and is what --help displays.

test_connection

regscale sentinel test_connection

Validates the configuration, authenticates, and reads one incident from every
configured workspace. Exits non-zero if the configuration is unusable or any
workspace cannot be reached. Run it before the first sync and after any change to
credentials, roles or network configuration.

sync_assets

regscale sentinel sync_assets --regscale_id 123
regscale sentinel sync_assets --regscale_id 123 --days_back 7 --include_closed

Creates or updates RegScale assets from the entities that Sentinel incidents
reference. Sentinel is not an inventory system, so the asset register only gains
machines and resources Sentinel has actually alerted on. Entities that are
forensic artifacts rather than inventory are filed as evidence
(see mapping).

sync_findings

regscale sentinel sync_findings --regscale_id 123
regscale sentinel sync_findings --regscale_id 123 --days_back 7
regscale sentinel sync_findings --regscale_id 123 --include_closed
regscale sentinel sync_findings --regscale_id 123 --full

Creates or updates one RegScale issue per Sentinel incident, with severity,
status, tactics and techniques, description and a link back to the incident in the
Azure portal.

Options for sync_assets and sync_findings:

OptionDescription
--regscale_idRequired. RegScale record the assets or issues are created under
--days_back NDays of incident history to read. Defaults to the configured days_back
--include_closedInclude closed incidents. Default: New and Active only
--fullIgnore the stored sync position and re-read the whole days_back window
--dry-runDiscover item counts without writing to RegScale
--offset N / --limit NSkip or cap the number of items (used to split a run across parallel jobs). --limit caps the whole run, not each workspace

sync_alerts and sync_alert_assets

regscale sentinel sync_alerts --regscale_id 123
regscale sentinel sync_alerts --regscale_id 123 --standalone_only
regscale sentinel sync_alert_assets --regscale_id 123

An incident is a grouping of alerts, and many analytics rules never create one.
A deployment that only runs sync_findings is therefore blind to every alert no
incident collected. These commands close that gap.

They read the workspace's SecurityAlert table, because the Sentinel management
API has no operation that lists a workspace's alerts. That means they need
workspace_id (or azure-mgmt-loganalytics to look it up) and the
azure-monitor-query package.

If you also run sync_findings, add --standalone_only. Without it, an alert
that belongs to an incident is represented twice: once inside its incident's issue
and once as its own issue. With the flag, only alerts no incident grouped are
imported. Alert issues use the source title Microsoft Sentinel Alerts,
distinct from the incident issues' Microsoft Sentinel, so the two syncs never
close each other's issues.

OptionDescription
--regscale_idRequired. RegScale record to create records under
--days_back NDays of alert history to read. Defaults to the configured days_back
--standalone_onlyOnly alerts that no incident groups
--row_limit NMaximum alerts read per workspace. Default 5000. 0 removes the cap. A capped run is a partial run and the next run continues from where it stopped
--fullIgnore the stored sync position and re-read the whole window
--dry-run, --offset, --limitAs above

Updated alerts are de-duplicated: Sentinel records a new row each time an alert
changes, and only the latest revision of each alert is imported.

query

regscale sentinel query --kql "SecurityAlert | project TimeGenerated, AlertName"
regscale sentinel query --days_back 7 --kql "SigninLogs | where ResultType != 0" --output signins.json
regscale sentinel query --workspace east-rg/east-sentinel --kql "Heartbeat | distinct Computer"

Runs any KQL query against the workspace's Log Analytics tables. Use it for
telemetry the incident API cannot return: sign-ins, security events, heartbeats,
or alerts that never became incidents. Without --output, the command summarizes
the result (column names and the first row); with --output, it writes every row
as JSON.

OptionDescription
--kqlRequired. The KQL query
--days_back NTime range to query. Default 1 (unlike the sync commands)
--row_limit NMaximum rows. Default 5000, applied as a KQL take unless your query already has its own take or limit. 0 removes the cap, which can pull an entire table into memory
--workspaceWhich configured workspace, as resource-group/workspace-name. Default: the first
--output FILEWrite all rows to this file as JSON

A query that times out on the server can still return partial rows. Those rows are
kept rather than discarded, and the partial state is logged.

sync_status

See Writing status back to Sentinel.

sync_content

See Documenting workspace configuration.

Incremental sync

sync_assets, sync_findings, sync_alerts and sync_alert_assets are
incremental by default. After a completed run each records the newest
modification time it saw, and the next run asks Azure only for what changed since
then, minus a ten-minute overlap to absorb clock differences between Azure and the
machine running the CLI. An hourly job therefore reads minutes of data rather than
the whole days_back window each time.

Rules worth knowing:

  • A failed or truncated run does not advance the position. An error, or a run
    cut short by --limit, leaves it where it was. A limited run is a sample, not a
    completed pass, and is never recorded as one.
  • Each command and each workspace has its own position. Asset and finding
    passes are tracked separately so one cannot skip data the other has not seen.
  • Positions advance only after RegScale accepted the writes.
  • Use --full to ignore the position for one run and re-read the entire
    days_back window. Do this after changing mapping-related settings or to
    backfill after a bad import.
  • Positions are stored in sentinel_sync_state.json in the CLI artifacts
    directory, keyed by RegScale record id and workspace. Deleting the file has the
    same effect as --full on the next run.

How Sentinel data maps to RegScale

Overview

SentinelRegScale
IncidentIssue
Incident tactics and techniques (MITRE ATT&CK)ATT&CK detail on the issue
Host, Azure resource, IP address, IoT device entitiesAsset (hardware)
Account, cloud application, security group, mailbox entitiesAsset (software)
File, file hash, malware, process, registry key, submission mail, URL, DNS resolution entitiesEvidence and a plan-level Data record (not assets)
Alert that no incident groupsIssue (via sync_alerts), source "Microsoft Sentinel Alerts"
Analytics rules, automation rules, connectors, watchlists, bookmarks, hunting queries, threat intelligenceData records and an evidence file (via sync_content)

Severity

SentinelRegScale issue severity
CriticalCritical
HighHigh
MediumModerate
LowLow
InformationalNot Assigned
Anything elseNot Assigned

The Sentinel portal offers Informational through High. Critical is mapped anyway
because analytics rules can carry values the portal does not display.

Status

Sentinel statusSentinel classificationRegScale issue
New—Open
Active—Open
ClosedTrue positive or UndeterminedClosed
ClosedFalse positive or Benign positiveClosed (recorded as suppressed)

By default only New and Active incidents are imported, so a routine sync
does not resurrect incidents an analyst has already dispositioned. Add
--include_closed (or include_closed: true) to import closed ones as well.

Entity routing

Sentinel attaches many kinds of entity to an incident, and they are not all the
same kind of thing. Only entities that represent durable inventory become assets.
Inventorying every URL and file hash as an asset would flood the register with
per-incident artifacts.

DestinationEntity kinds
Asset: hardwareHost, AzureResource, Ip, IoTDevice
Asset: softwareAccount, CloudApplication, SecurityGroup, Mailbox
EvidenceFile, FileHash, Malware, Process, RegistryKey, SubmissionMail, Url, DnsResolution
  • An entity kind Microsoft adds in future is filed as evidence under "Other
    Artifacts" rather than as an asset, because an unrecognized kind is far more
    likely to be a forensic artifact than a machine.
  • Nothing is discarded. Every entity, whichever way it routes, still travels with
    the issue as an observable.
  • Evidence artifacts are de-duplicated across the whole run (with the list of
    incidents each appeared in), filed as a plan-level Data record that always
    reflects current state, and uploaded as an evidence file that is a per-run
    snapshot. Collection is capped at 25,000 distinct artifacts per run, with a
    warning if the cap is reached.
  • An entity with no identifying value is skipped rather than given a made-up id.

Linking issues to assets

An issue links to an asset by matching the entity's identifier against the
asset's stored identifier, so run sync_assets before sync_findings on a first
import
, and keep both on the same schedule afterward.

Issue identity

Each issue is keyed on the Sentinel incident's immutable id, so re-running a sync
updates the existing issue rather than creating a duplicate, even if the incident's
title changes.

Writing status back to Sentinel

Every other command reads. sync_status writes into your analysts' live incident
queue, so it is off by default, needs a higher Azure role, and supports a
dry run.

To enable:

  1. Assign Microsoft Sentinel Responder to the credential on the workspace.
  2. Set enable_write_back: true under sentinel: in init.yaml.
# Report what would change without writing anything
regscale sentinel sync_status --regscale_id 123 --dry_run

# Close incidents whose RegScale issue is resolved
regscale sentinel sync_status --regscale_id 123

# Also set incidents back to Active when their RegScale issue is open again
regscale sentinel sync_status --regscale_id 123 --reopen

# Change status without adding the comment to the incident timeline
regscale sentinel sync_status --regscale_id 123 --no_comments
OptionDescription
--regscale_idRequired. RegScale security plan whose Sentinel issues are pushed back
--reopenAlso reactivate incidents whose RegScale issue is open again. Off by default
--no_commentsSkip the audit comment on the incident timeline
--dry_runReport without writing

What gets written

RegScale issue statusSentinel statusClassificationReason
ClosedClosedTrue positive—
CancelledClosedUndetermined—
Exception / WaiverClosedBenign positiveSuspicious but expected
Anything elseUnchanged (Active, with --reopen)——

The mapping is deliberately conservative because Sentinel feeds classifications
back into analytic-rule tuning. The integration never writes "False positive".
A cancelled RegScale ticket does not prove a detection is noise, so it maps to
"Undetermined", which asserts nothing. An incident in New is never moved by
--reopen: untriaged is not closed.

Safeguards

  • Only issues this integration created are considered (source "Microsoft
    Sentinel"). Issues owned by other tools, and alert-sourced issues, are never
    touched.
  • No overwrite of analyst edits. Each incident is read immediately before it
    is written, and the write is rejected by Azure if an analyst changed the
    incident in between. That issue is reported as failed and picked up next run
    against fresh state. Fields the integration does not manage (owner, labels,
    activity times) are preserved.
  • Audit trail. Each change posts a comment on the incident timeline naming the
    RegScale issue and linking to it. Re-runs rewrite that single comment instead of
    stacking new ones. A failed comment never undoes a successful status change.
  • Multiple workspaces. Each workspace is offered the issues no earlier
    workspace could resolve. Only issues that no workspace recognized are
    reported as failures.
  • Exit status. The command exits non-zero if any issue failed, so a scheduled
    run surfaces a broken credential or missing role instead of reporting a clean
    pass that changed nothing.

A Reader-only credential fails per incident with an authorization error rather than
at startup, so assign Responder before enabling write-back.

Documenting workspace configuration

Incidents and alerts record what Sentinel found. sync_content records what it
is configured to look for, which is the evidence an assessor asks for when
reviewing continuous monitoring.

# Everything, for every configured workspace
regscale sentinel sync_content --regscale_id 123

# Only the types an audit asked for
regscale sentinel sync_content --regscale_id 123 --content analytics_rules --content data_connectors

# One workspace, reporting what would be filed without writing it
regscale sentinel sync_content --regscale_id 123 --workspace east-sentinel --dry_run
--content valueDocumentsRead from
analytics_rulesWhich detections are enabled, and their KQLManagement API
automation_rulesWhat fires automatically on an incidentManagement API
bookmarksWhat analysts flagged while huntingManagement API
connector_healthWhether each data connector is actually ingestingSentinelHealth table
data_connectorsWhich sources are wired up at allManagement API
hunting_queriesThe hunts available to analystsLog Analytics saved searches
threat_indicatorsThe threat intelligence the workspace matches againstManagement API
watchlistsReference data that rules join against, items includedManagement API
OptionDescription
--regscale_idRequired. Security plan the content is filed against
--contentContent type to collect. Repeatable. Omit to collect every type
--workspaceOne workspace only (resource-group/workspace-name). Default: all
--days_back NTime range for connector health. Default 30. Ignored by the other types
--dry_runCollect and report without creating records or uploading evidence

How it is filed

None of this is a finding (nothing is wrong) and none of it is an asset, so it is
filed against the security plan in two forms:

  • One Data record per content type per workspace: a trimmed, queryable summary
    of each item, with long text shortened. The record is replaced in place on every
    run so it reflects current state.
  • One evidence file per run per workspace, holding every field of every
    item, including full KQL, threat-indicator patterns and watchlist items.

Behavior when something is unavailable

  • Each type is collected independently. A credential that cannot read threat
    intelligence still gets the analytics rules it can read. The failure is logged
    and named, not raised.
  • Every type is capped. Hitting a cap logs a warning and marks that type
    truncated in both the Data record and the evidence file, so a partial
    threat-intelligence feed is never presented as complete.
  • connector_health needs azure-monitor-query and a workspace GUID, and the
    SentinelHealth table is only populated when Sentinel health diagnostics are
    enabled in the workspace. hunting_queries needs azure-mgmt-loganalytics.
    Without them, only that type is skipped, with the reason logged.
  • An older azure-mgmt-securityinsight that lacks an operation skips that type
    with a warning rather than failing the run.

Scheduling

All commands are ordinary CLI commands and work under cron, systemd timers,
Kubernetes CronJobs, CI schedulers or the RegScale scheduler.

CommandSuggested cadenceNotes
sync_assetsDailyRun before sync_findings on first import
sync_findingsHourly, --days_back 2Window wider than the interval so a missed run self-heals
sync_alerts --standalone_onlyHourlyOnly if you need alerts that never became incidents
sync_statusEvery 15–60 minutesOnly when write-back is enabled
sync_contentWeekly, or before an assessmentDocuments configuration, which changes slowly

Because syncs are incremental, a wide --days_back costs little once the first run
has completed.

Exit codes

ConditionExit code
Command completed0
Configuration invalid, authentication failed, or the sync raised an error1
test_connection: any configured workspace unreachable1
sync_status: any issue failed to update, or write-back is disabled1
sync_content: nothing was collected and something failed1
sync_content: some types collected, some failed0 (failures are logged as warnings)

sync_content treats a partial result as a success on purpose. If a run that
documented seven types and lost one failed the job, operators would learn to ignore
the exit code.

Security and data handling

  • Least privilege. Reader is enough for everything except sync_status.
  • Secrets. client_secret is treated as sensitive. Prefer a managed identity,
    or supply AZURE_* environment variables, so no secret lives in init.yaml.
    Never commit a real secret.
  • Read-only by default. No command writes to Azure unless
    enable_write_back: true is set and sync_status is run.
  • TLS verification is on by default. See
    TLS.
  • What leaves Azure. Incident and alert titles, descriptions, severity,
    status, tactics, entity identifiers (hostnames, IP addresses, account names and
    similar) and, for sync_content, your rule logic and watchlist contents are
    written into RegScale. Review what your watchlists and entities contain before
    syncing to a RegScale instance with a different audience.
  • Logging. Errors are logged with stack traces to the CLI's local log files,
    with credentials redacted.
  • Throttling. Azure responses of 429, 500, 502, 503 and 504 are retried up to
    four times with backoff, honoring the Retry-After header.

Troubleshooting

Start with regscale sentinel test_connection; it separates configuration and
permission problems from mapping problems.

SymptomCause and fix
The Microsoft Sentinel integration requires the Azure SDKStripped environment. pip install azure-mgmt-securityinsight azure-identity
Microsoft Sentinel workspace not configured. Add ...One of subscription_id, resource_group, workspace_name is empty
Incomplete Microsoft Sentinel service principal: missing ...You set one or two of tenant_id / client_id / client_secret. Set all three, or remove all three to use DefaultAzureCredential
Unknown Azure cloud ...cloud is misspelled. Use commercial or government
page_size must be between 1 and 1000, timeout or days_back must be greater than zeroOut-of-range numeric setting
Authentication fails with a service principalCheck the secret has not expired, the tenant id is right, and the role assignment is on the workspace or its resource group
Authorization error (401/403) on a Government workspacecloud is left at commercial. Set cloud: government
Connected, but zero incidentsExpected when the window has none. Widen with --days_back, or add --include_closed
Issues created but not linked to assetsRun sync_assets first, then sync_findings
The same alert appears as two issuesYou ran sync_findings and sync_alerts without --standalone_only
Microsoft Sentinel log queries require the Azure Monitor query SDKpip install azure-monitor-query
No Log Analytics workspace GUID is configuredSet sentinel.workspace_id (Overview blade "Workspace ID"), or install azure-mgmt-loganalytics so it is looked up from the workspace name
connector_health skipped or returns nothingMissing SDK or GUID, or Sentinel health diagnostics are not enabled on the workspace
sync_status says write-back is not availableExpected until enable_write_back: true is set
sync_status fails per incident with an authorization errorThe credential has Reader. Assign Microsoft Sentinel Responder
sync_status reports an incident as failed after an analyst edited itThe safeguard against overwriting analyst changes. The next run retries against fresh state
sync_status reports "not Sentinel incidents"The issue's finding id is not a Sentinel incident GUID, or the issue belongs to another tool
A sync seems to skip dataPositions are incremental. Run with --full to re-read the whole window, and check you did not use --limit, which makes a run partial
Persistent HTTP 429 from AzureRetried automatically. For a large workspace, lower page_size or narrow days_back
Could not reach N of M Sentinel workspace(s)At least one entry under workspaces is wrong or the credential lacks a role there. The log names each failing workspace

For more detail, rerun with --debug and review app.log and errors.log in the
working directory.


Did this page help you?