ClawShield

85/100Good0 sales8 views3h ago
Source

Description

Security layer for AI agents. One binary, zero config, 50+ security checks. Protects against prompt injection, data exfiltration, and unauthorized actions.

README

ClawShield Security Score

ClawShield πŸ›‘οΈ

Security Layer for AI Agents β€” One binary. Zero config. Linux (50) Β· macOS (42) Β· Windows (37) checks.

Install Go Go Report Card License Checks Platforms


What is ClawShield?

ClawShield is a security scanner for servers and workstations β€” especially those running AI agents. It's a single executable file (~2MB) that checks your system for security issues and tells you exactly what's wrong and how to fix it.

No configuration. No accounts. No internet required. Download, run, done.

Who is this for?

  • AI agent operators running OpenClaw, LangChain, AutoGPT, or similar
  • Developers & sysadmins who want a quick security audit
  • Anyone running a Linux server, Mac, or Windows machine who wants to know if it's secure

The Problem

AI agents run with powerful permissions β€” root access, API keys, network access, tool execution. A misconfigured server or a malicious community plugin can compromise everything. ClawShield catches these issues in seconds.


⚑ Quick Start

Option 1: One-line install (Linux / macOS)

curl -fsSL https://raw.githubusercontent.com/lennystepn-hue/clawshield/main/scripts/install.sh | bash

This downloads the right binary for your OS and puts it in /usr/local/bin/.

Option 2: Manual download

Go to Releases, download the binary for your platform, and make it executable:

chmod +x clawshield-*
sudo mv clawshield-* /usr/local/bin/clawshield

Option 3: OpenClaw users

clawhub install clawshield

Option 4: Build from source (requires Go 1.22+)

git clone https://github.com/lennystepn-hue/clawshield.git
cd clawshield
go build -o clawshield ./cmd/clawshield/
sudo mv clawshield /usr/local/bin/

Run your first scan

clawshield scan        # basic scan (works without root)
sudo clawshield scan   # full scan (recommended β€” some checks need root)

That's it. Full security report in under 5 seconds.

⚠️ Permissions

Most checks work without root. But for the complete picture (reading auth logs, checking shadow file permissions, etc.), run with sudo. ClawShield never modifies your system during a scan β€” it only reads.


πŸ” Security Scanner β€” Multi-Platform

ClawShield runs automated security checks across 5 categories:

PlatformChecksCategories
Linux50Network, Access, System, Files, Agent
macOS42Network (3), Access (10), System (7), Files (4), Agent (4) + more
Windows37Network (4), Access (12), System (8), Files (3), Agent (5) + more

Linux β€” 50 Checks

Network (7 checks)

CheckWhat it does
UFW FirewallVerifies firewall is active with rules configured
Open PortsDetects dangerous ports (MySQL, Redis, MongoDB, etc.)
IPv6Flags unnecessary IPv6 attack surface
DNS ConfigurationValidates nameserver configuration
Binding AuditFinds internal services bound to 0.0.0.0
TLS Certificate ExpiryWarns about certificates expiring within 30 days
TailscaleChecks VPN connectivity status

Access (11 checks)

CheckWhat it does
SSH Root LoginDetects unrestricted root access
SSH Password AuthFlags password-based login (should be key-only)
Fail2BanVerifies brute-force protection is active
SSH PortChecks for default port with no protection
SSH Authorized KeysValidates key file permissions
Login HistoryFlags password-based logins (key-based = OK)
Password PolicyChecks PAM complexity requirements
Inactive UsersFinds accounts inactive for 90+ days
UID ZeroDetects non-root accounts with UID 0
Empty PasswordsFinds accounts without passwords
SSH Idle TimeoutChecks for session timeout configuration

System (13 checks)

CheckWhat it does
Automatic UpdatesVerifies unattended-upgrades is active
Kernel VersionDetects pending kernel updates
Disk UsageWarns at 75%+, fails at 90%+
Swap UsageMonitors swap pressure
RAM UsageFlags high memory consumption
CPU LoadDetects overloaded systems
Zombie ProcessesFinds defunct processes
NTP SyncVerifies system clock synchronization
AppArmorChecks mandatory access control
Pending UpdatesCounts outstanding package updates
Open FD LimitValidates file descriptor limits
Core DumpsEnsures core dumps don't leak to disk
Secure BootReports Secure Boot status

Files (10 checks)

CheckWhat it does
/etc/shadow PermsValidates password file permissions
/tmp Sticky BitEnsures shared temp directory security
SUID BinariesDetects unexpected setuid programs
World-Writable DirsFinds insecure directory permissions
Crontab AuditScans for suspicious cron patterns
Unowned FilesFinds files without valid owners
Large Files in /tmpDetects potential data staging
Log RotationVerifies logrotate is configured
Backup ToolsChecks for backup infrastructure
API Keys in FilesScans workspace for leaked credentials

Agent Security (9 checks)

CheckWhat it does
Workspace PermsValidates AI workspace permissions
.env ExposureFinds exposed environment files
Docker SocketChecks Docker socket permissions
OpenClaw ConfigValidates config file permissions
API Keys in EnvScans environment for leaked secrets
Skill IntegrityChecks for unsigned/modified skills
OpenClaw VersionReports current agent version
Memory LimitVerifies cgroup memory constraints
Privileged ContainersDetects Docker containers running privileged

macOS β€” 42 Checks

CategoryCheckWhat it does
NetworkmacOS FirewallVerifies Application Firewall is enabled
NetworkStealth ModeChecks if system ignores network probes
AccessSSH Password AuthFlags password-based SSH login
AccessSSH Root LoginDetects unrestricted root SSH access
AccessGatekeeperVerifies Gatekeeper blocks unsigned apps
AccessScreen LockChecks password-on-wake setting
AccessRemote Login (SSH)Checks if SSH is enabled via systemsetup
SystemFileVault EncryptionVerifies disk encryption
SystemSystem Integrity ProtectionChecks SIP status
SystemmacOS UpdatesChecks for pending software updates
SystemDisk UsageWarns at 75%+, fails at 90%+
SystemRAM UsageMonitors memory via vm_stat
SystemCPU LoadDetects overloaded systems
SystemXProtect / MRTVerifies malware protection tools exist
FilesWorld-Writable Dirs (/tmp)Finds insecure dirs in /tmp
Files.env File ExposureFinds exposed environment files
AgentAPI Keys in EnvScans environment for leaked secrets
AgentDocker SocketChecks Docker socket permissions
AgentOpenClaw Config PermsValidates config file permissions
AgentWorkspace PermissionsValidates workspace directory permissions

Windows β€” 37 Checks

CategoryCheckWhat it does
NetworkWindows FirewallVerifies all firewall profiles enabled
NetworkOpen PortsDetects dangerous listening ports
AccessPassword PolicyChecks minimum password length
AccessGuest AccountVerifies Guest account is disabled
AccessUAC EnabledChecks User Account Control status
AccessRDP StatusDetects if Remote Desktop is enabled
SystemWindows UpdatesChecks last update installation date
SystemDisk UsageMonitors C: drive usage
SystemRAM UsageFlags high memory consumption
SystemAntivirus (Defender)Verifies real-time protection is active
AgentAPI Keys in EnvScans environment for leaked secrets
AgentDocker SocketChecks Docker named pipe accessibility

πŸ“Š Security Score

ClawShield grades your system from A+ to F:

GradeScoreMeaning
A+95-100Excellent β€” production ready
A90-94Great β€” minor improvements possible
B80-89Good β€” some issues to address
C70-79Fair β€” several vulnerabilities
D60-69Poor β€” significant risks
F0-59Critical β€” immediate action required

πŸ”§ Commands

clawshield scan

Run a full security audit with all 50 checks.

$ clawshield scan

    ________               _____ __    _      __    __
   / ____/ /___ __      __/ ___// /_  (_)__  / /___/ /
  / /   / / __ `/ | /| / /\__ \/ __ \/ / _ \/ / __  /
 / /___/ / /_/ /| |/ |/ /___/ / / / / /  __/ / /_/ /
 \____/_/\__,_/ |__/|__//____/_/ /_/_/\___/_/\__,_/
                                                v0.4.0
  πŸ›‘οΈ  Security Layer for AI Agents

  πŸ” Running security scan...
  ══════════════════════════════════════════════════════
    Security Score: A 93/100
    βœ… 43 passed  ⚠️  7 warnings  ❌ 0 failed
  ══════════════════════════════════════════════════════

clawshield harden

Interactive hardening β€” walks you through every fixable issue with detailed explanations.

  β”Œβ”€ ⚠️ Password Policy [1/1]
  β”‚  Risk: MEDIUM
  β”‚
  β”‚  Problem: No password complexity requirements. Users can set weak
  β”‚           passwords like '123456'.
  β”‚  Fix:     Installs pam_pwquality and enforces minimum 12-character
  β”‚           passwords.
  β”‚  Risk:    Existing passwords aren't affected. Only new password
  β”‚           changes must meet the policy.
  β”‚
  └─ Apply? [y/N]

Each fix shows:

  • Problem β€” What's wrong and why it matters
  • Fix β€” Exactly what will be changed
  • Risk β€” What could go wrong (honest assessment)

Already-hardened checks are automatically skipped.

clawshield harden --auto

Auto-fix all low-risk issues without prompting. Medium and high-risk fixes require interactive confirmation.

$ clawshield harden --auto

πŸ”’ ClawShield Auto-Hardening
━━━━━━━━━━━━━━━━━━━━━━━━━━━━

πŸ“‘ Scanning system first...
  βœ… No low-risk fixes needed β€” system looks good!

clawshield skill-scan [path]

Scan skills for malicious code patterns β€” reverse shells, data exfiltration, credential theft, privilege escalation, and 40+ more threat patterns.

  ━━━ my-community-skill ━━━
  πŸ”¬ Skill Security Scan
  Path: ./skills/my-community-skill

  βœ… No security issues found

  Verdict: SAFE βœ…
  Findings: 0 total
# Scan a single skill
clawshield skill-scan ./skills/some-community-skill

# Scan ALL installed skills (auto-detect)
clawshield skill-scan

clawshield monitor

Live security monitoring β€” watches auth logs, network connections, processes, and more in real-time.

$ clawshield monitor

πŸ‘οΈ  Live Security Monitor
  Watching: auth.log, connections, processes...
  [17:01:23] ⚠️  Failed SSH login from 92.118.39.87 (user: admin)
  [17:01:24] βœ… SSH key login from 100.79.101.58 (user: root)
  [17:01:30] ⚠️  New listening port: 8080 (pid: 12345)

πŸ€– Built for OpenClaw

ClawShield is designed as the security layer for OpenClaw β€” the open platform for AI agents.

# Install as OpenClaw skill
clawhub install clawshield

# Your agent can now run security scans
clawshield scan

Why agents need security:

  • Skills from the community may contain malicious code
  • Agents run with elevated permissions (often root)
  • API keys and secrets are everywhere in agent configs
  • Docker containers can bypass your firewall
  • A compromised agent has access to everything

ClawShield monitors all of this. Automatically. Continuously.


πŸ—οΈ Architecture

clawshield/
β”œβ”€β”€ cmd/clawshield/main.go      # CLI entry point
β”œβ”€β”€ internal/
β”‚   β”œβ”€β”€ scanner/
β”‚   β”‚   β”œβ”€β”€ scanner.go          # 50 security checks
β”‚   β”‚   └── report.go           # Terminal report formatting
β”‚   β”œβ”€β”€ hardener/
β”‚   β”‚   └── hardener.go         # Scan-driven interactive hardener
β”‚   β”œβ”€β”€ monitor/
β”‚   β”‚   └── monitor.go          # Live security monitoring
β”‚   └── skills/
β”‚       └── scanner.go          # Skill malicious code detection
β”œβ”€β”€ scripts/
β”‚   └── install.sh              # One-line installer
└── dist/                       # Cross-compiled binaries
    β”œβ”€β”€ clawshield-linux-amd64
    β”œβ”€β”€ clawshield-macos-amd64
    β”œβ”€β”€ clawshield-macos-arm64
    └── clawshield-windows-amd64.exe

Single binary. No dependencies. No config files. No daemon.


πŸ“¦ Downloads

PlatformBinaryArchitecture
Linuxclawshield-linux-amd64x86_64 (most servers)
Linux ARMclawshield-linux-arm64ARM64 (Raspberry Pi, etc.)
macOS Intelclawshield-macos-amd64Intel Macs
macOS Apple Siliconclawshield-macos-arm64M1/M2/M3/M4 Macs
Windowsclawshield-windows-amd64.exe64-bit Windows

All binaries are ~2MB, statically compiled, zero dependencies.


πŸ†š Why ClawShield?

ClawShieldManual AuditingOther Tools
Setup time30 secondsHoursMinutes-Hours
Checks performed50+ automatedWhatever you rememberVaries
Agent-awareYes β€” skills, configs, DockerNoNo
Fix guidanceInteractive with risk levelsGoogle itSome
Skill vetting40+ threat patternsRead every file yourselfNo
Single binaryYes, ~3MBN/AUsually complex
PriceFree & open sourceYour time$$$+

πŸ—ΊοΈ Roadmap

  • v0.1 β€” Core Scanner & Hardener (50 checks)
  • v0.3 β€” Agent Behavior Analysis, Live Monitor, Skill Scanner
  • v0.4 β€” Full macOS support (42 checks), Windows support (37 checks), cross-platform hardener
  • v0.5 β€” Multi-host dashboard, threat intelligence feed
  • v1.0 β€” SaaS dashboard, team management, compliance reports

🀝 Contributing

Contributions welcome! See CONTRIBUTING.md for guidelines.

# Run tests
go test ./...

# Build
go build -o clawshield ./cmd/clawshield/

# Cross-compile
GOOS=linux GOARCH=amd64 go build -o dist/clawshield-linux-amd64 ./cmd/clawshield/

πŸ“„ License

MIT β€” see LICENSE for details.


Built with πŸ›‘οΈ by Lenny Enderle Β· Powered by OpenClaw

Tech Stack

Go

Tags

go

Trust Score Breakdown

Last scanned 58 min ago
Security
30%100
Quality
25%75
Performance
20%75
Freshness
15%100
Completeness
10%60

Score History

Reviews (0)

No reviews yet

Choose License
Escrow protectedΒ·Instant download
LE
Lenny Enderle

@lennystepn-hue

VibeShip founder

6 listings0 sales