Skip to main content
Glama

Extract Firmware

extract_firmware

Extracts caller-selected firmware bytes into a new output directory and returns verified paths, digests, and diagnostics for safe binary analysis without executing extracted code.

Instructions

Extract caller-selected firmware bytes with Unblob 26.6.x (verified with 26.6.4) into an absent output directory. Returns verified child paths/digests, task derivations, unknown chunks and extraction diagnostics inline. Preserves the default sandbox; publishes regular files only. Linux, caller-supplied tool, format-specific extractors and util-linux prlimit required. No mounts or extracted-code execution. Select a returned native file with open_binary for Ghidra analysis; decompressed offsets are not original-file addresses.

Example tool call

This call uses example arguments supplied in the tool’s input schema.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "path": "/tmp/firmware.bin",
      "range": {
        "length": 4096,
        "offset": 64
      },
      "output_directory": "/tmp/firmware-output"
    },
    "name": "extract_firmware"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathYesAbsolute local firmware file; never executed. Relative paths are rejected.
rangeNoExplicit file-byte interval; omit to extract the whole file
max_depthNoExtraction depth; reaching it yields partial analysis
max_output_bytesNoStaging file-byte budget, checked during extraction; transient overshoot is possible
max_output_filesNoStaging entry budget, including directories and links
output_directoryYesAbsolute, absent output directory; parent must exist

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.4/5.0
Behavior5/5

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

Goes well beyond the annotations by disclosing sandbox preservation, that only regular files are published, that no mounts occur and extracted code is never executed, plus the budget-checking/transient-overshoot behavior. The "absent output directory" requirement and toolchain prerequisites are failure modes the annotations cannot convey.

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?

Front-loaded with the core action and engine version, and each subsequent sentence carries distinct information (returned data, isolation guarantees, prerequisites, follow-up routing). It is dense and telegraphic with some compressed fragments, but no sentence is redundant.

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?

With no output schema, the description takes on the burden of describing returns (verified child paths/digests, task derivations, unknown chunks, diagnostics inline) and does so. For a destructive-adjacent, environment-dependent extraction tool it also covers isolation, prerequisites, and the offset-caveat an agent needs before analyzing results.

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?

Schema description coverage is 100%, so every parameter is already documented, and the description largely echoes that (caller-selected bytes, absent output directory) rather than adding new parameter meaning. The one substantive addition — that decompressed offsets are not original-file addresses — clarifies how `range` relates to returned results, but it is framed as output guidance rather than parameter semantics.

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?

States a specific verb and resource ("Extract ... firmware bytes") plus the concrete engine and version (Unblob 26.6.x, verified with 26.6.4), so the agent knows exactly what operation runs. It also routes forward to the sibling tool `open_binary` for the downstream Ghidra step, which disambiguates it from analysis tools.

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?

Gives clear preconditions for invocation: Linux host, caller-supplied Unblob tool, format-specific extractors, and util-linux prlimit must be present, and the output directory must not already exist. It names `open_binary` as the follow-up for analysis but does not contrast this tool against siblings like `extract_artifact` or `inspect_firmware_regions`, leaving the choice between extraction tools implicit.

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

Deploy Server

Other Tools