Skip to main content
Glama
badchars

osint-mcp-server

by badchars

dns_srv_discover

Discover SRV records and service CNAMEs for domains to identify SIP, XMPP, LDAP, Kerberos, CalDAV, CardDAV, Autodiscover, OWA, ADFS, and other services.

Instructions

Discover SRV records and common service CNAMEs for a domain. Probes for SIP, XMPP, Autodiscover, LDAP, Kerberos, CalDAV, CardDAV, and checks CNAMEs for autodiscover, lyncdiscover, OWA, ADFS, etc.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
domainYesDomain to probe

Implementation Reference

  • The implementation of the dns_srv_discover logic in src/dns/index.ts.
    export async function dnsSrvDiscover(domain: string): Promise<SrvDiscoverResult> {
      const srvRecords: SrvRecord[] = [];
      const cnameRecords: CnameRecord[] = [];
    
      // SRV probes
      const srvPromises = SRV_PROBES.map(async (prefix) => {
        const fqdn = `${prefix}.${domain}`;
        try {
          const srvs = await dns.resolveSrv(fqdn);
          for (const s of srvs) {
            srvRecords.push({ name: fqdn, target: s.name, port: s.port, priority: s.priority, weight: s.weight });
          }
        } catch {
          // Not found
        }
      });
    
      // CNAME probes
      const cnamePromises = CNAME_PROBES.map(async (prefix) => {
        const fqdn = `${prefix}.${domain}`;
        try {
          const cnames = await dns.resolveCname(fqdn);
          for (const c of cnames) {
            cnameRecords.push({ name: fqdn, target: c });
          }
        } catch {
          // Not found — try A record to see if it exists
          try {
            const ips = await dns.resolve4(fqdn);
            if (ips.length > 0) {
              cnameRecords.push({ name: fqdn, target: ips.join(", ") });
            }
          } catch {
            // Not found
          }
        }
      });
    
      await Promise.all([...srvPromises, ...cnamePromises]);
    
      return { domain, srvRecords, cnameRecords };
    }
  • The tool definition and registration for dns_srv_discover.
    const dnsSrvDiscoverTool: ToolDef = {
      name: "dns_srv_discover",
      description: "Discover SRV records and common service CNAMEs for a domain. Probes for SIP, XMPP, Autodiscover, LDAP, Kerberos, CalDAV, CardDAV, and checks CNAMEs for autodiscover, lyncdiscover, OWA, ADFS, etc.",
      schema: {
        domain: z.string().describe("Domain to probe"),
      },
      execute: async (args) => json(await dnsSrvDiscover(args.domain as string)),
    };
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It describes what the tool probes for but lacks details on how it behaves: no mention of rate limits, error handling, output format, whether it performs active probing or passive lookups, or any authentication requirements. This leaves significant gaps for an agent to understand the tool's operation.

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 efficiently structured in two sentences: the first states the core purpose, and the second lists examples of what it probes for. It's front-loaded with the main action and avoids unnecessary verbiage, though the list of protocols/services could be slightly condensed for better readability.

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

Completeness3/5

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

Given the tool's moderate complexity (probing multiple services), no annotations, and no output schema, the description is partially complete. It covers the purpose and scope well but lacks behavioral details (e.g., output format, error cases) and doesn't compensate for the absence of annotations. This is adequate for basic understanding but has clear gaps for reliable agent use.

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

Parameters3/5

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

The input schema has 100% description coverage, with the 'domain' parameter clearly documented as 'Domain to probe'. The description adds no additional parameter semantics beyond what the schema provides, such as format examples or constraints. The baseline score of 3 is appropriate since the schema adequately covers the single parameter.

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 clearly states the specific action ('discover SRV records and common service CNAMEs') and the target resource ('for a domain'), with explicit examples of protocols and services probed (SIP, XMPP, Autodiscover, etc.). It distinguishes itself from sibling DNS tools like dns_lookup or dns_reverse by focusing on service discovery rather than general DNS queries.

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

Usage Guidelines4/5

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

The description implies usage context by listing specific protocols and services (e.g., SIP, XMPP, LDAP), suggesting it's for identifying infrastructure services on a domain. However, it doesn't explicitly state when to use this tool versus alternatives like dns_lookup or when not to use it (e.g., for general DNS resolution).

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/badchars/osint-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server