Networking

Azure DDoS Protection: qualify an attack before blocking source IPs

A production runbook for correlating Azure DDoS Protection metrics, mitigation logs and application impact before adding source-IP blocks, with validation and rollback.

19 Oct 2026 azureddos-protectionnetworkingsecurityazure-monitorkqlobservabilityincidentrunbookrollbackproduction

Azure DDoS Protection reports that a public IP is under attack while users see latency and intermittent timeouts. The first proposed action is often to block the most visible source addresses at the WAF, firewall or NSG. That can consume the incident window without reducing a distributed attack, and it can block legitimate clients hidden behind shared addresses.

The running case is an internet-facing service behind an Azure public IP protected by DDoS Network Protection or DDoS IP Protection. The goal is to establish whether mitigation is active, what traffic is still forwarded, where user impact begins, and whether any bounded application-layer control is justified. The decision at the end is explicit: observe, escalate, apply a narrow control, or remove the candidate change.

Freeze the public path and the incident window

Start with one protected public IP and one UTC interval. Do not investigate from a hostname alone: DNS, Front Door, a load balancer and a firewall can place different public IPs on the path.

yaml 01-ddos-incident-contract.yml
incident: INC-NET-842
window_utc:
start: 2026-10-19T14:05:00Z
end: open
public_ip_resource_id: /subscriptions/<sub>/resourceGroups/rg-edge-prod/providers/Microsoft.Network/publicIPAddresses/pip-api-prod
public_fqdn: api.example.net
protected_by: <network-protection-or-ip-protection>
application_path: Front Door-or-Public-IP -> firewall-or-load-balancer -> api
known_good:
request_rate: <baseline>
p95_latency_ms: <baseline>
error_rate: <baseline>
owners:
network: <on-call>
application: <on-call>
stop_owner: <incident-commander>

Capture the public IP resource ID, protection state, routing path, current deployment versions and diagnostic setting before changing any rule. Keep synthetic probes running from at least one trusted external location and one internal observation point if the architecture provides it.

Prove mitigation from the protected IP

The primary signal is the public IP metric IfUnderDDoSAttack, aggregated with Maximum. Pair it with packets received, dropped and forwarded. A large dropped volume proves that scrubbing is active; it does not prove that the application is unavailable. Forwarded traffic and application health decide that.

bash 02-ddos-metrics.sh
set -euo pipefail

PIP_ID="/subscriptions/<sub>/resourceGroups/rg-edge-prod/providers/Microsoft.Network/publicIPAddresses/pip-api-prod"
START="2026-10-19T14:00:00Z"
END="2026-10-19T15:00:00Z"

az monitor metrics list-definitions --resource "$PIP_ID" -o table

az monitor metrics list --resource "$PIP_ID" --metric IfUnderDDoSAttack PacketsInDDoS PacketsDroppedDDoS PacketsForwardedDDoS --aggregation Maximum --interval PT1M --start-time "$START" --end-time "$END" -o json > ddos-attack-metrics.json

az monitor metrics list --resource "$PIP_ID" --metric VipAvailability --aggregation Average --interval PT1M --start-time "$START" --end-time "$END" -o json > ddos-data-path-availability.json

Use the aggregation supported by each metric when building the permanent workbook or alert. During the incident, preserve the raw response and note gaps explicitly. Most detailed attack telemetry appears only after mitigation starts; absence before that point is not proof that no hostile traffic exists.

Read notifications, flow logs and reports separately

Azure DDoS Protection exposes three different evidence types in AzureDiagnostics: notifications delimit mitigation, flow logs show forwarded and dropped flows during mitigation, and reports summarize attack vectors and traffic. They answer different questions and should not be collapsed into one count.

kusto 03-ddos-timeline.kql
let IncidentStart = datetime(2026-10-19T14:05:00Z);
let IncidentEnd = now();
AzureDiagnostics
| where TimeGenerated between (IncidentStart .. IncidentEnd)
| where ResourceType == "PUBLICIPADDRESS"
| where Category in (
  "DDoSProtectionNotifications",
  "DDoSMitigationFlowLogs",
  "DDoSMitigationReports"
)
| project TimeGenerated,
        Resource,
        Category,
        OperationName,
        EventType=tostring(column_ifexists("Type_s", "")),
        SourceIP=tostring(column_ifexists("SourcePublicIpAddress_s", "")),
        DestinationPort=tostring(column_ifexists("DestPort_d", "")),
        Protocol=tostring(column_ifexists("Protocol_s", "")),
        Message=tostring(column_ifexists("Message", ""))
| order by TimeGenerated asc

First confirm that diagnostic settings on the public IP were already routing all three categories to the intended workspace or event stream. Enabling logs during an attack improves evidence from that point forward; it does not recreate events that were never exported.

Mitigation reports are incremental during a long attack and completed after mitigation. Treat the post-mitigation report as the final summary, not as the only source for a live decision.

Correlate network evidence with application impact

Do not equate MitigationStarted with an outage. Align five timelines at one-minute resolution:

  • mitigation state;
  • packets received, dropped and forwarded;
  • public-IP data-path availability;
  • edge, firewall or load-balancer health;
  • application requests, latency, saturation and dependency errors.
text 04-impact-matrix.txt
MITIGATION ACTIVE + APPLICATION HEALTHY
Keep scrubbing active
Preserve evidence
Do not add source-IP blocks

MITIGATION ACTIVE + FORWARDED TRAFFIC HIGH + APPLICATION DEGRADED
Identify protocol, destination port and application endpoint
Check compute, connection, queue and dependency saturation
Consider a bounded L7 control only with positive evidence

NO MITIGATION + APPLICATION DEGRADED
Validate the actual public IP and protection state
Separate deployment, dependency, routing and capacity failures
Escalate if traffic approaches the learned trigger

MITIGATION STOPPED + APPLICATION STILL DEGRADED
Investigate residual saturation, exhausted pools and unhealthy instances
Do not leave emergency blocks in place without a current signal

For an HTTP service, compare synthetic success, status codes and latency with backend health and resource saturation. A DDoS event can coexist with an unrelated release regression. The shared timestamp is not causality until the failure boundary matches the traffic that was forwarded.

Resist source-IP blocking without a stable predicate

Top source addresses are evidence, not automatically a block list. Distributed traffic rotates, legitimate users share carrier or enterprise egress, and a network-layer block may duplicate traffic already dropped by the DDoS service.

A source rule is defensible only when the predicate remains narrow and testable: one protocol or application route, a clearly abusive behavior, no trusted cohort overlap, a short expiry and an owner. Prefer an application-layer rate limit, request validation or WAF rule when the harmful behavior is visible at L7. Keep volumetric mitigation at the DDoS layer.

yaml 05-bounded-control.yml
candidate_control:
layer: <waf-or-firewall>
predicate:
  host: api.example.net
  path: /v1/search
  method: POST
  behavior: exceeds-approved-rate
exclude:
  - health-probes
  - partner-egress
  - corporate-egress
mode: detection-or-log
canary_scope: <one-endpoint-or-ring>
expires_utc: 2026-10-19T16:30:00Z
success:
  - abusive_requests_decrease
  - legitimate_success_rate_stable
  - backend_saturation_recovers
rollback:
  owner: <network-on-call>
  action: remove-candidate-rule

Never paste thousands of flow-log source addresses into a long-lived rule. If the evidence is only network volume and Azure is already dropping it, an additional application control has no proven job.

Canary, validate and keep an expiry

Deploy the candidate in detection or logging mode when the control plane supports it. Compare matched requests with known clients, probes and partner ranges. Activate only the narrowest scope, then watch both negative and positive controls: the abusive behavior must fall, while a legitimate transaction still completes through the full path.

Stop and roll back when the rule catches trusted traffic, shifts failures to another endpoint, leaves saturation unchanged, or depends on a source list that changes faster than the rule can be reviewed. Emergency controls need an expiry even if the attack is still being investigated; extension should be a new decision with fresh evidence.

Close the incident with a production decision

text 06-ddos-decision-gate.txt
OBSERVE
Mitigation is active and the application remains within its service objectives
Dropped and forwarded traffic are recorded
No additional control has a proven benefit

ESCALATE
The protected public IP is confirmed
Impact continues while mitigation or data-path availability is abnormal
Metrics, logs and application evidence are packaged on one UTC timeline

PROMOTE A BOUNDED CONTROL
Harmful forwarded behavior is proven at the chosen layer
Detection-mode matches exclude trusted cohorts
Canary improves application health without collateral failures
Owner and automatic expiry are recorded

ROLL BACK
Legitimate traffic is affected
Application health does not improve
The attack vector or source set has changed
Azure mitigation has stopped and the rule has no remaining predicate

After mitigation ends, retain the post-mitigation report, metric export, application timeline and every temporary-rule decision. Verify that IfUnderDDoSAttack returns to zero, synthetic and real-user signals recover, backend saturation clears, and temporary rules are removed or promoted through normal change control.

Conclusion

A DDoS notification is not a request to build an IP deny list. It is the start of a correlation exercise across the protected public IP, Azure mitigation, forwarded traffic and the application boundary.

The production-safe decision is to let Azure handle proven volumetric traffic, escalate with a complete timeline when mitigation is insufficient, and add an application control only for a narrow behavior that survives a canary. Anything broader should expire and roll back before it becomes invisible permanent policy.