Skip to content

fix: add STS client secret rotation and an optional bind host for the STS API - #1232

Merged
paullatzelsperger merged 2 commits into
eclipse-edc:mainfrom
paullatzelsperger:fix/1231_sts_secret_rotation
Oct 21, 2026
Merged

paullatzelsperger merged 2 commits into
eclipse-edc:mainfrom
paullatzelsperger:fix/1231_sts_secret_rotation

Conversation

@paullatzelsperger

@paullatzelsperger paullatzelsperger commented Oct 20, 2026 •

Copy link
Copy Markdown
Member

What this PR changes/adds

  • A new Identity API endpoint, POST /v1/participants/{participantContextId}/sts/secret, regenerates the STS client secret of a participant context and returns it. It has the same authorization as the API key regeneration endpoint (the participant itself or an admin). The new secret is stored under the existing vault alias, so the vault entry is replaced and no alias or vault policy changes. A participant context without an STS account gets a 404.
  • StsAccountService.updateSecret checks that the account belongs to the given participant context, stores the new secret before the account is switched to the new alias, deletes the old secret only afterwards (and the new one if the switch fails), and returns the new secret instead of the alias.
  • A new optional setting, web.http.sts.host, binds the STS API to one network interface. When it is unset, the STS API listens on all interfaces as before. sts-api now depends on jetty-core and jetty-server for this.
  • The documentation states that the STS API must not be exposed publicly and describes the rotation endpoint and the new setting.

Why it does that

An STS client secret could not be changed after the participant context was created, so a leaked secret stayed valid until an operator overwrote the vault entry manually or deleted the participant context. updateSecret deleted the old secret before storing the new one and did not check ownership. The STS API always listened on all network interfaces.

Linked Issue(s)

Closes #1231

🤖 Generated with Claude Code

… STS API

- new Identity API endpoint POST /v1/participants/{id}/sts/secret rotates the
  STS client secret of a participant context under the same vault alias
- StsAccountService.updateSecret checks the account's participant context,
  stores the new secret before switching to it, deletes the old secret only
  afterwards and returns the new secret
- optional web.http.sts.host setting binds the STS API to one interface
- document that the STS API must not be publicly reachable

Closes eclipse-edc#1231

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@paullatzelsperger
paullatzelsperger requested a review from a team as a code owner October 20, 2026 13:26
@paullatzelsperger paullatzelsperger added the enhancement New feature or request label Oct 20, 2026
@paullatzelsperger paullatzelsperger self-assigned this Oct 20, 2026
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@paullatzelsperger
paullatzelsperger merged commit 74b445a into eclipse-edc:main Oct 21, 2026
36 of 40 checks passed
@paullatzelsperger
paullatzelsperger deleted the fix/1231_sts_secret_rotation branch October 21, 2026 06:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

STS client secrets cannot be rotated, and the STS API cannot be bound to one interface

2 participants