← Back to library

Make a security audit your new agent's first job

Jonathan Shriftman, a venture investor, installed OpenClaw on an inexpensive VPS, connected it to Telegram and named it Pao. His first request, before any features, was a security audit. Pao configured the firewall, blocked direct root logins over SSH, patched a Docker proxy weakness it discovered, and wrote up each change, all for roughly thirty cents of API usage.

  • OutcomeClose obvious holes on the server running your always-on agent before you give it access to anything else.
  • SetupUnder an hour
  • LevelIntermediate
  • CreditJonathan Shriftman
View original
Works with
OpenClawCustom agent

Published Oct 23, 2026Updated Oct 23, 2026AI dry run on sample input: passed Oct 23, 2026Source verified Oct 23, 2026

When should you use it?

  • You just installed an always-on agent on a rented server
  • You lack the background to harden Linux yourself
  • The agent will later get email or business tools

Not for: Production systems with an existing security team; Servers you cannot afford to lock yourself out of

What do you need, and what do you get?

You need

  • A freshly set up VPS running the agent
  • A way to message the agent
  • Console access from your hosting provider as a fallback

You get

  • Firewall rules and SSH changes applied
  • A written record of what changed and why

How does it work, step by step?

  1. Keep a way back inConfirm you can reach the server's web console before any SSH changes.
  2. Ask for an audit before featuresHave the agent list open ports, login settings and container exposure.
  3. Approve each fixLet it propose firewall rules, disable root login and patch exposed services, one at a time.
  4. Get it written downAsk for a short document of every change and how to undo it.
  5. Re-check laterRepeat the audit after you add new tools or services.

The prompt

Our own prompt, inspired by Jonathan Shriftman and written to work in OpenClaw and Custom agent. Values in lime are placeholders.

Prompt0 variables
Audit the security of this server before we do anything else. List open ports, running services, SSH settings and any containers exposed to the internet. For each issue, propose a fix and wait for my approval. Make sure a non-root user with sudo works before disabling root SSH login. After each change, confirm I can still connect. Write everything you changed, and how to reverse it, to SECURITY.md.

Inspired by Jonathan Shriftman: My First Experience with OpenClaw: Building an AI Agent for VC Workflows. The prompt above is written by playbooks.bot in our own words; nothing from the original is quoted.

What can go wrong?

  • Disabling root login before a user account with sudo exists can lock you out.
  • An agent can also open holes; review what it changes, not just what it reports.

Our take

Jonathan Shriftman got the order right. Most people setting up a personal agent rush to the fun features while a fresh server sits on the internet with default settings, and attackers scan for exactly those within hours. Asking the agent to harden its own home first, and to write down every change, costs pennies and closes the obvious doors. The documentation request is as important as the fixes, because six months from now you will need to know why a port is closed or how to log in. Two cautions. Keep a way back in that does not depend on SSH, such as the provider's web console, before letting an agent touch firewall or SSH settings, since a single wrong rule can lock everyone out. And do not combine disabling root login with creating your personal account in one step; confirm the new account works first. Review each proposed change before it applies, then repeat the audit monthly or after installing new services, since every addition can open something new.

Where the time goes back: Basic hardening that would mean hiring someone or a long tutorial session takes a short supervised conversation.

FAQ

What did it cost?
The author reports about thirty cents in API usage for the audit.
Why do this first?
Before the agent gets your data and accounts, the box it runs on should be locked down.

Source and credit

Inspired by Jonathan Shriftman. We describe the idea in our own words, link to the original, and wrote the prompt ourselves; nothing is quoted.

Inspired by
My First Experience with OpenClaw: Building an AI Agent for VC Workflows
Creator
Jonathan Shriftman
Published on
shriftman.substack.com (Substack)
Original date
Feb 9, 2026
License
Not openly licensed (the poster keeps all rights), so we quote nothing and link to the original
Originally for
OpenClaw
AI dry run
Oct 23, 2026: passed. Dry-run tested by our AI test agent on sample input. PASS: Gates held on desk check; no live sends or purchases.
AI dry run on sample data; not run with live connected accounts. The playbooks.bot test agent filled the prompt with synthetic inputs, produced the output and checked it against the page's stated outputs and guardrails.
Verified
Oct 23, 2026: source link resolves to the original, the credited creator published it, our excerpt or prompt matches it, and the license allows our use.

Are you the creator? Claim or correct this page.

More in IT & Security

All 82 IT & Security playbooks →

Related playbooks

IT & SecurityWorkflow✓ AI dry run

Fix a scheduled agent digest that never arrives

Get your scheduled digest delivered again by finding why the job returned nothing and switching off the setting that swallowed its output.

Credit: Alex Rezvov

Under an hour
IT & SecurityPrompt✓ AI dry run

Plan a least-privilege move of your agent's Google access

Get a written, reviewable plan for moving an agent's Gmail, Calendar and Drive access onto Google's agent interfaces, with the current setup kept as a fallback, read-only grants first, proof that writes fail, and no cutover until a side-by-side run is clean.

Credit: u/rlnerd on r/hermesagent

An afternoon+
IT & SecurityWorkflow✓ AI dry run

Route tracker tickets to the right repo by label

Send tasks from chat into one issue tracker and let labels decide which repository and which model a coding agent uses, ending in pull requests for review.

Credit: bibstha on Hacker News

An afternoon+
IT & SecurityWorkflow✓ AI dry run

Re-check agent work after you switch models

Before trusting a team of always-on agents on a new model, rerun a known task set and require proof of finished work, not status messages.

Credit: u/Affectionate_Bad7147 on r/openclaw

Under an hour
IT & SecurityWorkflow✓ AI dry run

Read an unknown compiled program with an agent's help

Understand an unknown compiled program when you barely know Ghidra, by letting an agent call it over MCP and explain what the code does.

Credit: Huli

An afternoon+