Skip to main content
Glama
0xhackerfren

Frida Game Hacking MCP

by 0xhackerfren

spawn

Launch a process in suspended mode to inject hooks before execution begins, enabling early-stage game manipulation and reverse engineering.

Instructions

Spawn a process suspended for early hooking.

Args:
    path: Path to executable
    args: Optional command line arguments

Returns:
    Spawn information. Call resume() to start execution.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathYes
argsNo

Implementation Reference

  • The main handler function for the 'spawn' MCP tool. It spawns a new process using Frida's device.spawn(), attaches a session to it while suspended, sets session state, and returns spawn information. This implements process spawning with early hooking support.
    @mcp.tool()
    def spawn(path: str, args: List[str] = None) -> Dict[str, Any]:
        """
        Spawn a process suspended for early hooking.
        
        Args:
            path: Path to executable
            args: Optional command line arguments
        
        Returns:
            Spawn information. Call resume() to start execution.
        """
        global _session
        
        if not FRIDA_AVAILABLE:
            return {"error": "Frida not installed. Run: pip install frida frida-tools"}
        
        if _session.is_attached():
            detach()
        
        try:
            device = get_device()
            spawn_args = [path] + (args or [])
            
            _session.pid = device.spawn(spawn_args)
            _session.session = device.attach(_session.pid)
            _session.process_name = path.split("\\")[-1].split("/")[-1]
            _session.spawned = True
            
            return {
                "success": True,
                "pid": _session.pid,
                "process_name": _session.process_name,
                "state": "suspended",
                "message": f"Spawned {_session.process_name}. Call resume() to start."
            }
        
        except Exception as e:
            return {"error": f"Failed to spawn: {str(e)}"}

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