Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1696824 - Unauthenticated pull not working for Head requests
Summary: Unauthenticated pull not working for Head requests
Keywords:
Status: CLOSED DUPLICATE of bug 1672802
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Container Management
Version: 6.5.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: Unspecified
Assignee: satellite6-bugs
QA Contact: Mirek Długosz
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-04-05 17:13 UTC by Partha Aji
Modified: 2019-04-05 17:34 UTC (History)
0 users

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-04-05 17:34:59 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 26549 0 Normal Closed Unauthenticated pull not working for Head requests 2020-04-14 12:56:53 UTC

Description Partha Aji 2019-04-05 17:13:00 UTC
Description of problem:
Given an allowance of an unauthenticated pull for the Library environment head requests are not given a free pass.

"""
$ curl -L --head https://theta.partello.example.com/v2/default_organization-docker-busybox/manifests/4.0.0-0

HTTP/1.1 401 Unauthorized
Date: Fri, 05 Apr 2019 16:13:13 GMT
Server: Apache
"""


Version-Release number of selected component (if applicable):
6.5.0 earlier

How reproducible:
always

Steps to Reproduce:
1. Create a docker repo with the following url and  upstream name
registry url: https://quay.io/
upstream name: openshift-release-dev/ocp-release
2. Sync the repo
3. Goto Content->Lifecycle Environments
4. Choose library and set unauthenticated pull to yes
5. Try the following call
$ curl -L --head https://<sat>/v2/default_organization-<$PRODUCT>-<$REPO>/manifests/4.0.0-0

Actual results:
"""
HTTP/1.1 401 Unauthorized
Date: Fri, 05 Apr 2019 16:13:13 GMT
Server: Apache
"""


Expected results:
"""
$ curl -L --head https://theta.partello.example.com/v2/default_organization-docker-busybox/manifests/4.0.0-0
HTTP/1.1 200 OK
Date: Fri, 05 Apr 2019 16:18:31 GMT
Server: Apache
Foreman_version: 1.22.0-develop
Foreman_api_version: 2
Docker-Content-Digest: sha256:59c38273d9331211a5ad2c6fd10634f6db1932c15412e86bbeeba548c9c4c82c
Content-Type: application/json; charset=utf-8
Docker-Distribution-API-Version: registry/2.0
....
"""

Additional info:

Comment 3 Partha Aji 2019-04-05 17:25:12 UTC
Connecting redmine issue https://projects.theforeman.org/issues/26549 from this bug

Comment 4 Brad Buckingham 2019-04-05 17:34:59 UTC

*** This bug has been marked as a duplicate of bug 1672802 ***


Note You need to log in before you can comment on or make changes to this bug.