Skip to content
Report library
Purpose / Other

Azure Resource Lookup Skill Security Audit

What the author says it does (original text)

List, find, and show Azure resources across subscriptions or resource groups. Handles prompts like \"list the websites in my subscription\", \"list my web apps\", \"show my app services\", \"list virtual machines\", \"list my VMs\", \"show storage accounts\", \"find container apps\", and \"what resources do I have\". USE FOR: list websites, list web apps, list app services, show websites in subscr

Independent security check

Security risks found

Files checked
2
Risks found
4
Could it run dangerous commands?Looks for programs run straight after downloading, remote control of your computer, and hidden commands.Risks found: 2
Medium risk

The agent is told to run a CLI command generated from user-supplied intent

Source references: 2
What we found

The workflow places the user's request in the `extension_cli_generate` intent and then broadly says to run the generated command. It does not require validation that the result is exactly one read-only `az graph query`, or reject shell metacharacters and appended commands.

Why this matters

If the generator misinterprets or is manipulated by a crafted request into returning additional shell content, the agent could perform actions beyond resource lookup with the local Azure CLI session's permissions. The provided text does not show that this has occurred.

The workflow puts the user's request into a command-generation tool and then instructs the agent to run the generated command. The visible instructions do not require checking that the output is only the intended read-only `az graph query`. If extra shell content were generated, it could affect the user's machine or current Azure identity. Users can ask for command-structure validation, argument escaping, and confirmation before execution.

SKILL.md:73In the instructionsOpen original file
Use `extension_cli_generate` to build the `az graph query` command:```yamlmcp_azure_mcp_extension_cli_generate  intent: "query Azure Resource Graph to <user's request>"  cli-type: "az"```
Show 1 other places
SKILL.md:83In the instructionsOpen original file
### Step 3: Execute and Format ResultsRun the generated command. Use `--query` (JMESPath) to shape output:```bashaz graph query -q "<KQL>" --query "data[].{name:name, type:type, rg:resourceGroup}" -o table```
Low risk

Error handling installs an Azure CLI extension when it is missing

Source references: 3
What we found

Although the cloud-resource operations are described as read-only, error handling recommends `az extension add --name resource-graph`. Extension installation downloads executable code and persistently changes the local Azure CLI environment.

Why this matters

Installation expands the local software supply chain and future CLI execution surface. It may also conflict with policies that require pinned versions or prohibit dynamic package installation.

Error handling explicitly provides a command to install the Azure CLI `resource-graph` extension. If the agent applies that fix, it downloads code and persistently changes the local CLI environment, unlike the read-only cloud query itself. The visible instructions do not require installation approval or a pinned, verified extension version. Users can require confirmation and a controlled version or isolated environment.

SKILL.md:35In the instructionsOpen original file
|----------|-------|| **Query Language** | KQL (Kusto Query Language subset) || **CLI Command** | `az graph query -q "<KQL>" -o table` || **Extension** | `az extension add --name resource-graph` || **MCP Tool** | `extension_cli_generate` with intent for `az graph query` || **Best For** | Cross-subscription queries, orphaned resources, tag audits |
Show 2 other places
SKILL.md:95In the instructionsOpen original file
| Error | Cause | Fix ||-------|-------|-----|| `resource-graph extension not found` | Extension not installed | `az extension add --name resource-graph` || `AuthorizationFailed` | No read access to subscription | Check RBAC — need Reader role || `BadRequest` on query | Invalid KQL syntax | Verify table/column names; use `=~` for case-insensitive type matching |
SKILL.md:97In the instructionsOpen original file
|-------|-------|-----|| `resource-graph extension not found` | Extension not installed | `az extension add --name resource-graph` || `AuthorizationFailed` | No read access to subscription | Check RBAC — need Reader role |
Could it expose your files or keys?Looks for uploads of files containing passwords or keys, and keys written directly in the code.Risks found: 1
Low risk

Broad requests can bring multi-subscription infrastructure metadata into agent results

Source references: 7
What we found

The Skill supports cross-subscription inventories, tag audits, public-network checks, and authorization-resource queries. These can reveal internal names, deployment locations, topology, tags, and permission structure.

Why this matters

In a shared session, an overly broad query, or when results are forwarded, the output may disclose cloud-environment details beyond the task's need. No automatic transmission to a third party is shown in the source.

Legitimate use of this code

These queries can read infrastructure metadata across subscriptions, including tags and health state, but that is the Skill's expressly stated inventory and discovery function rather than covert collection. Execution still depends on a user query and the current Azure identity having read access; the instructions also require subscription or result limits for large tenants. In sensitive environments, users can restrict subscriptions, returned fields, and where output is shown.

This assessment concerns the code and conditions shown, not proof that harm has occurred.
SKILL.md:17In the instructionsOpen original file
Use this skill when the user wants to:- **List resources** of any type (VMs, web apps, storage accounts, container apps, databases, etc.)- **Show resources** in a specific subscription or resource group- Query resources **across multiple subscriptions** or resource types- Find **orphaned resources** (unattached disks, unused NICs, idle IPs)- Discover resources **missing required tags** or configurations- Get a **resource inventory** spanning multiple types- Find resources in a **specific state** (unhealthy, failed provisioning, stopped)- Answer "**what resources do I have?**" or "**show me my Azure resources**"- **List web apps, websites, or App Services**
Show 6 other places
references/azure-resource-graph.md:23In the instructionsOpen original file
|-------|----------|| `Resources` | All ARM resources — name, type, location, properties, tags, sku || `ResourceContainers` | Subscriptions, resource groups, management groups || `HealthResources` | Resource health availability status || `ServiceHealthResources` | Azure service health events/incidents || `AuthorizationResources` | Role assignments and definitions || `AdvisorResources` | Azure Advisor recommendations |
references/azure-resource-graph.md:107In the instructionsOpen original file
**Resources missing a required tag:**```kqlResources| where isnull(tags['Environment']) or isnull(tags['CostCenter'])| project name, type, resourceGroup, tags```
references/azure-resource-graph.md:123In the instructionsOpen original file
**Resources with public network access:**```kqlResources| where properties.publicNetworkAccess =~ 'Enabled'| project name, type, resourceGroup, location```
SKILL.md:98In the instructionsOpen original file
| `resource-graph extension not found` | Extension not installed | `az extension add --name resource-graph` || `AuthorizationFailed` | No read access to subscription | Check RBAC — need Reader role || `BadRequest` on query | Invalid KQL syntax | Verify table/column names; use `=~` for case-insensitive type matching |
SKILL.md:105In the instructionsOpen original file
- ✅ **Always** use `=~` for case-insensitive type matching (types are lowercase)- ✅ **Always** scope queries with `--subscriptions` or `--first` for large tenants- ✅ **Prefer** dedicated MCP tools for single-resource-type queries
SKILL.md:108In the instructionsOpen original file
- ❌ **Never** use ARG for real-time monitoring (data has slight delay)- ❌ **Never** attempt mutations through ARG (read-only)
Could it delete files or keep running?Looks for broad file deletion, disk overwrites, and programs set to start automatically.No risks found
Could it bypass safety checks?Looks for skipped website security checks, excessive file access, or actions that skip your approval.No risks found
Could it mislead the AI or hide text?Checks the skill instructions for requests to ignore you, influence the report, or hide text in invisible characters.No risks found
Could it change links or payment recipients without asking?Looks for forced referral or payment changes combined with instructions to hide the change.Risks found: 1
Low risk

The reference includes a cost-recommendation query despite the stated non-cost scope

Source references: 3
What we found

The Skill description explicitly excludes cost optimization, but its bundled reference provides an executable pattern for Azure Advisor cost recommendations. An agent could use that example to expand a resource-lookup task into cost guidance.

Why this matters

If used for a cost question, the user could make a business decision from recommendations that have not passed a dedicated cost-analysis workflow. The query itself remains read-only.

The main description expressly excludes cost optimization, while the directly referenced query guide includes an Azure Advisor cost-recommendation pattern. The snippet is only an example and does not execute itself, but an agent consulting the guide could treat cost recommendations as authorized, causing cost data retrieval or decision-making beyond a resource-inventory request. Users can ask the author to remove it or require separate explicit authorization.

SKILL.md:2In the instructionsOpen original file
---name: azure-resource-lookupdescription: "List, find, and show Azure resources across subscriptions or resource groups. Handles prompts like \"list the websites in my subscription\", \"list my web apps\", \"show my app services\", \"list virtual machines\", \"list my VMs\", \"show storage accounts\", \"find container apps\", and \"what resources do I have\". USE FOR: list websites, list web apps, list app services, show websites in subscription, resource inventory, find resources by tag, tag analysis, orphaned resource discovery (not for cost analysis), unattached disks, count resources by type, cross-subscription lookup, and Azure Resource Graph queries. DO NOT USE FOR: deploying/changing resources (use azure-deploy), cost optimization (use azure-cost), or non-Azure clouds."license: MIT
Show 2 other places
references/azure-resource-graph.md:179In the instructionsOpen original file
**Advisor cost recommendations:**```kqlAdvisorResources| where properties.category == 'Cost'| project name, impact=properties.impact, solution=properties.shortDescription.solution```
SKILL.md:81In the instructionsOpen original file
See [Azure Resource Graph Query Patterns](references/azure-resource-graph.md) for common KQL patterns.

Inside this skill

6 instruction sections

The Skill primarily reads Azure resource metadata: it prefers dedicated MCP tools and otherwise generates and executes Azure Resource Graph queries. It explicitly prohibits changing cloud resources through ARG.

View source
SKILL.md:69In the instructionsOpen original file
If a dedicated tool is available with full coverage, use it. Otherwise proceed to Step 2.### Step 2: Generate the ARG QueryUse `extension_cli_generate` to build the `az graph query` command:
SKILL.md:83In the instructionsOpen original file
### Step 3: Execute and Format ResultsRun the generated command. Use `--query` (JMESPath) to shape output:```bashaz graph query -q "<KQL>" --query "data[].{name:name, type:type, rg:resourceGroup}" -o table```
SKILL.md:107In the instructionsOpen original file
- ✅ **Prefer** dedicated MCP tools for single-resource-type queries- ❌ **Never** use ARG for real-time monitoring (data has slight delay)- ❌ **Never** attempt mutations through ARG (read-only)

Queries may span multiple subscriptions and can read metadata such as resource names, types, locations, tags, health states, and authorization structures. The supplied examples only query and project data; no instruction sends results to an external recipient.

View source
SKILL.md:17In the instructionsOpen original file
Use this skill when the user wants to:- **List resources** of any type (VMs, web apps, storage accounts, container apps, databases, etc.)- **Show resources** in a specific subscription or resource group- Query resources **across multiple subscriptions** or resource types- Find **orphaned resources** (unattached disks, unused NICs, idle IPs)- Discover resources **missing required tags** or configurations- Get a **resource inventory** spanning multiple types- Find resources in a **specific state** (unhealthy, failed provisioning, stopped)- Answer "**what resources do I have?**" or "**show me my Azure resources**"
references/azure-resource-graph.md:23In the instructionsOpen original file
|-------|----------|| `Resources` | All ARM resources — name, type, location, properties, tags, sku || `ResourceContainers` | Subscriptions, resource groups, management groups || `HealthResources` | Resource health availability status || `ServiceHealthResources` | Azure service health events/incidents || `AuthorizationResources` | Role assignments and definitions || `AdvisorResources` | Azure Advisor recommendations |
Start here · InstructionsSKILL.md
azure-resource-lookup
Lines connect the instruction file to its sections, not an observed execution order. Select a section to read the source.

File reference map

References: 1
Files making referencesReferenced content
Lines show actual file references, not execution order. Select a node to highlight its connections and inspect the files and source locations. Dashed lines include files that still need locating.
Files and check records2 files

Coverage and gaps

Content covered in each file

These are the source ranges included in this check, not a guarantee that every issue has been resolved.

  • SKILL.mdFull text included
  • references/azure-resource-graph.mdFull text included

This report is for the version above. We read the available code and instructions without running the skill or checking extra packages it installs. This is not a promise of safety: a different version or setup may behave differently.

  • SKILL.mdInstructions
  • references/azure-resource-graph.mdSupporting file

Operations mentioned in code and instructions

Run commands
SKILL.md:87In the instructionsOpen original file
```bashaz graph query -q "<KQL>" --query "data[].{name:name, type:type, rg:resourceGroup}" -o table
references/azure-resource-graph.md:7In the instructionsOpen original file
```bashaz graph query -q "<KQL>" --query "data[].{col1:field1, col2:field2}" -o table
Lines read
294
File checksum (to compare versions)
022f85d368160da5db5b1de43a3e4e5417734e2c5ed8167327778bf877e5aae2