Skip to content

Cherrypick config api token auth - #345

Merged
lstruman merged 2 commits into
developn-1from
cherrypick-config-api-token_auth
Aug 19, 2026
Merged

Cherrypick config api token auth#345
lstruman merged 2 commits into
developn-1from
cherrypick-config-api-token_auth

Conversation

@lstruman

Copy link
Copy Markdown
Contributor

No description provided.

Copilot AI lite review requested due to automatic review settings August 19, 2026 18:09

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds an opt-in API-token authentication toggle for the /config endpoint, allowing deployments to protect config retrieval without changing the default (legacy) unauthenticated behavior.

Changes:

  • Introduces webconfig.jwt.config_api_token_auth.enabled (default false) and wires it into WebconfigServer.
  • Conditionally applies ApiMiddleware to /config routing when enabled.
  • Suppresses “Request started/finished” info logs for /config requests and adds regression tests covering default auth behavior and log suppression.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
http/webconfig_server.go Adds config API token auth flag/state + suppresses request start/end info logs for /config.
http/router.go Applies ApiMiddleware to /config only when the new flag is enabled.
http/webconfig_server_test.go Adds tests for /config auth default/enablement and for log suppression behavior.
config/sample_webconfig.conf Documents the new config_api_token_auth.enabled setting in the sample config.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@lstruman
lstruman merged commit 1695136 into developn-1 Aug 19, 2026
4 checks passed
@github-actions github-actions Bot locked and limited conversation to collaborators Aug 19, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants