Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem when constructing ContractIds containing colons ":" #3211

Closed
paullatzelsperger opened this issue Jun 22, 2023 · 1 comment · Fixed by #3235
Closed

Problem when constructing ContractIds containing colons ":" #3211

paullatzelsperger opened this issue Jun 22, 2023 · 1 comment · Fixed by #3235
Assignees
Labels
bug Something isn't working
Milestone

Comments

@paullatzelsperger
Copy link
Member

paullatzelsperger commented Jun 22, 2023

Bug Report

Describe the Bug

Having Assets where the id contains the ":" colon character causes problems during contract negotiation, causing the negotiation instance not to be found.

Expected Behavior

(see link below)

Observed Behavior

(see link below)

Steps to Reproduce, Context Information

eclipse-tractusx/tractusx-edc#484

Detailed Description

ContractId instances are constructed in the form <CONTRACT_DEF_ID>:<ASSET_ID>:<UUID> using ":" as delimiter character and are parsed accordingly. If either the contract definition id or the asset id contains a colon ":" character, that would throw off the parsing algorithm.

Possible Implementations

  • make the delimiter configurable, default to ":"
  • make ContractIds opaque, e.g. base64 encode the parts (<-- probably the best solution)
@ndr-brt
Copy link
Member

ndr-brt commented Jun 26, 2023

I also agree on making the ContractId parts opaque with encoding, at that point we could remove the : validation on ContractDefinition. I can take care of this

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants