Skip to main content

The Hard Part of Giving AI Agents Machine Access Is Not the Tools

Updated 6 min readMarkdown

Reading a file is easy to implement.

Running a command is easy to expose.

Opening a browser is easy to wrap in a tool.

The difficult part starts one step later:

who is allowed to do it, to which resource, through which connection, and under whose authority?

That is the problem I built RunOnMine around.

RunOnMine is an open-source, local-first MCP security gateway for controlled AI access to files, terminals, browsers and desktop applications.

GitHub: https://github.com/ademisler/RunOnMine

The project is now in public beta for macOS, Windows and Linux.

The obvious architecture collapses too much state

The simplest machine-agent architecture is usually something like this:

AI client -> authenticated connection -> shell/tools -> OS account

It works.

It also makes one authenticated connection responsible for several different decisions:

  • identity
  • tool availability
  • resource scope
  • destructive-action policy
  • human approval
  • privilege level

Once those decisions collapse into the connection itself, the operating-system account becomes the effective permission model.

That is a lot of authority to hide behind one credential.

RunOnMine separates those decisions.

The request is the unit of policy

The central object is not "the terminal" or "the filesystem".

It is the request.

A request carries enough context for the local machine to ask:

Who asked?
Through which connector?
Which tool?
Which resource?
Which exact arguments/action?
What does local policy say?

The decision can then be:

allow
ask the owner
or deny

Authentication and OAuth scopes are still useful, but they only narrow the request. They do not grant authority that the local policy did not already allow.

That direction matters to me:

remote identity can reduce local authority; it cannot manufacture more of it.

Resource scope matters more than tool scope

A permission called "filesystem access" sounds precise until the filesystem is the user's entire home directory.

A coding agent may need one repository. That does not imply it needs unrelated projects, SSH configuration, browser data or personal documents.

RunOnMine therefore starts with explicit filesystem roots selected by the owner.

File operations stay inside those roots instead of treating the OS account's readable filesystem as the agent's namespace.

The same principle applies to shell execution: the effective working directory is part of the policy context rather than a cosmetic process option.

Approval is not a substitute for policy

It would be easy to make every non-read operation display a dialog.

That would be secure only in the sense that users eventually learn to click "Approve" without reading.

The goal is not maximum prompting.

The goal is a useful boundary.

Safe operations can be allowed by policy. Trusted developer workflows can be less restrictive. Dangerous or ambiguous actions can stop for local approval.

When approval is required, it should describe the real action and be bound to the requester and action context. A changed action should not inherit an unrelated approval because the same tool name happens to be involved.

A remote agent should not own the approval path

There is a simple confused-deputy problem if the system exposes both:

run_dangerous_action()
approve_dangerous_action()

to the same remote principal.

RunOnMine keeps approval local.

A remote connector can request an action. It cannot turn around and approve its own dangerous request.

Remote administrator execution is also denied by the safety ceiling.

This is intentionally asymmetric: the machine owner has authority the remote agent does not.

Keep MCP local; carry connectivity outward

Another boundary I did not want to blur was the network listener.

RunOnMine's HTTP MCP server stays on loopback.

Remote access uses supported outbound connector/tunnel models rather than making a raw MCP listener public.

That does not make the remote path trusted by default. The connector still goes through requester identity and local policy.

Network transport answers "how did the request arrive?"

It does not answer "may this action run?"

Browser automation is also network access

A browser tool is not just DOM access.

A browser can reach URLs, follow redirects, open WebSockets and potentially touch services on localhost or private networks.

That means browser automation can become a network pivot if destination access is not treated as part of the security boundary.

RunOnMine uses an isolated profile and protected network behavior for its managed browser path. Private/non-routable destinations are treated differently from ordinary public navigation instead of assuming profile isolation is enough.

This was one of the places where the real boundary turned out to be wider than the tool API suggested.

"Stop" needs its own primitive

Connection setup gets a lot of attention in agent tooling.

Revocation often gets less.

I wanted an owner-controlled action with an unambiguous meaning: stop the active access path now.

RunOnMine calls that Emergency Lock.

It stops managed runtime access, rejects pending approvals and clears/revokes temporary authorization state without pretending that uninstall is the same thing as incident response.

Why I do not call it a sandbox

A policy gateway can decide whether a shell request is allowed to run.

It cannot make an arbitrary permitted shell command harmless.

Once execution is allowed, the command has the authority of the operating-system account that runs it.

That is why RunOnMine is described as a security boundary and approval system, not a sandbox.

The distinction is not wording. It tells the user what problem the system is actually trying to solve.

The beta boundary includes distribution trust

The first beta is open source, written in Rust and Apache-2.0 licensed.

The release includes SHA-256 checksums and CycloneDX SBOMs, and the repository records its frozen release candidate and acceptance evidence.

But there are still gaps:

  • macOS is not Developer ID signed/notarized yet
  • Windows is not Authenticode signed yet
  • an independent external security review is still pending

I would rather state those constraints directly than let "security tool" imply guarantees the release does not have.

What I am trying to learn from the beta

The basic implementation works across macOS, Windows and Linux.

The more interesting question now is the permission model.

Where does granularity help, and where does it become friction?

When should an approval be reusable?

Which machine capabilities should never be exposed to a remote agent at all?

Those are product questions as much as security questions.

Repository: https://github.com/ademisler/RunOnMine

Website: https://runonmine.github.io/

7 views

No comments yet. Be the first to comment.