Skip to main content

Command menu

Jump to a page or search the catalog

AI Tools & Scripts

systemd Unit Check

Check systemd unit files before you install them: passwords in Environment=, programs run from /tmp, apps running as root with no sandboxing, missing hardening, CAP_SYS_ADMIN, and curl | bash run at every start.

$5.00

What you get: 1 file · 28.29 KB · ZIP

See purchase options

Product description

Environment=DB_PASSWORD=... in a unit file can be read by any user on the server with systemctl show, and a Node or Python app started without a User= line runs as root. This skill finds those and four other systemd unit mistakes before you install the unit, and tells you how to fix each one.

Your agent runs a scanner on your .service, .socket and .timer files, the drop-in overrides in <unit>.d/*.conf (what systemctl edit writes) and templates such as myapp.service.j2. It reads units the way systemd does: comment lines, backslash continuations, ExecStart= prefixes such as - and +, sh -c scripts, and drop-ins applied in order so a later User= wins. It tells your own applications apart from the programs Linux distributions ship, so stock units such as ssh, nginx, cron and docker are not reported. It never runs systemctl or the unit's commands. It returns BLOCK, REVIEW, or NOT FLAGGED, with the file, line, reason, and a safer approach. Secrets are never printed.

What it checks

BLOCK (fix before shipping)

  • U01: passwords, tokens and keys in Environment=, SetCredential=, URLs and command-line flags

  • U02: programs, scripts or environment files in /tmp, /var/tmp or /dev/shm

REVIEW (check before release)

  • U11: applications running as root with no sandboxing (no User=, User=root, or a + prefix)

  • U12: application services with none of NoNewPrivileges, ProtectSystem, ProtectHome and PrivateTmp

  • U13: ambient capabilities close to root, such as CAP_SYS_ADMIN or CAP_DAC_OVERRIDE

  • U14: curl | bash and downloaded programs run each time the service starts

What's included

  • The scanner (Python 3.9+, standard library only)

  • A rules guide with the reason and safer approach for each rule

  • A risky and a safe example project, and the real report the scanner produces on the risky one

Limits

It reads unit text, not the server: drop-ins and environment files outside the scanned folder, template logic, file ownership and what the program does after it starts are not checked. Agents that really need root (backup or monitoring tools in /opt or /usr/local) are reported for review. NOT FLAGGED is not a guarantee.

Contents

One ZIP file with 16 files: SKILL.md, the scanner in scripts/ (3 Python files), references/rules.md (every rule with its reason and safer approach), and examples/ (10 example files plus report.md, the real scanner output on the risky example).

How to use: This is an agent skill: a folder with a SKILL.md file and Python scripts that an AI coding agent such as Claude Code, Cursor, or Codex CLI can run. Unzip it into your agent's skills folder (for Claude Code: ~/.claude/skills/), then ask your agent to check your project. The scripts also run on their own with Python 3.9 or newer, with nothing to install. They read your files only: no network access, and nothing is sent anywhere.

What you get

1 file · 28.29 KB

  • systemd-unit-check-1.0.0.zipZIP · 28.29 KB

Included in Getly ProGet Pro

LicenseCommercial use allowed
PublishedNov 11, 2026
File size28.29 KB
File formatZIP
Versionv1.0

Tags

systemdlinuxserver-hardeningsecuritydevopsai agent skill
R
RR HH

Frequently asked questions

Do I get access instantly?

Yes. This is a digital product - you can download it right after checkout, straight from your library.

Can I use it for commercial projects?

Yes. Commercial use is allowed: use it in your own business and in things you sell. You may not resell or redistribute the file itself.

What's your refund policy?

You can request a refund within 30 days. If something isn't right, request it from your order and the Getly team reviews it.

What file formats and sizes will I get?

You'll download 1 file - ZIP - 28.29 KB in total.

Do I get free updates?

Yes - when the seller ships a new version, you can re-download the latest files from your library at no extra cost. Check the changelog for recent updates.

Price

$5.00