Skip to main content
Glama

unflatten_control_flow

Deobfuscates OLLVM control-flow flattening state dispatchers symbolically and reconstructs clean linear basic blocks from a flattened binary function.

Instructions

Symbolically deobfuscates OLLVM Control-Flow Flattening (CFF) state dispatchers and reconstructs clean linear basic blocks.

Input Schema

NameRequiredDescriptionDefault
binary_pathYesPath to binary
timeout_secondsNoSolver timeout
function_addressYesHex address of flattened function

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changed
    • changedInput schema / properties / binary_path / description
      Previous value: -"Absolute path to target binary"New value: +"Path to binary"
    • changedInput schema / properties / function_address / description
      Previous value: -"Hex address (e.g. '0x401500') or symbol"New value: +"Hex address of flattened function"
    • removedInput schema / properties / timeout_seconds / default
      Removed value: -60
    • addedInput schema / properties / timeout_seconds / description
      Added value: +"Solver timeout"
  2. First observedv2.0.0

TDQS

C2.9/5.0
Behavior2/5

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

No annotations are provided, so the description carries the full behavioral burden. It identifies the deobfuscation target but does not disclose whether the binary is modified in place, whether the operation is read-only or destructive, required permissions, or what happens on solver timeout. It adds technical context but leaves core behavioral traits unstated.

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, dense sentence with the core technical action front-loaded. There is no filler or repetition, and every term ('symbolically', 'OLLVM CFF', 'linear basic blocks') carries domain meaning.

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

Completeness2/5

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

With no annotations, no output schema, and a non-trivial symbolic deobfuscation operation, the description is too thin. An agent would still lack guidance on prerequisites, side effects, failure modes, and expected results beyond the one-line purpose statement.

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% for all three parameters, so binary_path, function_address, and timeout_seconds are already documented. The description adds no parameter-level nuance such as address format expectations or timeout semantics beyond what the schema provides, which is acceptable baseline behavior.

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

Purpose4/5

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

The description states a specific verb and technical resource: 'Symbolically deobfuscates OLLVM Control-Flow Flattening (CFF) state dispatchers and reconstructs clean linear basic blocks.' This is far more specific than a generic decompile tool, though it does not explicitly differentiate itself from siblings like decompile_native_function or solve_branch_reachability.

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

Usage Guidelines2/5

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

The description gives no when-to-use or when-not-to-use guidance, no prerequisites (e.g., supported architectures or OLLVM variants), and no named alternatives among the many sibling binary-analysis tools. Usage is only implied by the technical term 'OLLVM Control-Flow Flattening.'

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