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

Support Content-Digest header in StagingsController #3558

Conversation

philippthun
Copy link
Member

@philippthun philippthun commented Dec 15, 2023

The Content-Digest header takes precedence over Content-MD5. The following header format is supported:

<algorithm>=:<base64-digest>:

Whereas 'algorithm' is one of the following: sha-512, sha-256, sha-1 (or sha) and md5.

Addresses one of the issues identified in: #3544

  • I have reviewed the contributing guide

  • I have viewed, signed, and submitted the Contributor License Agreement

  • I have made this pull request to the main branch

  • I have run all the unit tests using bundle exec rake

  • I have run CF Acceptance Tests

The Content-Digest header takes precedence over Content-MD5. The
following header format is supported:

 <algorithm>=:<base64-digest>:

Whereas 'algorithm' is one of the following: sha-512, sha-256, sha-1
(or sha) and md5.
Copy link
Member

@moleske moleske left a comment

Choose a reason for hiding this comment

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

This seems good as it allows for both the older md5 hash and newer hashes. Some future time we can decide if we want to error on content_digest.present? being false

@philippthun philippthun merged commit 13c55c6 into cloudfoundry:main Dec 19, 2023
philippthun added a commit to sap-contributions/cc-uploader that referenced this pull request Dec 19, 2023
The (CC) StagingsController now supports both 'Content-MD5' and
'Content-Digest' headers (see [1]). Both headers should be forwarded.

[1] cloudfoundry/cloud_controller_ng#3558
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