Bug 1977893

Summary: [pulp3] Pulp contentguard using wrong ca certificate leads to permission denied on consumers
Product: Red Hat Satellite Reporter: Matthias Dellweg <mdellweg>
Component: Subscription ManagementAssignee: satellite6-bugs <satellite6-bugs>
Status: CLOSED DUPLICATE QA Contact: Cole Higgins <chiggins>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.9.0CC: jsherril, peter.vreman
Target Milestone: 6.10.0Keywords: Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-07-06 15:36:57 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1957813    

Description Matthias Dellweg 2021-06-30 16:27:49 UTC
Description of problem:
Katello configures the RHSM content guard with the wrong ca certificate (probably in conjunction with a custom server certificate). This leads to clients being unable to consume subscription content from Katello even when fully entitled.


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


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:
yum issues 403 errors when accessing content protected by subscriptions,
but success when using custom repositories.


Expected results:
yum update on a system with subscription content should succeed.


Additional info:
`curl -vv -k -X PATCH  --data-urlencode 'ca_certificate@/etc/pki/katello/certs/katello-default-ca-stripped.crt' --cert /etc/pki/katello/certs/pulp-client.crt --key /etc/pki/katello/private/pulp-client.key "https://localhost/pulp/api/v3/contentguards/certguard/rhsm/<UUID>/"`
can be used to install the ca certificate that candlepin uses when creating entitlements.

Comment 3 Justin Sherrill 2021-07-06 15:36:57 UTC
This is actually a dupe of https://bugzilla.redhat.com/show_bug.cgi?id=1961886  

That one is assigned to 6.10, but now that i think about it, i think its worthwhile to backport to 6.9.

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

Comment 4 Justin Sherrill 2021-07-06 15:38:01 UTC
Here is the upstream change:  https://github.com/Katello/katello/pull/9381