Skip to main content
Glama

subdomain_takeover

Detect subdomains vulnerable to dangling-CNAME takeover by resolving CNAMEs, recognizing unclaimed third-party services, and flagging takeover-prone hosts.

Instructions

Check subdomains for a dangling-CNAME takeover risk.

A subdomain is takeover-prone when it CNAMEs to a third-party service (GitHub Pages, S3, Heroku, Azure, ...) whose resource was deleted or never claimed — anyone who registers that resource then controls the subdomain. For each host this resolves the CNAME, recognizes known takeover-prone services, fetches the page, and flags the provider's "unclaimed resource" fingerprint and/or a CNAME target that no longer resolves.

Read-only recon (DNS lookups + one HTTP GET per host). Pair it with subdomain_enum: enumerate first, then pass the interesting hosts here. Only check domains you are authorized to assess.

Args: hosts: One hostname or a comma-separated list, e.g. "blog.example.com,shop.example.com". Capped at 100 per call. timeout: Per-probe network timeout in seconds.

Returns: A dict with checked, vulnerable_count, and results (one entry per host with host, cname, service, status, vulnerable, severity, and detail). status is one of not_applicable, not_vulnerable, potential, dangling_cname, or vulnerable.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
hostsYes
timeoutNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.13.0

TDQS

A4.9/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description carries full burden. It thoroughly discloses behavior: resolves CNAME, recognizes takeover-prone services, fetches the page, flags fingerprints, and notes it is read-only recon (DNS + one HTTP GET per host). It also mentions the host cap and the output structure, leaving little to inference.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is well-structured with a lead sentence, a detailed explanation, usage pairing, and an Args section. It is slightly verbose but every sentence carries weight—explaining the method, safety, and output. No fluff.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity and the absence of an output schema, the description is remarkably complete. It explains the output dict fields (checked, vulnerable_count, results) and the possible statuses. It also covers limitations (cap) and usage context. An agent has everything needed to call it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, but the description fully compensates. It explains 'hosts' with format, example, and cap ('comma-separated list, e.g. ... Capped at 100 per call'), and 'timeout' as 'Per-probe network timeout in seconds.' This adds meaning far beyond the bare schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb and resource: 'Check subdomains for a dangling-CNAME takeover risk.' It clearly distinguishes itself from siblings like subdomain_enum (enumerates) and dns_recon (DNS lookups) by focusing on takeover risk. The purpose is unambiguous.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explicitly instructs when to use this tool: 'Pair it with subdomain_enum: enumerate first, then pass the interesting hosts here.' It also states a condition for use: 'Only check domains you are authorized to assess.' This provides clear routing to the tool and its complementary sibling.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.