Skip to content

fix(policy): add Deny to managedDiskPublicNetworkAccess (#4204) - #2178

Open
Git-PrinceNagar wants to merge 1 commit into
Azure:mainfrom
Git-PrinceNagar:fix/4204-managed-disk-deny
Open

fix(policy): add Deny to managedDiskPublicNetworkAccess (#4204)#2178
Git-PrinceNagar wants to merge 1 commit into
Azure:mainfrom
Git-PrinceNagar:fix/4204-managed-disk-deny

Conversation

@Git-PrinceNagar

@Git-PrinceNagar Git-PrinceNagar commented Jul 27, 2026

Copy link
Copy Markdown

Overview/Summary

The Deny-PublicPaaSEndpoints initiative's managedDiskPublicNetworkAccess parameter only exposes Audit and Disabled, while the built-in policy it maps to — 8405fdab-1faf-48aa-b702-999c9c172094 ("Managed disks should disable public network access") — also supports Deny. As a result, customers cannot enforce (deny) public network access on managed disks via this initiative.

This PR aligns the parameter with the built-in policy by adding the missing Deny value.

Fixes Azure/Azure-Landing-Zones#4204

This PR fixes/adds/changes/removes

  1. Adds Deny to managedDiskPublicNetworkAccess.allowedValues (now Audit, Deny, Disabled); default remains Audit.
  2. Bumps the initiative metadata.version from 5.2.0 to 5.3.0.
  3. Regenerates the compiled eslzArm/managementGroupTemplates/policyDefinitions/initiatives.json via bicep build.

Breaking Changes

None. The change is additive and the default (Audit) is unchanged, so existing assignments behave exactly as before — Deny is simply now selectable.

Testing Evidence

Confirmed the built-in policy supports Deny across three independent sources:

Source Allowed values
az policy definition show 8405fdab-... (live Azure) Audit, Deny, Disabled
AzAdvertizer (public reference) Audit, Deny, Disabled
Sibling param containerAppsPublicNetworkAccess (same file) Audit, Deny, Disabled

Local validation after the fix:

  • Test-BuildPolicies.Tests.ps1 (build-sync gate): 3 passed / 0 failed — committed initiatives.json matches a fresh bicep build.
  • Test-ModifiedPolicies.Tests.ps1 content assertions on the modified file (version bumped, category, source, cloud environments, name/filename match, parameter default): all pass.

As part of this Pull Request I have

  • Checked for duplicate Pull Requests
  • Associated it with relevant issues, for tracking and closure
  • Ensured my code/branch is up-to-date with the latest changes in the main branch
  • Performed testing and provided evidence
  • Ensured contribution guidance is followed
  • Updated relevant and associated documentation
  • Created a pull request to update the "What's New?" wiki page

…cPaaSEndpoints (#4204)

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@Git-PrinceNagar

Copy link
Copy Markdown
Author

@microsoft-github-policy-service agree company="Microsoft"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]:

1 participant