Hunting persistence on linux

From meltedinhex/analyst-ai-pack · View interactive version

Hunting persistence on linux is an AI agent skill from the GitHub repository meltedinhex/analyst-ai-pack. Hunts for Linux persistence by inspecting cron, systemd units, shell rc files, SSH authorized_keys, and common autostart locations for attacker-added entries. Activates for requests to hunt Linux persistence, audit cron/systemd for backdoors, or find unauthorized autostart and authorized_keys entrie

How to use this skill

Skill file

Hunting Persistence on Linux

When to Use

files, authorized_keys, autostart) and want to flag suspicious entries.

Do not use this on a live root shell as a substitute for proper IR collection — feed it

collected copies. It reads files statically and executes nothing.

Prerequisites

Safety & Handling

Workflow

Step 1: Scan persistence files

python scripts/analyst.py scan /path/to/collected

Recursively scans known persistence locations and flags entries containing download/exec patterns

(curl|wget ... | sh, base64 -d | bash, reverse-shell one-liners, nc -e), suspicious paths

(/tmp, /dev/shm), and unexpected authorized_keys additions.

Step 2: Categorize by mechanism

Group findings by mechanism: cron, systemd, rc/profile, SSH keys, autostart.

Step 3: Confirm

Compare against a known-good baseline of expected services/keys; investigate deviations.

Step 4: Document

Record each persistence entry, its mechanism, and the suspicious indicator.

Validation

Pitfalls

References

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.