- Hooks.
hooks/hooks.jsonregisters two Node scripts.hooks/gate.mjsruns onPreToolUse(forEdit|Write|MultiEdit|NotebookEdit|Bash|PowerShell) and onStop. It reads the hook JSON from stdin and the plan files underdocs/keystone/(or the AI Factorypaths.specsfolder), and runsgit cat-file -eto see whether a test file is committed. It writes only a JSON decision to stdout.hooks/sessions-event.mjsruns onUserPromptSubmit: it reads only the hook JSON from stdin and, on a side-sessions event, prints only a JSON context line; it runs no git and reads no files. Neither makes network calls or writes files. - Permissions. The hooks run with your user's permissions.
gate.mjscan deny a tool call or remind atStop; it cannot approve anything.KEYSTONE_GATES=offdisablesgate.mjs;KEYSTONE_SESSIONS=offdisablessessions-event.mjs. - Skills and agents are prompts. They use only the tools Claude Code already grants the session. The optional memlab integration calls an MCP server you configured yourself.
Please report privately through GitHub's private vulnerability reporting for this repository. Do not open a public issue for a security problem. Include the affected file, steps to reproduce and the impact. You should get a first reply within a few days.
Only the latest release receives fixes.