Skip to content

fix(kong): render API credentials before startup - #16

Merged
birdmanmandbir merged 2 commits into
mainfrom
fix/kong-key-template-rendering
Jul 27, 2026
Merged

fix(kong): render API credentials before startup#16
birdmanmandbir merged 2 commits into
mainfrom
fix/kong-key-template-rendering

Conversation

@birdmanmandbir

@birdmanmandbir birdmanmandbir commented Jul 27, 2026

Copy link
Copy Markdown
Contributor

Summary

  • render the Kong declarative credential template inside the container before startup
  • point Kong at the rendered file so key-auth accepts the actual anon and service-role keys
  • add a deployment contract regression test

Security impact

Before this fix, Kong used predictable template literals as both anonymous and service-role key-auth credentials. The service-role credential can bypass normal row-level access controls, so affected clusters should deploy this fix promptly.

Root cause

The credential ConfigMap is a template, but the Kong container started directly without rendering it. Environment variables supplied from the JWT Secret therefore never reached Kong declarative configuration.

Verification

  • go test ./...
  • runtime render probe against the live Kong image: both placeholders removed without printing either credential
  • live reproduction confirmed both predictable credentials are currently accepted; the corrected deployment will be re-tested after rollout

@birdmanmandbir
birdmanmandbir merged commit 9e71dcc into main Jul 27, 2026
3 checks passed
@birdmanmandbir
birdmanmandbir deleted the fix/kong-key-template-rendering branch July 27, 2026 08:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant