Lynis
$ lynis Official Low RiskLynis (lynis) is a POSIX shell security auditing tool for Linux, macOS, and BSD systems that inspects kernel settings, file permissions, installed packages, SSH/firewall configs, and malware indicators. Use --quick or --cronjob for non-interactive runs; results write to a key-value .dat report file rather than JSON.
brew install lynis lynis inspects local OS filesystems, sysctl values, and service configs directly on the target host.
Agent-Readiness Checklist
Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.
FCRS-1.0 6-Dimension Breakdown
Requires --quick or --cronjob to avoid interactive Enter pauses, lacks native JSON output, and writes an INI-style .dat report file.
- Supports
--quick,--cronjob, and--no-colors - No native
--jsonoutput; emits.datkey-value lines
Performs non-destructive read-only host checks while writing log and report files locally.
- Read-only system checks; only writes log/report output
POSIX shell script portable across Linux, macOS, and BSD via brew or distro packages, with no Windows support.
- Unix/Linux/macOS only; no Windows support
Broad host hardening baseline covering hundreds of OS checks in one pass, though verbose stdout slows agent triage.
- Hundreds of built-in OS hardening and compliance checks
Maintained by CISOfy (CISOfy/lynis) under GPL-3.0 for over a decade.
- Official
CISOfy/lynisupstream
Solid online documentation, though --help flag coverage is spread across subcommands and profiles.
- Official documentation at cisofy.com/documentation/lynis/
Security, Auth & Guardrails
No external credentials needed; root privileges (sudo) unlock deeper kernel and /etc permission checks.
GPL-3.0 open-source CLI; free for local host auditing (enterprise server management is paid).
# Lynis (lynis) Agent Rules - Always pass `--quick` (or `--cronjob`) and `--no-colors` so Lynis never pauses for Enter. - Write reports to an explicit `--report-file` path and parse `warning[]` / `suggestion[]` keys instead of scraping colored stdout.
Agent-Ready Command Recipes
Safe Read-Only Queries
lynis audit system --quick --no-colors --report-file /tmp/lynis-report.dat
Audits the local host without pausing on prompts (--quick), disables ANSI via --no-colors, and writes findings to /tmp/lynis-report.dat.
lynis audit system --cronjob --tests-from-group ssh
Limits checks to the ssh test group under silent --cronjob automation mode.
Strengths for Agents
- + Comprehensive, battle-tested Unix/Linux/macOS hardening audit with zero compilation needed.
- +
--tests-from-groupand--quickallow targeted, non-blocking execution.
Caveats & Pitfalls
- ! No JSON output—agents must parse
warning[]andsuggestion[]entries from the.datreport file. - ! Omitting
--quickor--cronjobcauses interactive pauses waiting for user keypresses; Windows is unsupported.