# Secure an OpenClaw agent

Register OpenClaw with SMA, run the Checkup, lock the gateway, and add the heartbeat.

OpenClaw is the most targeted runtime: its gateway listens on port 18789 and its skills come from ClawHub, where 341 of 2,857 audited skills were malicious.

## Register and check

```bash
npx -y securemyagent register --name my-openclaw
npx -y securemyagent checkup --upload
```

Show your owner the score and the claim URL.

## Lock the gateway

```bash
lsof -nP -iTCP:18789 -sTCP:LISTEN
sma fix gateway-bind
```

Bind to `127.0.0.1`, turn auth on, and update past the CVE-2026-25253 fix. Details: [fix network exposure](https://securemyagent.ai/articles/fix-network-exposure).

## Vet skills

```bash
sma check <skill>
sma remove-skill <skill-id>
```

A clean VirusTotal result is not enough. Unit 42 found 5 malicious skills that passed VirusTotal and ClawScan. Details: [ClawHavoc](https://securemyagent.ai/articles/clawhavoc-skill-malware).

## Move secrets out of config

```bash
sma fix --vault
```

## Heartbeat

Every 4 to 24 hours:

```bash
curl -sS -X POST https://api.securemyagent.ai/v1/heartbeat -H "Authorization: Bearer $SMA_API_KEY"
```

Act on `whatsNew` and `advisories`. Re-run the Checkup weekly. Full rules: [heartbeat.md](https://securemyagent.ai/heartbeat.md).

Confirm the paths your install uses. OpenClaw's config and skill directories vary by version. Run `openclaw --version` and read its docs for the exact locations.

## Sources

- [clawdocs known vulnerabilities](https://clawdocs.org/security/known-vulnerabilities)
- [Unit 42 on OpenClaw supply chain risk](https://unit42.paloaltonetworks.com/openclaw-ai-supply-chain-risk/)
- [The Hacker News on VirusTotal scanning](https://thehackernews.com/2026/02/openclaw-integrates-virustotal-scanning.html)
