Why this exists

AI coding assistants became useful the moment they could touch real systems. That is also the moment they became a security problem.

Under the Model Context Protocol, each tool an assistant can use runs as its own server, typically on a local port, usually with no authentication, no access control, and no record of what was called. When an assistant can run a database write, delete a file, or make an outbound API call, no record stops being an inconvenience. You cannot answer who approved this, or whether anyone agreed to it in advance.

How it works

AgentHub sits between the AI client and the tool servers as a reverse proxy. Every call passes through authentication, a security boundary, and a policy engine, and every outcome, allowed or blocked, is written to an audit log.

Policies are set per tool and there are four levels: allow, block, read-only, and require-approval. Read-only is the interesting one, because it detects write operations by naming convention and blocks them without needing a hand-written rule for every tool in the catalogue.

The security boundary blocks request forgery attempts at the point where they matter. Private IP ranges, cloud metadata endpoints, internal hostnames, and shell metacharacters in tool arguments.

When a tool is set to require approval, the request pauses, a pending record is created, the approver is notified with the tool name and the arguments, and the call waits. If nobody answers inside five minutes, it does not run.

The audit log records the user, the tool, the arguments, the response status, the caller's address, and which administrator approved it.

The decision that shaped the product

Making approval a gate rather than a wall.

The secure default in this category is to deny everything sensitive, which is safe and useless. A developer whose assistant cannot read the staging database gets no value, turns the gateway off, and a security tool that gets turned off protects nothing.

So high-risk operations pause instead of failing. The assistant keeps working, a human gets a decision they can make in ten seconds, and the access stays narrow. Reviewability mattered as much as enforcement. An audit trail that only a security engineer can parse gets opened once, during an incident. An audit trail that reads like a log gets looked at.

What it does not do

Enforcement covers the integrations currently supported, not every tool server that exists. The security properties have not been formally audited. This is a founder-built project rather than a product with a compliance certificate attached to it.

What to take from this

If you give an agent access to production, the useful questions are what it can reach, what it can do once it gets there, and who finds out afterwards. Least privilege is the easy part. Knowing what happened is the part that gets skipped.