Lesson 9 of 9 · 21m
Shipping Internal Tools: Packaging, Rollout, and Adoption
A tool survives when it is installable, documented, owned, safe by default, and shaped by the people who use it under pressure.
Security teams are full of abandoned automation: a repo with no owner, a cron job on a forgotten VM, a README last edited before a reorg. Shipping a tool is not publishing code; it is making the tool operable by someone who did not write it, during an incident, at night.
Package the tool like software
Python packaging does not need to be elaborate, but it does need to be real. Use a virtual environment, pin direct dependencies, expose a console entry point, and keep runtime configuration out of the package.
[project]
name = "secscan"
version = "1.4.0"
description = "Scanner ingestion and finding normalization utilities"
requires-python = ">=3.11"
dependencies = ["httpx>=0.27,<0.29", "pydantic>=2.7,<3"]
[project.scripts]
secscan = "secscan.cli:main"A console entry point means analysts run secscan, not python /opt/secops/tools/secscan/src/main.py. Version numbers matter because incident timelines need to know which behavior ran.
Documentation is operational, not aspirational
The README should answer the questions people have under stress: what it does, what it touches, how to install it, how to run a safe test, how to roll back, and where logs go.
## Safe smoke test
export SCANNER_API_TOKEN=...
secscan import sample-data/nmap.xml --dry-run --json
Expected result: exit code 0, summary includes parsed_hosts > 0 and writes = 0.Include one realistic sample input and exact expected output. A sanitized Nmap XML file teaches more than a paragraph of abstract instructions ever will.
Roll out in stages and assign ownership
Start read-only. Compare automation output against human judgment. Then enable limited actions behind approval.
stage 1: parse and report only
stage 2: create tickets, no containment actions
stage 3: reversible actions for low-criticality assets
stage 4: broader actions with approval and expirationEach stage needs a measurable exit condition: parse accuracy, duplicate rate, analyst time saved, rollback success, or incident volume. Every tool also needs an owner, escalation path, and maintenance cadence; if the team cannot patch it, the tool is technical debt with root privileges.
Field notes
- Provide
--version,--dry-run, and verbose mode from day one. - Keep a changelog; internal users need to know why behavior changed before they assume malware did it.
- Store sample input and expected output in the repo — they are documentation and regression tests.
- Decommission old scripts explicitly; a zombie cron job is worse than no automation.
- The final test is not whether automation saves time on a good day, but whether it reduces confusion on a bad one.
Was this lesson helpful?