Free plan available. Set up in minutes with the collectors you already use. Start free
Logthread

Integration

Azure WAF management

Your Application Gateway WAF, read only: every gateway and policy with its mode, rule sets and logs, the rules that block real users, false-positive candidates previewed on your own traffic, and copy-ready fixes (Azure CLI, Terraform, Bicep). Logthread never changes your WAF.

  • Category: Security
  • How data is sent: Logthread reads the API with a token you create (nothing to install)
  • Status: Beta

How it works#

  1. Answer a few questions. The ids and client secret of the read-only app registration made in "Before you start". The secret is stored encrypted and never shown again; Logthread reads with it and changes nothing in your tenant.
  2. Logthread reads your WAF configuration every 15 minutes. Nothing to install: with the read-only role, Logthread lists your Application Gateways and WAF policies (Resource Graph, or each subscription when that is not allowed) and keeps each policy's versions. It never changes them.
  3. Data arrives. Security → WAF shows every gateway with its policy, mode and rule sets, and what to fix. The rule analysis reads the Application Gateway WAF and access logs your Azure integration sends as service azure, with its parser on.

Before you start#

1. Register an app in your tenant. In the Microsoft Entra admin center (entra.microsoft.com): Identity, Applications, App registrations, New registration. Name it Logthread audit reader, choose Accounts in this organizational directory only, leave Redirect URI empty, then Register. The Overview page shows the Application (client) ID and the Directory (tenant) ID asked for below.

2. Create a client secret. Certificates & secrets, Client secrets, New client secret, an expiry of up to 24 months. Copy its Value straight away and paste it below with its expiry date. Already connected Entra ID or Microsoft 365? Use the same app registration and secret: no Graph permission is needed for this.

What you answer#

QuestionAnswerNotes
Directory (tenant) IDTextOn the app registration's Overview page, a GUID.
Application (client) IDTextOn the same Overview page, a GUID.
Client secret valueSecret (stored encrypted, never shown)The Value column of the new secret (not its Secret ID); stored encrypted.
Client secret expires onDate (YYYY-MM-DD)Home reminds you 30 days before, with a guided way to replace it. Where to find it: In the Microsoft Entra admin center, open the app registration, then Certificates & secrets, Client secrets. The Expires column shows the date for each secret; use the one of the secret you are pasting.
Subscription IDsTextComma separated, up to 20: the subscriptions whose gateways and WAF policies to read. Where to find it: Azure portal: Subscriptions; or az account list --query "[].id" -o tsv.

Setup#

These are the steps for the default answers. In the app, they follow your answers, and the connector's ingest key replaces YOUR_INGEST_KEY.

Step 1. Create the read-only role. With the Azure CLI signed in as someone who can create roles (Owner or User Access Administrator). The role only reads: WAF policies, gateways, their diagnostic settings, resource groups and deployments. It has no write action, so Logthread cannot change your WAF.

cat > logthread-waf-reader.json <<'JSON'
{
  "Name": "Logthread WAF reader",
  "IsCustom": true,
  "Description": "Reads Application Gateway and Front Door WAF policies, gateways and their diagnostic settings. No write.",
  "Actions": [
    "Microsoft.Network/ApplicationGatewayWebApplicationFirewallPolicies/read",
    "Microsoft.Network/applicationGateways/read",
    "Microsoft.Network/frontDoorWebApplicationFirewallPolicies/read",
    "Microsoft.Cdn/profiles/read",
    "Microsoft.Cdn/profiles/securityPolicies/read",
    "Microsoft.Insights/diagnosticSettings/read",
    "Microsoft.Insights/eventtypes/values/read",
    "Microsoft.Resources/subscriptions/resourceGroups/read",
    "Microsoft.Resources/deployments/read",
    "Microsoft.ResourceGraph/resources/read"
  ],
  "NotActions": [],
  "AssignableScopes": [
    "/subscriptions/00000000-0000-0000-0000-000000000000"
  ]
}
JSON
az role definition create --role-definition @logthread-waf-reader.json

Step 2. Assign it to the app. On each subscription you listed. With many subscriptions, assign it once at a management group instead (and use that scope in AssignableScopes). Role assignments can take a few minutes to apply.

az role assignment create --assignee 11111111-1111-1111-1111-111111111111 --role "Logthread WAF reader" --scope /subscriptions/00000000-0000-0000-0000-000000000000

Step 3. Check access. Choose Test connection on this page. Logthread signs in as the app and lists your gateways and WAF policies once, now. A missing permission is named, with the role change that fixes it.

Step 4. Send the WAF log, with the parser first. Coverage and the rule analysis read ApplicationGatewayFirewallLog and ApplicationGatewayAccessLog from your Azure integration (Event Hub). Turn on its parser ("Use parser: Azure role assignments and Key Vault", which also reads WAF logs) before the logs arrive: it drops the matched values Azure logs (details.data) and every query string, and keeps only the variable's name and the value's shape.

Check that it works#

The connection page under Integrations counts what has arrived and turns Active with the first record. In Explore, search service:azure.

Security detections#

Turn them on under Security → SIEM (Turn on recommended offers the ones whose data arrives). Each opens one incident per user, address or resource it groups by, and Use opens its query in the rule editor.

DetectionSeverityFires on
Surge in WAF blockscriticalMore than 100 requests blocked on one server in 10 minutes: an attack in progress, or a rule that started blocking real users. This is a fixed limit, not a learned baseline; set it above your normal level when you turn it on.
WAF policy switched to Detection or disabledcriticalAn Azure Application Gateway WAF policy stopped blocking: someone switched it from Prevention to Detection mode, or disabled it, outside Logthread. Requests its rules match now reach your application. Logthread's 15-minute read of the policy found the change; the Azure activity log (operation ApplicationGatewayWebApplicationFirewallPolicies/write) shows who made it, and the policy history on the WAF page shows the diff.

Price#

The integration itself has no charge. What it sends is billed as data ingested, ₹85 ($0.90) per GB on every plan, like any other data; parsing, detections and the dashboard add nothing. See Prices.

Set it up under Integrations in the app, or from an AI agent with MCP (add_integration). All integrations: Integrations guide. Next: find what it sends in Explore and live tail.