Gate every skill before your agent loads it.
safeskill is the SDK + CLI your agent runs. Onboard a signer and a policy once, then it checks each skill against the ENS registry, re-hashes the file locally, and decides — auto-approve, a Ledger override, or block.
Runs offline against a hardcoded demo registry with zero chain config. --ens swaps in real ENS v2 on Sepolia.
Onboard
Hook up a signer — a real Ledger, a local dev key, or none — and set a policy. The policy is yours: a preset, a one-line threshold, or a custom ruleset. It is persisted to ~/.safeskill/config.json.
Gate
Before loading any skill, safeskill resolves its verdict from the ENS registry, re-hashes the live file, and runs your policy. Below-policy skills require a hardware signature; tampered files are always blocked.
Three outcomes
Every skill resolves to exactly one — decided by your policy, with one floor it can never loosen.
Installed with no human in the loop.
Installable only with a verified Ledger signature — the bypass override.
Never installable. A signature cannot override the integrity floor.
The policy is yours.
A policy is an ordered ruleset evaluated top-to-bottom, first match wins, then a default. Plain JSON — ship it, hand-edit it, or pick a preset. Predicates compose with AND:
minSecurityRating·maxSecurityRating— 0–100, higher is saferverdictStatus·hasVerdict·revokedpublisherIn·publisherNotIn— trust by ENS parent
Built-in presets: default · strict · permissive. Set one with --preset, --min-security, or --policy ./file.json.
{
"name": "trust-acme-only",
"rules": [
{ "publisherNotIn": ["acme.safeskills.eth"],
"action": "blocked" },
{ "minSecurityRating": 70,
"verdictStatus": "pass",
"action": "auto-approve" }
],
"default": "needs-override"
}If the signature fails, the skill never loads.
A skill is written to disk only on an explicit auto-approve, or a below-policy skill whose Ledger signature verifies. A blocked skill, a missing signer, a declined or errored signature, or one that fails verification all result in no install — nothing is fetched to disk.
Or call it from code.
The same two parts as the CLI, behind a tiny typed API. Onboard once; then use() before loading any skill and respect the result.
import { Safeskill } from "@aegis/safeskill";
// 1 — onboard once (signer + policy)
await Safeskill.onboard({
signer: "ledger",
minSecurityRating: 70,
});
// 2 — gate a skill before loading it
const ss = await Safeskill.load();
const r = await ss.use("weather.acme.safeskills.eth");
if (!r.installed) throw new Error(r.error); // fail-closedCommand reference
safeskill onboard --ledger --min-security 70Part 1 — hook up a signer + set the policysafeskill policyShow the active ruleset (or --presets for the built-ins)safeskill listThe registry + the decision the policy makes for each skillsafeskill check <name>Resolve ENS → re-hash → decide (no install)safeskill use <name>check + install: auto-approve, or require a Ledger override