release v0.5.18 (6a76a73085) #63

Merged
pipeline-bot merged 3 commits from _promote/v0.5.18 into main 2026-07-27 23:37:13 +00:00
Contributor
No description provided.
chore: devbump 0.5.17 -> 0.5.18-dev
All checks were successful
pipeline/ci CI green v0.5.18-dev
78ecd3c903
fix(security): refuse redirects on Kratos Admin API calls
All checks were successful
pipeline/ci CI green v569b504a5d12
569b504a5d
Pinning kratosAdminURL to the in-namespace kratos-admin Service pins
the URL the operator DIALS, not where the request ends up. The shared
client set no CheckRedirect, so Go followed up to ten redirects across
origins, and 307/308 replay the request body — which for createIdentity
and updateIdentity is the plaintext password read from the referenced
Secret.

That leaves the original confused-deputy open to the very actor the pin
defends against: anyone who can create a Service or EndpointSlice named
kratos-admin on port 4434 in their own namespace satisfies the pin, then
answers with a 307 and receives the credential.

The client now returns the 3xx to the caller instead of following it,
where it fails the status-code check like any other unexpected response.
This costs nothing: the Kratos Admin API never answers a legitimate
request with a redirect.

Both the shipped client and the tested client now come from one
controller.NewAdminHTTPClient constructor, so a future timeout or
transport change cannot reintroduce the gap on only one side — the
previous client was built inline in cmd/main.go, out of reach of every
test in the controller package.

The regression test drives createIdentity through a redirecting server
and asserts the redirect target receives nothing. Removing CheckRedirect
fails it with the password visible in the captured body.
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
sean/kratos-identity-operator!63
No description provided.