Skip to content

fix: Infra reliability & security improvements — reduce quota demand, add Bicep guard, remove hardcoded VM credentials#901

Open
Roopan-Microsoft wants to merge 2 commits intodev-v4from
fix/infra-reliability-security-v4
Open

fix: Infra reliability & security improvements — reduce quota demand, add Bicep guard, remove hardcoded VM credentials#901
Roopan-Microsoft wants to merge 2 commits intodev-v4from
fix/infra-reliability-security-v4

Conversation

@Roopan-Microsoft
Copy link
Copy Markdown
Collaborator

Summary

Addresses 3 high-impact findings from MACAE error analysis (telemetry: 2025-12-01 to 2026-04-06). Template has 30.3% success rate (2,247 failures / 3,228 provisions).

Replaces closed PR #900 (was targeting \dev, now re-targeted to \dev-v4).


Changes

1. Reduce default model capacities (addresses 20.2% of failures)

Error: \InsufficientQuota\ + \SubscriptionIsOverQuotaForSku\ — 453 occurrences, 84 machines

  • \gpt4_1ModelCapacity: 150 -> 80
  • \gptModelCapacity: 50 -> 30
  • \gptReasoningModelCapacity: 50 -> 30
  • Total TPM: 250 -> 140 (44% reduction)
  • Added @minValue(1)\ constraints

2. Add Bicep version guard (addresses 45.8% of failures)

Error: \InvalidTemplate\ + \ ool.bicep.failed\ — 1,030 occurrences, 131+ machines

  • Added \�icep: '>= 0.33.0'\ to
    equiredVersions\ in \�zure.yaml\

3. Remove hardcoded VM credentials (SECURITY)

Issue: OWASP A07:2021 — hardcoded password visible in public repo

  • Removed \JumpboxAdminUser\ / \JumpboxAdminP@ssw0rd1234!\ fallbacks
  • VM credentials now required when \�nablePrivateNetworking = true\

Files Changed

File Changes
\infra/main.bicep\ Reduced capacities, removed hardcoded creds, improved param descriptions
\�zure.yaml\ Added Bicep version requirement

Impact

  • Projected success rate: 30.3% -> ~55-60%
  • Security fix: 1 critical vulnerability removed
  • Zero breaking changes for non-WAF deployments

…ardcoded VM credentials

- Reduce model capacities: gpt4_1 150->80, gptModel 50->30, reasoning 50->30 (total 250->140 TPM)
- Add bicep >= 0.33.0 to requiredVersions in azure.yaml
- Remove hardcoded VM password fallback (OWASP A07:2021)
- Add @minValue(1) constraints to capacity parameters
- Improve VM credential parameter descriptions
- PR #3: Add enablePurgeProtection: false to Key Vault (fixes FlagMustBeSetForRestore - 68 occurrences, 21 machines)
- PR #4: Separate model deployments from AI Services account creation with @batchsize(1) via ai-services-deployments.bicep (fixes ETag conflicts - 152 occurrences, 27+ machines)
- PR #6: Restrict AI service regions to eastus2, swedencentral, westus and update usageName to match reduced capacities (fixes InvalidResourceLocation - 61 occurrences, 12 machines)
- PR #7: Re-enable Search Service private endpoints and publicNetworkAccess toggle for WAF deployments (closes security gap)
- PR #8: Enable MCP Server authentication by default (ENABLE_AUTH: true)
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.

1 participant