Generated banner for Azure Compliance
Generated logo for Azure Compliance

Azure Compliance

MicrosoftOfficialCreated by Microsoft

  • Skill
  • Tool integration
  • Security
  • MIT
  • Low risk

From the author

Run Azure compliance and security audits with azqr plus Key Vault expiration checks. Covers best-practice assessment, resource review, policy/compliance validation, and security posture checks. WHEN: compliance scan, security audit, BEFORE running azqr (compliance cli tool), Azure best practices, Key Vault expiration check, expired certificates, expiring secrets, orphaned resources, compliance assessment.
— the description by Microsoft

AutoGineer summary

Written by AutoGineer from the skill’s own files, not by the author

The azure-compliance skill provides a structured approach to auditing Azure environments for security, reliability, and operational best practices. It leverages the azqr tool for comprehensive resource assessments and includes specific capabilities for monitoring Key Vault assets, such as secrets, keys, and certificates, for expiration. The skill guides users through selecting a scope, running scans, analyzing results, and prioritizing remediation based on severity levels.

What it does

  • Executes compliance scans using the azqr tool.
  • Monitors Azure Key Vault for expiring secrets, keys, and certificates.
  • Lists subscriptions and resource groups for targeted auditing.
  • Provides a framework for classifying findings by priority (Critical to Low).
  • Offers guidance on interpreting scan results and remediation patterns.
  • Supports programmatic access to Key Vault via various SDKs.

When to use it

  • During scheduled security and compliance audits.
  • When identifying orphaned or unused Azure resources.
  • Before performing major infrastructure changes or migrations.
  • To proactively check for expiring certificates or secrets in Key Vault.
  • When validating adherence to Azure best practices.

Advantages

  • Automates the collection of compliance and security data.
  • Standardizes the assessment process across different Azure environments.
  • Helps reduce risk by identifying expiring credentials early.
  • Provides clear prioritization logic for remediation efforts.
  • Integrates multiple assessment sources into a single workflow.

Usage examples

“Run a compliance scan on my production subscription.”
The agent will list available subscriptions, execute the azqr scan on the selected scope, and provide a summary of findings categorized by reliability, security, and cost.
“Check for any expiring secrets in my Key Vault.”
The agent will inspect the specified Key Vault, retrieve expiration dates for all secrets, and report any that are nearing their expiration date.

Install

  1. Download the skill as a ZIP:

    https://autogineer.com/agent-skills/microsoft/azure-compliance/download
  2. Unzip it into the cross-client skills folder of your project:

    mkdir -p .agents/skills && unzip azure-compliance.zip -d .agents/skills

Documentation by Microsoft

Azure Compliance & Security Auditing

Quick Reference

PropertyDetails
Best forCompliance scans, security audits, Key Vault expiration checks
Primary capabilitiesComprehensive Resources Assessment, Key Vault Expiration Monitoring
MCP toolsazqr, subscription and resource group listing, Key Vault item inspection

Prerequisites

  • Authentication: user is logged in to Azure via az login

  • Permissions to read resource configuration and Key Vault metadata

Assessments

AssessmentReference
Comprehensive Compliance (azqr)references/azure-quick-review.md
Key Vault Expirationreferences/azure-keyvault-expiration-audit.md
Resource Graph Queriesreferences/azure-resource-graph.md

MCP Tools

ToolPurpose
mcp_azure_mcp_extension_azqrRun azqr compliance scans
mcp_azure_mcp_subscription_listList available subscriptions
mcp_azure_mcp_group_listList resource groups
keyvault_key_listList all keys in vault
keyvault_key_getGet key details including expiration
keyvault_secret_listList all secrets in vault
keyvault_secret_getGet secret details including expiration
keyvault_certificate_listList all certificates in vault
keyvault_certificate_getGet certificate details including expiration

Assessment Workflow

  1. Select scope (subscription or resource group) for Comprehensive Resources Assessment.

  2. Run azqr and capture output artifacts.

  3. Analyze Scan Results and summarize findings and recommendations.

  4. Review Key Vault Expiration Monitoring output for keys, secrets, and certificates.

  5. Classify issues and propose remediation or fix steps for each finding.

Priority Classification
PriorityGuidance
CriticalImmediate remediation required for high-impact exposure
HighResolve within days to reduce risk
MediumPlan a resolution in the next sprint
LowTrack and fix during regular maintenance

Error Handling

ErrorMessageRemediation
Authentication required"Please login"Run az login and retry
Access denied"Forbidden"Confirm permissions and fix role assignments
Missing resource"Not found"Verify subscription and resource group selection

Best Practices

  • Run compliance scans on a regular schedule (weekly or monthly)

  • Track findings over time and verify remediation effectiveness

  • Separate compliance reporting from remediation execution

  • Keep Key Vault expiration policies documented and enforced

SDK Quick References

For programmatic Key Vault access, see the condensed SDK guides:

Files

references/azure-keyvault-expiration-audit.md

Key Vault Expiration Audit & Compliance

Automated auditing of Azure Key Vault resources to identify expired or expiring keys, secrets, and certificates before they cause service disruptions.

Overview

This skill monitors Azure Key Vault resources (keys, secrets, certificates) for expiration issues. It helps prevent service disruptions by identifying:

  • Expired resources causing active problems

  • Expiring soon (within customizable days threshold)

  • Missing expiration dates (security risk)

  • Disabled resources needing cleanup

Core Workflow

  1. List Resources: Enumerate keys, secrets, and certificates in target vault(s)

  2. Get Details: Retrieve expiration metadata for each resource

  3. Analyze Status: Compare expiration dates against current date and threshold

  4. Generate Report: Organize findings by priority with actionable recommendations

Audit Patterns

Pattern 1: Single Vault Quick Scan

Check one Key Vault for all expiration issues with configurable day threshold (default: 30 days).

Tools: keyvault_key_list, keyvault_key_get, keyvault_secret_list, keyvault_secret_get, keyvault_certificate_list, keyvault_certificate_get

Pattern 2: Multi-Vault Compliance Report

Scan multiple vaults across subscription for comprehensive security review.

Use for: Quarterly audits, organization-wide compliance checks

Pattern 3: Resource Type Focus

Audit only keys, secrets, OR certificates when specific resource type is mentioned.

Use for: Certificate renewal planning, secret rotation tracking

Pattern 4: Emergency Expired Finder

Quick scan for already-expired resources (negative days) to troubleshoot active incidents.

Use for: Production issues, authentication failures

Key Data Fields

When retrieving resource details, analyze these fields:

  • expiresOn: Expiration timestamp (null = no expiration set - security risk!)

  • enabled: Resource is active (false = disabled/inactive)

  • notBefore: When resource becomes valid

  • createdOn/updatedOn: For tracking resource age and last rotation

  • subject/issuer: Certificate-specific metadata

Report Format

Organize findings into:

  • Summary Statistics: Total count, expired count, expiring count, no-expiration count per resource type

  • Critical Issues: Expired resources requiring immediate action

  • Warnings: Expiring within threshold (e.g., 30 days)

  • Risks: Resources without expiration dates

  • Recommendations: Set expiration policies, rotate credentials, remove disabled items

Remediation Priority

🔴 Critical - Expired (< 0 days): Rotate immediately
🟠 High - Expiring 0-7 days: Schedule rotation within 24 hours
🟡 Medium - Expiring 8-30 days: Plan rotation within 1 week
🟡 Medium - No expiration set: Apply expiration policy
🟢 Low - Active (> 30 days): Monitor on regular schedule

Best Practices

  • Run weekly audits to catch issues early

  • All resources should have expiration dates (Azure Policy recommendation)

  • Configure Azure Event Grid for 30-day advance notifications

  • Rotation schedule: Secrets every 60-90 days, Keys annually, Certificates per CA requirements (max 1 year)

  • Prioritize production Key Vaults over dev/test

  • Automate rotation with Azure Functions or Logic Apps

MCP Tools Used

ToolPurpose
keyvault_key_listList all keys in a vault
keyvault_key_getGet key details including expiration
keyvault_secret_listList all secrets in a vault
keyvault_secret_getGet secret details including expiration
keyvault_certificate_listList all certificates in a vault
keyvault_certificate_getGet certificate details including expiration

Required: vault (Key Vault name)
Optional: subscription, tenant

Fallback Strategy: Azure CLI Commands

If Azure MCP Key Vault tools fail, timeout, or are unavailable, use Azure CLI commands as fallback.

CLI Command Reference
OperationAzure CLI Command
List secretsaz keyvault secret list --vault-name <vault-name>
Get secret detailsaz keyvault secret show --vault-name <vault-name> --name <secret-name>
List keysaz keyvault key list --vault-name <vault-name>
Get key detailsaz keyvault key show --vault-name <vault-name> --name <key-name>
List certificatesaz keyvault certificate list --vault-name <vault-name>
Get certificate detailsaz keyvault certificate show --vault-name <vault-name> --name <cert-name>
When to Fallback

Switch to Azure CLI when:

  • MCP tool returns timeout error

  • MCP tool returns "service unavailable" or connection errors

  • MCP tool takes longer than 30 seconds to respond

  • Empty response when vault is known to have resources

Common Issues

  • Access Denied: Verify RBAC permissions (Key Vault Reader + data plane access)

  • Vault Not Found: Check vault name and subscription context

  • Null expiresOn: Resource has no expiration (security risk - requires policy)

  • Time zones: All timestamps are UTC

Requirements and compatibility

Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta

“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.

Security

What our scanner noticed· Low risk

  • Instructions that use the network

A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.

Attribution and licence

Created by
Microsoft
Publisher
Microsoft (Official)
Source
microsoft/skills · .github/plugins/azure-skills/skills/azure-compliance · commit 0696600
Licence
MIT License (redistribution allowed)
  • LICENSE (added by AutoGineer from .github/plugins/azure-skills/LICENSE)
  • ATTRIBUTION.md (written by AutoGineer)
Synced
Also distributed in
microsoft/azure-skills

AutoGineer is not affiliated with or endorsed by Microsoft or Microsoft.

Download ZIP

The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download azure-compliance.zip