-
Notifications
You must be signed in to change notification settings - Fork 2
Security
automoto edited this page Aug 1, 2026
·
1 revision
Report security issues privately. Do not open a public GitHub issue for a suspected vulnerability.
Contact: <security-contact> (replace with the project's disclosure address or a
GitHub private security advisory link).
Include the affected version or commit, a description, and steps to reproduce. You will get an acknowledgement while the fix is worked.
The server fails to boot in production if the core hardening config is missing, so the core items are enforced at boot. The rest is up to the operator.
- Set
JWT_SIGNING_KEY,EMAIL_VERIFY_SIGNING_KEY, andMETRICS_AUTH_TOKENexplicitly in production. Do not rely on the auto-generated keys, which live only in one database and are hard to rotate. - Mount secrets with the
<NAME>_FILEform rather than passing them inline where you can. - Back up Postgres. It holds the
server_secretstable, so losing it loses the signing keys.
-
TWO_FACTOR_ENC_KEYencrypts TOTP secrets at rest. Setting it pins the key so it is not tied to one database. - Changing or removing it after players enroll locks those logins out until the prior key is restored. Rotate deliberately, and keep the old key as a decrypt fallback during a rotation.
- Terminate TLS in front of the server. The server itself speaks plain HTTP.
- In production set
CONTROL_PANEL_COOKIE_SECURE=trueandCONTROL_PANEL_BASE_URLonhttps://.
- Give each API key the narrowest scope that covers its job. Keep server-tier keys (
fleetand server scopes) separate from client keys. - Point
DATABASE_URLat a least-privilege login role and use a separateDB_MIGRATE_URLfor the migration role that runs DDL.
- Set
CORS_ALLOWED_ORIGINSto your real origins with no*. - Only trust a forwarded-IP header from your own proxy: set
TRUSTED_PROXY_HEADERtogether withTRUSTED_PROXY_CIDRS. - Token-gate
/metricswithMETRICS_AUTH_TOKEN, or disable auth on it on purpose withMETRICS_AUTH_DISABLED=true. - If you enable the entitlement API (
ENTITLEMENT_API_ENABLED), bind or firewall it to a private network. It is off by default.
See Configuration Reference for every variable named here.