Skip to main content
Glama
0xhackerfren

Frida Game Hacking MCP

by 0xhackerfren

get_session_info

Retrieve current session details including attached processes, active hooks, and memory scan status for game hacking and reverse engineering.

Instructions

Get current session information.

Returns:
    Session state including attached process, hooks, scan state.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The main handler function for the 'get_session_info' tool. It returns a dictionary with the current Frida session status, including whether attached to a process, PID, process name, scan state summary, number of active hooks, breakpoints, and custom scripts.
    @mcp.tool()
    def get_session_info() -> Dict[str, Any]:
        """
        Get current session information.
        
        Returns:
            Session state including attached process, hooks, scan state.
        """
        return {
            "attached": _session.is_attached(),
            "pid": _session.pid,
            "process_name": _session.process_name,
            "spawned": _session.spawned,
            "scan_active": _session.scan_state.scan_active,
            "scan_results_count": len(_session.scan_state.results),
            "scan_value_type": _session.scan_state.value_type,
            "active_hooks": len(_session.hooks),
            "active_breakpoints": len(_session.breakpoints),
            "custom_scripts": len(_session.custom_scripts)
        }
  • The FridaSession class and global _session instance that store all the state queried by get_session_info. Includes is_attached() method used in the handler.
    @dataclass
    class HookInfo:
        """Information about an active hook."""
        address: str
        script: Any
        hook_type: str
        description: str = ""
    
    
    class FridaSession:
        """Manages Frida session state."""
        
        def __init__(self):
            self.device: Optional[Any] = None
            self.session: Optional[Any] = None
            self.pid: Optional[int] = None
            self.process_name: Optional[str] = None
            self.spawned: bool = False
            self.scan_state: ScanState = ScanState()
            self.hooks: Dict[str, HookInfo] = {}
            self.breakpoints: Dict[str, Any] = {}
            self.custom_scripts: Dict[str, Any] = {}
        
        def is_attached(self) -> bool:
            return self.session is not None and not self.session.is_detached
        
        def reset(self):
            self.session = None
            self.pid = None
            self.process_name = None
            self.spawned = False
            self.scan_state = ScanState()
            self.hooks.clear()
            self.breakpoints.clear()
            self.custom_scripts.clear()
    
    
    # Global session instance
    _session = FridaSession()
Behavior3/5

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

With no annotations provided, the description carries the full burden. It discloses that the tool returns session state including attached process, hooks, and scan state, which adds useful behavioral context. However, it doesn't cover aspects like permissions needed, rate limits, or error conditions, which are gaps for a tool with no annotations.

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 front-loaded with the core purpose in the first sentence, followed by a brief returns section. Every sentence adds value without waste, making it efficiently structured and appropriately sized.

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

Completeness4/5

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

Given the tool has 0 parameters, an output schema exists, and no annotations, the description is reasonably complete. It explains what the tool does and what it returns, though it could benefit from more context on usage scenarios or limitations to fully compensate for the lack of annotations.

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 input schema has 0 parameters with 100% coverage, so no parameter information is needed. The description appropriately doesn't discuss parameters, earning a baseline score of 4 for not adding unnecessary details.

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 'Get' and the resource 'current session information', making the purpose evident. However, it doesn't differentiate from siblings like 'get_module_info' or 'list_processes' that also retrieve information, so it's not fully specific about what makes this tool unique.

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?

No guidance is provided on when to use this tool versus alternatives. The description doesn't mention prerequisites, context, or exclusions, leaving the agent to infer usage based on 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