v0.18 · now guards your AI agents and this machine

Local protection for builders.

Your machine is a castle. Every package, workflow and agent config is something you let through the gate. selfguard posts a guard at the gate who checks each one, on your own computer, and sounds the alarm the moment a Trojan horse shows up.

Download for Mac

Apple Silicon & Intel · macOS 13+

Open source (MIT) · no account · no telemetry · macOS & Linux

selfguard · now

Packages, CI workflows, agent configs and startup files: everything that comes through the gate gets checked.

What it guards

Four ways in. One guard.

It started with your repos. It doesn't stop there.

Dependencies of every repo

Every project on your machine, checked against OSV.dev, even the ones you haven't opened in months. Malicious packages outrank any CVE, with one upgrade target per package.

npm · pnpm · yarn · bun · uv · Poetry · Cargo · Go

Catches Shai-Hulud, the npm worm that shipped compromised releases

CI workflows

The GitHub Actions your workflows use: compromised actions, references not pinned to a commit SHA, and script injection.

.github/workflows

Catches tj-actions/changed-files, retagged to leak CI secrets

AI agents

MCP servers for Claude, Cursor, VS Code and Codex, without reading their secrets. Repo files that run code when you open the repo, and hidden Unicode in instruction files.

MCP configs · .claude · .cursor · .vscode · AGENTS.md

Catches Contagious Interview's autorun VS Code tasks

This machine

What malware leaves behind: suspicious launch items, hooks in shell startup files, agents aliased to skip permissions, plaintext tokens (presence only) and Python startup hooks.

LaunchAgents · ~/.zshrc · ~/.npmrc · ~/.aws · .pth

Catches LiteLLM's .pth stealer and ClickFix's fake updaters

Privacy

It guards your secrets. It never takes them.

selfguard runs entirely on your computer. No account, no telemetry, no server of ours. The only thing that ever leaves is what's needed to look up a public package.

The only thing it sends

One lookup per dependency to OSV.dev, Google's open vulnerability database:

POST api.osv.dev/v1/querybatch
{
  "package": { "ecosystem": "npm", "name": "lodash" },
  "version": "4.17.21"
}

That's it: a public package name and version. Plus a daily "is there a newer selfguard?" to the npm registry, which you can turn off. Want zero? Point it at your own OSV mirror.

Never leaves your machine

  • Your codeSource files are never uploaded, and nothing in your projects is ever run.
  • Your secretsTokens in ~/.npmrc or ~/.aws, MCP keys and env vars: it only notes that they exist. The values are never stored, shown or sent.
  • Your projectsNo file paths, repo names, git remotes or history.
  • YouNo account, no email, no device ID, no usage tracking.
  • Open sourceMIT. Read every line it runs.
  • Zero dependenciesNo third-party code to trust.
  • Signed releasesnpm provenance, notarized Mac app.
  • Read-onlyFiles are parsed as data, never executed.

Read the full security model →

How it works

Set it up once. It tells you on its own.

Alerts without asking

Re-checks seconds after a lockfile or config changes and syncs new advisories on a schedule. Attacks open a dialog that stays on screen.

Tells you what to do

"Upgrade lodash to 4.18.0", "pin this action to a SHA", "use a short-lived token". Not a wall of advisories.

Quiet until it matters

Only active repos alert you, and the first scan is a baseline: you hear about what's new, not the backlog.

Post a guard on your machine.

Two minutes to set up. Then it's quiet until it matters.

Download for Mac

Apple Silicon & Intel · macOS 13+

Requires Node.js 20.10+ for the CLI. The Mac app bundles everything.