Skip to content

chore: fix holderPid generation - #190

Merged
wolf4ood merged 2 commits into
eclipse-cfm:mainfrom
wolf4ood:fix/holder-pid-assigned-by-identityhub
Oct 22, 2026
Merged

wolf4ood merged 2 commits into
eclipse-cfm:mainfrom
wolf4ood:fix/holder-pid-assigned-by-identityhub

Conversation

@wolf4ood

Copy link
Copy Markdown
Contributor

What this PR changes/adds

The onboarding agent no longer sends a holderPid when it requests credentials from IdentityHub. It now reads the holderPid that IdentityHub assigns from the Location header of the response.

  • CredentialRequest no longer has a HolderPID field.
  • New identityhub.HolderPIDFromLocation(location) returns the last path segment of the Location header (.../credentials/request/{holderPid}). It returns an error if the segment is missing.
  • The onboarding activity stores the holderPid returned by IdentityHub. It then polls the request state with it, as before.

Why it does that

Since eclipse-edc/IdentityHub#1219 , IdentityHub assigns the holderPid itself. It rejects any credential request that already carries one:

400 [{"message":"Property 'holderPid' must not be set, it is assigned by IdentityHub","type":"InvalidRequest"}]
This breaks participant onboarding with EDC 1.0.0-RC5.

Further notes

  • Requires an IdentityHub version that includes #1219, such as 1.0.0-RC5. Older IdentityHub versions ignore a request without holderPid, so the agent can't track the request against them.
  • Tests: the CredentialRequest serialization tests are updated, with a new check that holderPid is never serialized. There are new tests for HolderPIDFromLocation. The onboarding deploy test now checks that the stored holderPid comes from the location.

@wolf4ood
wolf4ood merged commit 7bbf49d into eclipse-cfm:main Oct 22, 2026
3 checks passed
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.

2 participants