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

Rephrase the subject exclusion from validation #445

Merged
merged 1 commit into from
Jul 27, 2023

Conversation

sudo-bmitch
Copy link
Contributor

Fixes #442.

Signed-off-by: Brandon Mitchell <git@bmitch.net>
Copy link
Contributor

@rchincha rchincha left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

A registry MUST accept an otherwise valid manifest with a `subject` field that references a manifest that does not exist, allowing clients to push a manifest and referrers to that manifest in either order.
When a manifest is rejected for these reasons, it MUST result in one or more `MANIFEST_BLOB_UNKNOWN` errors <sup>[code-1](#error-codes)</sup>.
A registry MAY reject a manifest uploaded to the manifest endpoint with descriptors in other fields that reference a manifest or blob that does not exist in the registry.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Swapping the order of these lines makes "otherwise valid manifest" a strange phrase.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we removed "otherwise valid", then couldn't someone upload an invalid manifest (missing fields, unknown media type, etc), but include a subject field and insist that the manifest must now be accepted?

@jdolitsky jdolitsky merged commit 60fc69c into opencontainers:main Jul 27, 2023
4 checks passed
@sudo-bmitch sudo-bmitch deleted the pr-subject-missing branch July 27, 2023 10:32
sudo-bmitch added a commit to sudo-bmitch/distribution-spec that referenced this pull request Aug 18, 2023
Signed-off-by: Brandon Mitchell <git@bmitch.net>
@jdolitsky jdolitsky mentioned this pull request Jan 11, 2024
8 tasks
@sudo-bmitch sudo-bmitch mentioned this pull request Feb 1, 2024
8 tasks
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.

Clarify conditions under which the registry may reject a manifest for having non-existent references
6 participants