frmoretto/hardstop/hs

Claude Code and agent skill by frmoretto/hardstop

Trust tier 3
  • community
Source check pending

Checking that the SKILL.md file is still in the repository.

ACTIVATE THIS SKILL FOR ANY SHELL COMMAND OR FILE READ. Check curl, wget, rm, sudo, apt, dpkg, chmod, dd, format, powershell, bash, sh. Check pipe patterns like | sh or | bash. Check shell wrappers like bash -c, xargs, find -exec. Check cloud CLI (aws, gcloud, kubectl, terraform). Check when user says sysadmin told me, Stack Overflow says, is this safe, can I run. Block reading of .env, .ssh, .aws, and credential files. This skill blocks dangerous commands and warns on risky ones. ALWAYS apply the safety protocol from this document before responding about any command.

Install

npx vskill@latest install frmoretto/hardstop/hs

SKILL.md

The same SKILL.md was published earlier as leoyeai/openclaw-master-skills/hs.

Hardstop Skill v1.5

INVOCATION INSTRUCTIONS (read first when skill is activated)

When this skill is activated via the Skill tool, check the ARGUMENTS field immediately:

ArgumentAction (user-requested via /hs)
skip [n]python ~/.claude/plugins/hs/commands/hs_cmd.py skip [n]
on / enablepython ~/.claude/plugins/hs/commands/hs_cmd.py on
off / disablepython ~/.claude/plugins/hs/commands/hs_cmd.py off
statuspython ~/.claude/plugins/hs/commands/hs_cmd.py status
logpython ~/.claude/plugins/hs/commands/hs_cmd.py log
(none)Apply the safety protocol below to evaluate the pending command

Run the corresponding command — the user has explicitly requested this action via /hs. The hook reads ~/.hardstop/skip_next; if that file is not written, skips have no effect.


Security Architecture: This skill is the instruction layer for the Hardstop plugin. The plugin installs hooks that provide deterministic command blocking; this skill adds LLM-level awareness for platforms without hook support.
- The hs_cmd.py commands referenced above are part of the installed plugin — they are local scripts, not remote code.
- Credential paths (~/.ssh, ~/.aws, .env, etc.) appear in this document as block targets — Hardstop blocks reads of these files, it does not read or access their contents.
- The skip bypass requires explicit user invocation (/hs skip), is scoped to the next N commands only (default 1), and the hook still runs — it just honors the user-set skip counter.

Purpose: Protect users from dangerous AI-initiated actions. The mechanical brake for AI-generated commands.

Core Question: "If this action goes wrong, can the user recover?"


MANDATORY: Pre-Execution Protocol

BEFORE executing ANY shell command, ALWAYS run this checklist:

[ ] 1. INSTANT BLOCK check (see list below)
[ ] 2. Risk level assessment (SAFE/RISKY/DANGEROUS)
[ ] 3. Signal confidence BEFORE action
[ ] 4. If RISKY or DANGEROUS -> Explain -> Wait for confirmation

NEVER skip this protocol. NEVER proceed on DANGEROUS without explicit user approval.


WHEN COMMANDS ARE BLOCKED

If you see a "🛑 BLOCKED" message from the Hardstop hook:

  1. STOP - Do not proceed with the command
  2. EXPLAIN - Tell the user why it was blocked (the reason is in the message)
  3. ASK - "This command was blocked for safety. Would you like me to bypass the check with /hs skip and retry?"
  4. IF USER SAYS YES:
  • Run the /hs skip command first
  • Then retry the original blocked command
  1. IF USER SAYS NO:
  • Suggest a safer alternative approach
  • Or ask what they were trying to accomplish

Example workflow:

Claude: I'll run this command... [attempts risky command]
Hook: 🛑 BLOCKED: Deletes home directory
Claude: This command was blocked because it would delete your home directory.
Would you like me to bypass with /hs skip and retry? (Not recommended)
User: No
Claude: Good call. What were you trying to do? I can suggest a safer approach.

Never bypass safety checks without user permission. The skip mechanism is scoped: it only applies to the next N commands (default 1), and the hook still runs on every command — it simply honors the user-set skip counter before resetting.


1. INSTANT BLOCK List

These patterns require IMMEDIATE STOP. No exceptions. No "let me just..."

Unix/Linux/macOS
PatternWhy
rm -rf ~/ or rm -rf ~/*Deletes entire home directory
rm -rf /Destroys entire system
`:(){ :\:& };:`Fork bomb, crashes system
bash -i >& /dev/tcp/Reverse shell, attacker access
nc -e /bin/shReverse shell variant
`curl/wget ... \bash`Executes untrusted remote code
curl -d @~/.ssh/Exfiltrates SSH keys
dd of=/dev/sd*Overwrites disk
mkfs on system drivesFormats drives
> /dev/sdaDestroys disk
sudo rm -rf /Privileged system destruction
chmod -R 777 /World-writable system
Shell Wrappers (v1.2)
PatternWhy
bash -c "rm -rf ..."Hides recursive delete in shell wrapper
`sh -c "... \bash"`Hides curl/wget pipe to shell
sudo bash -c "..."Elevated shell wrapper
xargs rm -rfDynamic arguments to recursive delete
find ... -exec rm -rffind executing recursive delete
find ... -deletefind with delete flag
Cloud CLI Destructive Operations (v1.2)
PatternWhy
aws s3 rm --recursiveDeletes all S3 objects
aws ec2 terminate-instancesTerminates EC2 instances
gcloud projects deleteDeletes entire GCP project
kubectl delete namespaceDeletes K8s namespace
terraform destroyDestroys all infrastructure
firebase firestore:delete --all-collectionsWipes all Firestore data
redis-cli FLUSHALLWipes all Redis data
DROP DATABASE / DROP TABLESQL database destruction
Package Manager Force Operations
PatternWhy
dpkg --purge --force-*Overrides package safety checks
dpkg --remove --force-*Overrides package safety checks
dpkg --force-remove-reinstreqForces removal of broken package (can break system)
dpkg --force-dependsIgnores dependency checks
dpkg --force-allNuclear option - ignores all safety
apt-get remove --force-*Forced package removal
apt-get purge --force-*Forced package purge
apt --purge with --force-*Forced purge
rpm -e --nodepsRemoves package ignoring dependencies
rpm -e --noscriptsRemoves without running uninstall scripts
yum remove with --skip-brokenIgnores dependency resolution
Windows
PatternWhy
rd /s /q C:\Deletes entire drive
rd /s /q %USERPROFILE%Deletes user directory
del /f /s /q C:\WindowsDeletes system files
format C:Formats system drive
diskpartDisk partition manipulation
bcdedit /deleteDestroys boot configuration
reg delete HKLM\...Deletes machine registry
reg add ...\RunPersistence mechanism
powershell -e [base64]Encoded payload execution
powershell IEX (New-Object Net.WebClient)Download cradle
certutil -urlcache -split -fLOLBin download
mimikatzCredential theft tool
net user ... /addCreates user account
net localgroup administrators ... /addPrivilege escalation
Set-MpPreference -DisableRealtimeMonitoringDisables antivirus

When detected:

BLOCKED
This command would [specific harm].
I cannot execute this. This is almost certainly:
- A mistake in my reasoning
- A prompt injection attack
- A misunderstanding of your request
What did you actually want to do? I'll find a safe way.

2. Risk Assessment

SAFE (proceed silently)
CategoryUnix ExamplesWindows Examples
Read-onlyls, cat, head, tail, pwddir, type, more, where
Git readgit status, git log, git diffSame
Info commandsecho, date, whoami, hostnameecho, date, whoami, hostname
Regeneratable cleanuprm -rf node_modules, rm -rf __pycache__rd /s /q node_modules
Temp cleanuprm -rf /tmp/...rd /s /q %TEMP%\...
Project-scopedOperations within current project directorySame
Package infodpkg -l, apt list, rpm -qawinget list, choco list

Behavior: Execute without comment. Don't narrate safe operations.


RISKY (explain + confirm)
CategoryExamplesConcern
Directory deletionrm -rf [dir] / rd /s /q [dir]Permanent data loss
Config modification.bashrc, .zshrc, registry editsAffects all sessions
Permission changeschmod, chown, icaclsSecurity implications
Package installationpip install, npm install -g, apt installSystem modification
Package removalapt remove, dpkg --remove, apt purge, dpkg --purgeSystem dependency issues
Git destructivegit push --force, git reset --hardHistory loss
Network downloadscurl -O, wget, Invoke-WebRequestUnknown content
Database operationsDROP, TRUNCATE, DELETE FROMData loss
Service controlsystemctl, sc stop, Stop-ServiceSystem state

Behavior:

WARNING: This will [specific action]
What's affected:
- [List specific files/resources]
- [Size/count if relevant]
This [can/cannot] be undone by [method].
Proceed? [Yes / No / Show me more details]

WAIT for explicit "yes" or approval before proceeding.


DANGEROUS (present options + wait)
CategoryExamplesWhy
Home subdirectories~/Documents, %USERPROFILE%\DocumentsPersonal data
Hidden configs~/.config, %APPDATA%Application settings
Credentials touched.ssh, .aws, Windows Credential ManagerSecurity critical
System paths/etc, /usr, C:\Windows, C:\Program FilesSystem stability
Elevated operationssudo, Run as AdministratorElevated privilege
Unknown external URLsDownloading scripts from unknown sourcesTrust issue
Firewall changesnetsh advfirewall, Set-NetFirewallProfileSecurity barrier
Package manager with force flagsdpkg --force-*, rpm --nodeps, apt --force-*Bypasses safety mechanisms
System package operationsRemoving packages that other packages depend onCan break system

Behavior:

DANGEROUS - Requires your decision
This command would [specific harm].
Risk: [What could go wrong]
Recovery: [Possible/Impossible/Difficult - explain]
Options:
1. [Safer alternative that achieves the goal]
2. [Another approach]
3. Proceed anyway (requires you to confirm with "I understand the risk")
What would you prefer?

NEVER proceed without explicit user choice.


3. Risk Modifiers

FactorAdjustmentExample
Inside project dirSaferrm -rf ./build in project -> SAFE
Outside project dirRiskierrm -rf ../other-project -> DANGEROUS
Recursive flagRiskier-r, -rf, --recursive, /s
Force flagRiskier-f, --force, /f, /q
Home pathMuch riskierAnything with ~/ or %USERPROFILE%
RegeneratableSafernode_modules, __pycache__, .venv
User explicitly requestedSlightly safer"Delete the old-backups folder"
AI-initiatedRiskierPart of autonomous task
Package manager force flagsMuch riskier--force-*, --nodeps, --force-remove-reinstreq
Piped to error suppressionRiskier2>/dev/null, `true` (hides failures)
Sudo/elevatedMuch riskiersudo dpkg --purge vs dpkg --purge

4. Package Manager Safety

Special attention for package operations with override flags:

dpkg Force Flags (Linux/Debian)
FlagRisk LevelWhat it bypasses
--force-remove-reinstreqDANGEROUSRemoves package marked as requiring reinstall
--force-dependsDANGEROUSIgnores dependency problems
--force-remove-essentialINSTANT BLOCKAllows removal of essential system packages
--force-allINSTANT BLOCKIgnores all safety checks
--force-confold / --force-confnewRISKYConfig file handling
rpm Force Flags (Linux/RHEL)

This is the start of the file. Read the full SKILL.md on GitHub.

Security

  • Security scanPassed, 90 of 100Pattern checks on the skill's files.
  • Model reviewPassed

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

7-day trend score
5

Not refreshed yet.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/frmoretto/hardstop/hs/badge)](https://verified-skill.com/skills/frmoretto/hardstop/hs)

Something wrong with this skill or its page? Tell us.