Flag the dev admin token as insecure at startup#198
Open
LiorFink00 wants to merge 1 commit into
Open
Conversation
THUMPER_ADMIN_TOKEN stays fail-closed (no code default), but .env.example ships an obvious 'dev-admin-token' value that insecure_default_tokens() did not flag - so a prod deploy copying it ran with a publicly-known admin token and no startup warning. Recognize that value alongside the enroll/install dev defaults; an unset token still disables the API (503). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016X1cbU86GceaeEGU3trGyB
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #197.
THUMPER_ADMIN_TOKENis fail-closed (no code default — unset disables the management API with a 503). But.env.exampleships an obviousdev-admin-token, andinsecure_default_tokens()only checked the enroll/install defaults, so a deploy copying the example ran with a publicly-known admin token and no startup warning.config.py: recognizedev-admin-token(the.env.examplevalue) as a known-insecure default and flag it, exactly like enroll/install. An unset token still fails closed — this adds no code default..env.example: note the value is publicly known and flagged at startup.336 passed locally (TDD: red → green).