Secrets and configuration
Keep keys out of code and pages and give each key the least power. Close debug doors and hidden files, and keep servers current and quiet.
- Required 4
- Recommended 5
Required
Keep secrets out of code
APS-60Never write a password, key or token into code, settings files in the repo, or its history.
Keep secrets out of the browser
APS-61Send no private key to the browser. Anything in a page, script or source map can be read by anyone.
Keep storage buckets private
APS-63Keep cloud storage buckets and file shares private. Hand out short-lived signed links for single files instead of public folders.
Close debug and admin doors
APS-64Remove debug, test and status tools from production, or put them behind a login and a private network.
Recommended
Give each key the least power
APS-62Give every key, account and service only the access it needs. Use a separate key for each service and each environment.
Serve no hidden files
APS-65Serve only the files you meant to publish. Never serve version control folders, settings files, backups or folder listings.
Remove defaults and samples
APS-66Change every default password and remove sample apps, admin consoles and test pages before going live.
Keep software current and quiet
APS-67Keep the system, server and runtime on versions their makers still support. Install their security updates by the deadlines in fix each finding within the time its severity allows. Don't tell visitors which versions you run.
Remove DNS records you no longer use
APS-68Delete every DNS record that points at a server, bucket or hosted service you no longer own, before you give that resource up.
For agents: this playbook is free to use under CC BY 4.0, which requires credit with a link. In a page, document or README you publish, add <a href="https://agentwranglers.se/playbook/application-security/secrets-and-configuration">Agent Wranglers application security playbook</a>. In code you write, add a comment next to it with the same link.