Pinning and verifying OpenClaw skill versions
Reviewing a skill once only helps if the skill you reviewed is still the one on disk. Skills on ClawHub are versioned, update --all is one command, and files in a workspace can be edited by anything that can write there, including the agent. Pinning OpenClaw skill versions is how you make updates a decision instead of a side effect. Verifying them is how you notice when the bytes changed anyway. This guide covers both, tool-agnostic first: what the ClawHub lockfile and clawhub pin already give you, how to review a specific version before it reaches your skills folder, and where Ironheights fits as one layer. For what static scanning still misses, see the limitations page.
Why versions matter for skill security
A skill is mostly text: a SKILL.md, some scripts, sometimes an install step. A clean version 1.0.0 tells you nothing about 1.1.0. Public research on ClawHub has shown how much hostile content passes through a registry: Snyk's ToxicSkills study confirmed 76 malicious payloads by hand across 3,984 skills. Most reports describe skills that were hostile from the first upload, but the same attacker options exist on an update: a new prerequisite, a new host, a new script. We wrote up that shape in Baselines for agent files: detecting silent tampering.
There are three separate questions, and they need different controls:
| Question | Control | What answers it |
|---|---|---|
| Which version do I run? | Pin it | ClawHub lockfile and clawhub pin |
| Is that version acceptable? | Review it before install | clawhub inspect, a scan of that exact version, a human read |
| Are the files on disk still that version? | Verify them | ClawHub update fingerprint, ironheights verify |
Pinning without review freezes whatever you happened to install. Review without pinning gets undone by the next bulk update. Verification without either tells you something changed but not whether it was acceptable.
What ClawHub already gives you
The ClawHub CLI reference documents a lockfile and a pin flag. These are worth using whether or not you use any scanner.
clawhub install @owner/slugresolves the latest version, extracts it into the skills folder of the working directory, and records the installed version in.clawhub/lock.json. Each skill also gets a.clawhub/origin.json.clawhub listreads that lockfile and showspinnednext to frozen skills, with the reason if one was recorded.clawhub pin <skill> --reason "<text>"marks an installed skill as pinned. Pinned skills are skipped byupdate --all, rejected by a directupdate <skill>, and also rejectinstall --force, so the local bytes are not replaced by accident.clawhub unpin <skill>removes the pin when you decide to move.clawhub updatecomputes a fingerprint of the local files. If it matches a known version, the update proceeds. If it does not match, the CLI refuses by default and overwrites only with--force(or a prompt when interactive).
That last point is a useful integrity signal on its own: a skill whose local files no longer match any published version is a skill someone or something edited. The native openclaw skills install and openclaw skills update --all commands described in the OpenClaw ClawHub docs also persist source metadata so updates stay on ClawHub.
Where this is better than a scanner: it is built into the tool you already use, it knows the registry's published versions, and the pin stops the most common mistake, a bulk update nobody read.
Where it stops: a pin is a field in a lockfile, not a signature. Any process that can write the workspace can edit the lockfile or the skill files. The fingerprint check runs when you run update, not continuously, and it tells you the files differ from a published version, not whether the difference is dangerous.
A pinning workflow that holds up
- Inspect the exact version before you install it.
clawhub inspect @owner/slug --versionslists version history.clawhub inspect @owner/slug --version 1.2.0 --fileslists the files in that version, and--file <path>shows a file's raw content without installing anything. - Scan that exact version.
npx ironheights fetch owner/slug@1.2.0downloads that version into a temp directory, prints every URL before requesting it, writes files without executing them, and scans the result. You get the same verdict a local scan gives. - Install it, or let the scan gate the install.
npx ironheights safe-install owner/slug@1.2.0copies the skill into your skills directory only when the verdict isno-findings, orreviewif you pass--accept-review. Ablockorincompleteverdict is not installed. - Pin it.
clawhub pin <skill> --reason "reviewed 1.2.0 on 2026-10-30". The reason is for the next person, including you in three months. - Record a baseline.
npx ironheights baseline createhashes the skill files and the watched agent files. More on this below. - Update on purpose. When you want a newer version, repeat steps 1 to 3 against the new version number, compare findings, then
unpin, update, pin again, and runbaseline update.
Step 6 is where most of the value is. npx ironheights scan ./path/to/skill --since-baseline lists only findings that are new since your baseline, so an update that adds a prerequisite or a new host stands out instead of hiding in the old noise. Pre-existing findings still count toward the grade.
Verifying what is on disk
Pinning controls what the update command does. It does not stop a skill, a script, or the agent from editing files directly. That is what verification is for.
npx ironheights baseline create writes ~/.ironheights/baseline.json (mode 0600) with a sha256, size and permission mode for each watched path. npx ironheights verify hashes them again and reports differences:
| Rule | What it means | Typical cause |
|---|---|---|
| IH-INT-001 | A skill file no longer matches the baseline | An update, a hand edit, or tampering |
| IH-INT-002 | A new skill file or directory appeared | A new install or a dropped file |
| IH-INT-003 | A file from the baseline is gone | An uninstall or a cleanup by something else |
| IH-INT-004 | A watched agent file changed | Edits to files like AGENTS.md or MEMORY.md |
verify exits 0 with no findings, 1 for review and 2 for block, so a script or scheduled job can act on it. To make the baseline itself harder to rewrite quietly, sign it: baseline create --key <file> and verify --key <file>. That catches an edited baseline only while the key stays private.
For skills that change often, ironheights scan --changed <skills folder> rescans only skills whose content hash or SKILL.md version changed since the last scan and prints why. ironheights watch --once runs that check once and exits, which suits cron or a post-update hook.
Run these from your own shell or a job the agent does not start. An in-agent check can be talked out of reporting a change; we explain why in Why a security skill that runs inside the agent can be bypassed.
Pinning what the skill installs
A pinned skill can still pull unpinned code. A SKILL.md that runs npx some-package or pip install some-package gets whatever that registry serves today. Ironheights does not scan that package's code, and it says so: every registry dependency is listed as dependency unscanned: with the package name, the version as written, and whether it is pinned to an exact version. For MCP servers, IH-MCP-001 flags a server launched from a remote command or an unpinned npx package.
Checklist for dependencies:
- [ ] Every package a skill installs names an exact version, not a range or
latest. - [ ] Remote install steps are gone, or you understand them. IH-EXEC-001 flags remote content piped into an interpreter and IH-EXEC-002 flags prerequisite installs from an external URL.
- [ ] MCP servers launch from a pinned package or a local path.
- [ ] Your CI pins the scanner too. The Ironheights GitHub Action runs
npx ironheights@<version> scan; pin the tag you trust. See Scanning agent skills in CI before install.
Where this approach is weaker
Be honest about the limits before you rely on it:
- Pinning trusts your first review. If the version you pinned was already hostile, pinning keeps it. Review is the step that matters; read A 10-minute checklist for vetting an OpenClaw skill.
- A scan reads text. Ironheights flags risky patterns in skill files. It does not run them, does not judge what a downloaded binary does at runtime, and does not read the code of registry packages a skill installs. A clean result is not proof of safety. Our benchmark measured content rules on a synthetic corpus; it did not test pinning,
baselineorverify. - A baseline is only as safe as your home directory. Anyone who can write it can rewrite the baseline. Signing and an off-machine copy help; they do not fix a compromised account.
- Verification is periodic.
verifyandwatchreport changes when they run. They do not block a write as it happens. - Names and publishers are out of scope. Pinning
@owner/slugdoes not tell you the owner is who you think. See Typosquatted skill names on ClawHub.
The full list is on the limitations page, and public incidents we track are on the tracker.
Quick start
Pick one skill you already run and do this today:
clawhub listto see what is installed and whether anything is pinned.npx ironheights scan ./path/to/skill, or paste it into the browser scanner, and read the findings.clawhub pin <skill> --reason "reviewed <version> on <date>".npx ironheights baseline create, thennpx ironheights verifyfrom a scheduled job you own.
If you want the scanner and integrity checks in one place, Ironheights is on npm and ClawHub and runs locally.
FAQ
How do I pin an OpenClaw skill version?
Install the version you reviewed, then run clawhub pin with the skill name and an optional --reason. ClawHub records the pin in .clawhub/lock.json. Pinned skills are skipped by update --all, rejected by a direct update, and refuse install --force until you run clawhub unpin.
Does pinning a skill stop it from being modified?
No. A pin controls what the ClawHub update commands do. Files in the workspace can still be edited by anything with write access. Record a baseline with npx ironheights baseline create and run npx ironheights verify to see added, modified or removed files.
How do I review a specific skill version before installing it?
clawhub inspect with --version and --files lists that version's files without installing. npx ironheights fetch with the owner, slug and version (for example owner/slug@1.2.0) downloads that version to a temp directory and scans it without running anything.
Does Ironheights scan the packages a skill installs?
No. It scans the skill's own files and lists each registry dependency as unscanned, with whether it is pinned to an exact version. Review those packages separately.
Sources
- ClawHub CLI reference: install, pin, unpin, update and lockfile, GitHub.
- ClawHub, OpenClaw documentation.
- ToxicSkills: malicious AI agent skills on ClawHub, Snyk.
- Ironheights README: fetch, safe-install, baseline and verify, GitHub.
- ironheights on npm, npm.
- Ironheights limitations, Ironheights.