Bug 2112098 - Need to be able to provide custom cert for ISS for Red Hat CDN
Summary: Need to be able to provide custom cert for ISS for Red Hat CDN
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Inter Satellite Sync
Version: 6.11.0
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: 6.12.0
Assignee: Partha Aji
QA Contact: Radek Mynar
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-07-28 19:34 UTC by Partha Aji
Modified: 2023-12-19 16:59 UTC (History)
3 users (show)

Fixed In Version: foreman-3.3.0.9-1,tfm-rubygem-katello-4.5.0.12-1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2022-11-16 13:35:05 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 35296 0 Normal New Need to be able to provide custom cert for ISS for Red Hat CDN 2022-07-29 22:31:06 UTC
Foreman Issue Tracker 35359 0 Normal Closed Make the Http Proxy store a CA certifcate 2022-09-21 14:42:21 UTC
Red Hat Issue Tracker SAT-11932 0 None None None 2022-09-19 20:17:38 UTC
Red Hat Product Errata RHSA-2022:8506 0 None None None 2022-11-16 13:35:13 UTC

Description Partha Aji 2022-07-28 19:34:51 UTC
Description of problem:

Assume we have an Upstream HTTP Server that is serving the extracted CDN ISO  content and a Downstream Server that can only talk to that http server.

We need to be able specify custom ca cert (or ca credential) when we change the RedHat CDN url to the upstream url.

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


How reproducible:


Steps to Reproduce:
1. Get a content iso extracted in /var/www/html/pub/<myrepo> on some other box
2. Go to Subscriptions => Manage Manifest 
3. Change the redhat cdn url to  https://<fqdn>/pub/<myrepo>. Notice that you cannot specify the cert in this tab.
4. Go to Redhat Repositories and try expanding the available repositories.

Actual results:

You should get an error along the lines of 
2022-07-28T18:01:33 [I|app|37e3cb19] CDN: Requesting path https://<webserver>:443/pub/repos/content/dist/rhel/server/7/listing
/opt/rh/rh-ruby27/root/usr/share/ruby/net/protocol.rb:44: warning: exception in verify_callback is ignored
2022-07-28T18:01:33 [E|app|37e3cb19] Failed at scanning for repository: SSL_connect returned=1 errno=0 state=error: certificate verify failed (self signed certificate in certificate chain)


Expected results:

Ability to set the SSL CA Credential even for Red Hat CDN.


Additional notes:
https://github.com/Katello/katello/blob/master/app/lib/katello/resources/cdn.rb#L64 needs to have a logic along the lines of

if cdn_configuration.ssl_ca?
  options[:ssl_ca_cert] = cdn_configuration.ssl_ca  
else
  options[:ssl_ca_file] =  self.ca_file
end

We also need to be able to set a SSL CA Credential on the Manage Manifests.

Comment 1 Partha Aji 2022-07-29 22:31:06 UTC
Connecting redmine issue https://projects.theforeman.org/issues/35296 from this bug

Comment 2 Bryan Kearney 2022-07-30 00:05:20 UTC
Upstream bug assigned to paji

Comment 3 Bryan Kearney 2022-07-30 00:05:22 UTC
Upstream bug assigned to paji

Comment 4 Bryan Kearney 2022-09-19 20:06:20 UTC
Moving this bug to POST for triage into Satellite since the upstream issue https://projects.theforeman.org/issues/35296 has been resolved.

Comment 5 Partha Aji 2022-09-21 14:42:20 UTC
Connecting redmine issue https://projects.theforeman.org/issues/35359 from this bug

Comment 8 Radek Mynar 2022-10-07 10:05:04 UTC
Redhat CDN is not editable. There's a new CDN configuration type - Custom CDN. It allows to select (non-mandatory) Content Credential. Synchronization over Custom CDN is possible.

VERIFIED with Satellite 6.12 SNAP13 @RHEL8.6

Comment 12 errata-xmlrpc 2022-11-16 13:35:05 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Important: Satellite 6.12 Release), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2022:8506


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