Azure Policy
Microsoft's native governance service for evaluating and enforcing rules against Azure resource configurations, at the management-group, subscription, or resource-group level.
How Azure Policy works
Azure Policy attaches policy definitions – written in JSON – to a scope, so resources created or updated in that scope are evaluated against a rule. Definitions describe the conditions to match and the effect to apply; initiatives group related definitions together.
Because it is built into Azure, there are no agents to install. Resource create and update requests are evaluated through the Azure Resource Manager request pipeline, while compliance evaluations also identify existing resources that do not meet the assigned rules.

- Define the rule. Choose a built-in definition or write a custom policy.
- Assign the scope. Apply it to the management group, subscription or resource group.
- Evaluate the resource. Azure applies the configured effect to matching resources and requests.
Audit, Deny and other policy effects
Not every Azure Policy effect blocks a change. The effect determines whether a rule only reports a violation, prevents a request, adjusts supported properties or deploys missing configuration.
Audit
Records non-compliance without blocking the request. Use it to understand where resources fall outside a policy before deciding what to enforce.
Deny
Blocks a matching non-compliant create or update request before the requested configuration takes effect. It does not automatically repair resources that already exist.
Modify
Adds, removes or updates supported properties or tags on a request. Existing non-compliant resources need a remediation task and an appropriately permitted managed identity.
DeployIfNotExists
Deploys missing related configuration when its conditions are met after a resource is created or updated. Existing resources require a remediation task and the necessary managed-identity permissions.
Existing resources need a remediation plan. A compliance scan does not itself fix a resource. Modify and DeployIfNotExists can remediate existing resources through appropriate remediation tasks with the required permissions. Audit and Deny do not automatically correct existing configuration.
Enforcement and scopes
Assign policies at the management-group, subscription or resource-group level to apply rules at the right boundary. Higher-level assignments apply to resources within that scope, including its child scopes. Use deliberate exclusions or tracked exemptions where a legitimate need conflicts with a rule.

Enforcement is more than assigning a definition. The selected effect, the assignment's enforcement setting and any exemptions determine what happens. Start by assessing violations and legitimate deployment activity, tune the scope, and test before enabling a blocking effect in production.
Explore granular policy scoping
Example: prevent public blob access
A team requires its production storage accounts to disallow public blob access. It assigns a policy with a Deny effect to its production subscription and enables enforcement.

In Audit mode, the same request would be allowed and the violation reported. A Deny assignment does not make existing storage accounts private: identify non-compliant resources and remediate them separately.
From audit to preventive security
Azure Policy's Deny effect evaluates a change at the Azure control plane before the requested configuration takes effect. That makes it a native building block for preventive cloud security: the same rule can apply regardless of whether a change originates from IaC, the console, the CLI or an AI agent.
A poorly tested policy can also block a legitimate deployment. Aryon adds impact assessment, granular scoping and exception management so teams can understand a policy's effect, tune it and move from Audit to enforcement with confidence. This complements CSPM's visibility into deployed resources and IaC scanning earlier in development; it does not replace them.