Directory Compare FCRS-1.0 /llms.txt
← Back to Directory

checksec

$ checksec Official Low Risk
slimm609 · Security & Secrets · BSD-3-Clause · macos / linux

checksec (checksec) inspects compiled ELF/Mach-O binaries, running processes, and kernel security flags for exploit mitigations such as RELRO, stack canaries, NX, PIE, Fortify, and RPATH/RUNPATH. Supports --output=json for zero-ambiguity machine parsing.

FCRS-1.0 Score
82 /100
Good
Medium Confidence
Zero-Friction Install
brew install checksec
CLI vs MCP Decision CLI Only

checksec inspects local compiled ELF/Mach-O artifacts directly via readelf/otool with structured --output=json.

Agent-Readiness Checklist

✓ JSON Output
— Field Filtering
✓ Non-Interactive
— Dry-Run
— Read-Only Mode
— NO_COLOR Clean
✓ Self-Describing
— Official SKILL.md

Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.

FCRS-1.0 6-Dimension Breakdown

Agent-Readiness 21 / 25

Clean --output=json mode (plus CSV/XML) and non-interactive flag invocation with zero prompts.

  • Native --output=json output on --file and --dir
  • Non-interactive execution
Trust & Safety 23 / 25

Strictly read-only header inspection using OS binutils without executing target binaries.

  • Purely static read-only metadata inspection
Setup & Portability 10 / 15

Bash script depending on host tools (readelf, file, otool, objdump), limited to Linux and macOS (no Windows).

  • Linux/macOS only; relies on host binutils/Xcode tools
Utility & Efficiency 12 / 15

Verifies compiler hardening flags across CI build outputs in a single command.

  • Checks RELRO, Canary, NX, PIE, RPATH, and Fortify together
Maintenance & Lineage 8 / 10

Maintained at slimm609/checksec under BSD-3-Clause (with recent Go/script evolution).

  • Canonical slimm609/checksec upstream
Docs & Verifiability 8 / 10

Clear README and --help covering output formats and target modes.

  • Well-documented flags on slimm609.github.io/checksec

Security, Auth & Guardrails

Auth Modes
No Auth
Credential Storage

No authentication credentials used; inspects local binaries and /proc read-only.

Side Effects
Read-Only
Cost & Quotas

BSD-3-Clause open-source CLI; free and offline.

Copyable Guardrail for CLAUDE.md / AGENTS.md
# checksec Agent Rules
- Always pass `--output=json` so mitigation fields are structured rather than ANSI-colored tables.
- Confirm target binaries match the host OS (`readelf` on Linux ELF; `otool` on macOS Mach-O).

Agent-Ready Command Recipes

Safe Read-Only Queries

Check a single binary's mitigations as JSON
checksec --output=json --file=./build/app

Audits ./build/app for RELRO, Canary, NX, PIE, and Fortify flags and emits clean JSON.

Audit all binaries in a build directory
checksec --output=json --dir=./build/bin

Recursively checks executables inside ./build/bin and outputs consolidated JSON results.

Strengths for Agents

  • + --output=json turns messy readelf/otool hardening checks into clean structured JSON.
  • + Purely static and read-only—never executes the inspected binary.

Caveats & Pitfalls

  • ! No Windows support; macOS Mach-O inspection covers fewer mitigation fields than Linux ELF.

Tested Agent Hosts

Claude Code Codex CLI Gemini CLI