Skip to main content
Glama

audit_x509_pem_chain

Read-onlyIdempotent

Audit X.509 PEM or Base64 DER certificate bundles to detect chain-order issues, missing intermediates, weak SHA-1/RSA keys, and upcoming expirations before deployment.

Instructions

Decodes X.509 PEM or Base64 DER certificate bundles, detects scrambled Leaf -> Intermediate CA order, missing intermediates, weak SHA-1/<2048-bit RSA keys, and expiry countdowns.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "audit_x509_pem_chain"
  }
}

Input Schema

NameRequiredDescriptionDefault
certPemNoX.509 PEM certificate or fullchain.pem bundle text (only public CERTIFICATE blocks are emitted).
certPathNoOptional local file path to a .pem, .crt, or .cer certificate bundle when certPem is omitted.
stripRootNoWhen true (default), strips redundant self-signed Root CA certificates from autoOrderedFullchainPem.
minDaysRemainingNoOptional custom expiry warning threshold in days (defaults to 30).
referenceTimeIsoNoOptional ISO-8601 timestamp overriding wall-clock time for deterministic expiry calculations.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.9/5.0
Behavior3/5

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

Annotations already establish read-only, idempotent, non-destructive, and closed-world behavior. The description adds useful behavioral detail by naming the defects it reports, but it does not explain output shape, error handling, or how it treats mixed or broken bundles.

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

Conciseness5/5

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

The description is a single front-loaded sentence with no filler. The list of checks is dense but every item is relevant to what the tool detects.

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?

For a five-parameter audit tool with no output schema, the description explains the input domain and checks performed but never states the return structure or how results are organized. The schema and annotations fill some gaps, yet output expectations remain implicit.

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

Parameters4/5

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

Schema coverage is 100%, so the parameter definitions carry most of the load. The description still adds meaning by noting Base64 DER input, which the certPem schema does not mention, and by linking expiry countdowns to the expiry-threshold parameter, though it says nothing about certPath, stripRoot, or referenceTime.

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 uses a specific verb ('Decodes') and resource ('X.509 PEM or Base64 DER certificate bundles'), then enumerates concrete checks such as scrambled Leaf -> Intermediate CA order, missing intermediates, weak keys, and expiry countdowns. That scope clearly separates it from the hostname, serial/SPKI, and CSR-match siblings.

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

Usage Guidelines3/5

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

There is no explicit when-to-use or when-not-to-use guidance, and no sibling alternative is named. The list of detected problems implies it should be used for chain-audit tasks, but the agent must infer that context.

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