Skip to main content
Glama
0xhackerfren

Frida Game Hacking MCP

by 0xhackerfren

resolve_symbol

Find memory addresses of functions or symbols in game modules for reverse engineering and hooking operations.

Instructions

Resolve a symbol to its address.

Args:
    module_name: Name of the module containing the symbol
    symbol_name: Name of the symbol/function

Returns:
    Address of the symbol.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
module_nameYes
symbol_nameYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The primary handler for the 'resolve_symbol' MCP tool. It uses a Frida script to call Module.findExportByName to resolve the symbol address in the specified module and returns it or an error.
    @mcp.tool()
    def resolve_symbol(module_name: str, symbol_name: str) -> Dict[str, Any]:
        """
        Resolve a symbol to its address.
        
        Args:
            module_name: Name of the module containing the symbol
            symbol_name: Name of the symbol/function
        
        Returns:
            Address of the symbol.
        """
        global _session
        
        if not _session.is_attached():
            return {"error": "Not attached. Use attach() first."}
        
        try:
            script_code = f"""
            var addr = Module.findExportByName("{module_name}", "{symbol_name}");
            send(JSON.stringify(addr ? {{address: addr.toString()}} : {{error: "Symbol not found"}}));
            """
            
            result_data = []
            def on_message(message, data):
                if message['type'] == 'send':
                    result_data.append(message['payload'])
            
            script = _session.session.create_script(script_code)
            script.on('message', on_message)
            script.load()
            script.unload()
            
            import json
            result = json.loads(result_data[0]) if result_data else {"error": "No response"}
            result["module"] = module_name
            result["symbol"] = symbol_name
            return result
        
        except Exception as e:
            return {"error": f"Failed to resolve symbol: {str(e)}"}
  • The resolve_symbol tool is registered/listed in the capabilities under the 'module_information' category in the list_capabilities tool.
            "module_information": [
                "list_modules", "get_module_info", "get_module_exports",
                "get_module_imports", "resolve_symbol"
            ],
            "function_hooking": [
                "hook_function", "unhook_function", "replace_function",
                "hook_native_function", "list_hooks", "intercept_module_function"
            ],
            "debugging": [
                "set_breakpoint", "remove_breakpoint", "list_breakpoints", "read_registers"
            ],
            "script_management": [
                "load_script", "unload_script", "call_rpc"
            ],
            "window_interaction": [
                "list_windows", "screenshot_window", "screenshot_screen",
                "send_key_to_window", "focus_window"
            ],
            "standard": [
                "list_capabilities", "get_documentation", "check_installation"
            ]
        },
        "total_tools": 42
    }
  • The resolve_symbol tool is used as a helper in the intercept_module_function tool to resolve the function address before hooking it.
    result = resolve_symbol(module_name, function_name)
    if "error" in result:
        return result
    
    return hook_function(result["address"], on_enter, on_leave,
                        f"{module_name}!{function_name}")
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 burden of behavioral disclosure. It states what the tool does (resolves symbol to address) but doesn't describe how it behaves: e.g., whether it requires an attached process, what happens if the symbol isn't found (error vs. null), or if there are rate limits. For a tool with zero annotation coverage, this is a significant gap in transparency.

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 appropriately sized and front-loaded: the first sentence states the core purpose, followed by structured 'Args' and 'Returns' sections. Every sentence earns its place by providing essential information without fluff. It could be slightly more concise by integrating the parameter explanations into the main flow, but the structure is clear and efficient.

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 2 parameters with 0% schema coverage and an output schema (implied by 'Returns'), the description is moderately complete. It covers the basic purpose and parameters but lacks behavioral context (e.g., error handling, prerequisites) and doesn't fully leverage the output schema's existence to explain return value details. For a simple lookup tool, it's adequate but has clear gaps in usage and transparency.

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?

The description explicitly lists and briefly explains both parameters ('module_name' and 'symbol_name'), adding meaning beyond the input schema which has 0% description coverage. It clarifies that 'module_name' is the containing module and 'symbol_name' is the target symbol/function. With 2 parameters and no schema descriptions, the description effectively compensates, though it could provide more detail (e.g., format examples).

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 clearly states the verb 'resolve' and the resource 'symbol to its address', making the purpose understandable. It distinguishes from siblings like 'get_module_info' or 'get_module_exports' by focusing on address resolution rather than general module information or export listing. However, it doesn't explicitly differentiate from tools like 'get_scan_results' or 'scan_pattern' that might also involve symbol-related operations.

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 provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., whether a process must be attached), nor does it compare to siblings like 'get_module_exports' (which might list symbols) or 'scan_pattern' (which might find symbols by pattern). The lack of context leaves the agent to infer usage from the tool name alone.

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/0xhackerfren/frida-game-hacking-mcp'

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