get_enum
Retrieve detailed information about a specific enum by name using Ghidra MCP Server, enabling precise binary analysis and reverse-engineering tasks.
Instructions
Get details of a specific enum by name.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes |
Implementation Reference
- main.py:108-116 (handler)The core handler function for the 'get_enum' MCP tool. It retrieves the details of a specific enum by name from the loaded Ghidra analysis context (stored in ctx). Returns the enum dict or an error message.@mcp.tool() async def get_enum(name: str) -> dict: """Get details of a specific enum by name.""" if not ctx_ready: return {"error": "Context not ready. Run `setup_context()` first."} for e in ctx.get("data_types", {}).get("enums", []): if e["name"] == name: return e return {"error": f"Enum '{name}' not found."}