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

Add TLE response media type #2218

Open
haydentherapper opened this issue Aug 26, 2024 · 2 comments
Open

Add TLE response media type #2218

haydentherapper opened this issue Aug 26, 2024 · 2 comments
Labels
enhancement New feature or request

Comments

@haydentherapper
Copy link
Contributor

Description

We should support returning a response formatted as a TransparencyLogEntry (TLE) per the specification. This will be used by Sigstore clients who currently have to transform the Rekor response into the spec-compliant struct.

We should be able to implement this as a custom response type in OpenAPI - https://swagger.io/docs/specification/2-0/describing-responses/

@haydentherapper
Copy link
Contributor Author

Not as straightforward - OpenAPI 3.0 allows a per-content-type schema, but not 2.0 which is what we're using - https://swagger.io/docs/specification/describing-responses/

@bobcallaway
Copy link
Member

after reviewing, there's a problem in that we cannot take a TLE and convert back into a models.LogEntry because we don't have the tree ID to correctly set the entryUUID. While most tests still pass, others expect the full entryUUID and therefore I think this will significantly break clients. Given the flaky nature of go-openapi's Accept header support, and this fact, I think we'll have to punt this to the v2 api.

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 a pull request may close this issue.

3 participants
@bobcallaway @haydentherapper and others