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 1925532 - Do not require RPM puppet-foreman_scap_client that is injecting Puppet Facts
Summary: Do not require RPM puppet-foreman_scap_client that is injecting Puppet Facts
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Packaging
Version: 6.8.0
Hardware: x86_64
OS: Linux
unspecified
low
Target Milestone: 6.14.0
Assignee: Eric Helms
QA Contact: Lukas Pramuk
URL:
Whiteboard:
: 2106654 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-02-05 13:17 UTC by Anand Jambhulkar
Modified: 2023-11-08 14:17 UTC (History)
10 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 2242908 (view as bug list)
Environment:
Last Closed: 2023-11-08 14:17:32 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker SAT-18953 0 None None None 2023-07-14 13:12:52 UTC
Red Hat Knowledge Base (Solution) 5756981 0 None None None 2022-05-11 19:05:09 UTC
Red Hat Product Errata RHSA-2023:6818 0 None None None 2023-11-08 14:17:51 UTC

Description Anand Jambhulkar 2021-02-05 13:17:51 UTC
Description of problem:
----------------------


The Satellite RPM depends on puppet-foreman_scap_client. This module has also a Facts that are ALLWAYS synced to the ALL Client even that i do not use the foramn_scap_client.


-----------
Dependencies Resolved

======================================================================================================================
 Package                         Arch        Version               Repository                                    Size
======================================================================================================================
Removing:
 puppet-foreman_scap_client      noarch      0.4.0-1.el7sat        @local-rhel-7-server-satellite-6.8-rpms       58 k
Removing for dependencies:
 satellite                       noarch      6.8.3-1.el7sat        @local-rhel-7-server-satellite-6.8-rpms       72

Transaction Summary
======================================================================================================================
Remove  1 Package (+1 Dependent package)

Installed size: 58 k
Is this ok [y/N]: n
-----------

---------
[crash/LI] root@li-lc-2224:~# cat /usr/share/puppet/modules/foreman_scap_client/lib/facter/rh_certificates.rb
def extract_certificates_from_subscription_manager
  certificates = {}
  certificate_end_path = '/cert.pem'
  private_key_end_path = '/key.pem'
  rh_default_ca_cert = '/etc/rhsm/ca/redhat-uep.pem'
  data = Facter::Util::Resolution.exec('/usr/sbin/subscription-manager config')
  return nil if data.nil? || data.empty?
  data = data.gsub("\n", "").gsub(/[\[\]]/, "")
  data_array = data.scan(/(\S+)\s*=\s* ([^ ]+)/)
  data_hash = Hash[*data_array.flatten]
  consumer_cert_dir = data_hash["consumercertdir"]
  certificates[:repo_ca_cert]          = data_hash["repo_ca_cert"] unless data_hash["repo_ca_cert"] == rh_default_ca_cert
  certificates[:host_certificate_path] = consumer_cert_dir + certificate_end_path
  certificates[:host_private_key_path] = consumer_cert_dir + private_key_end_path

  certificates
end

certificates_hash = extract_certificates_from_subscription_manager
# Set Katello certificates only if certificates_hash[:repo_ca_cert] exists
if certificates_hash && certificates_hash[:repo_ca_cert]
  Facter.add('rh_certificate_repo_ca_file') do
    setcode do
      certificates_hash[:repo_ca_cert]
    end
  end

  Facter.add('rh_certificate_consumer_host_cert') do
    setcode do
      certificates_hash[:host_certificate_path]
    end
  end

  Facter.add('rh_certificate_consumer_host_key') do
    setcode do
      certificates_hash[:host_private_key_path]
    end
  end
end
[crash/LI] root@li-lc-2224:~#
----------

Effect on the Client:
----------
vrempet-admin@li-lc-1437 ~
$ sudo facter -p | grep rh_
rh_certificate_consumer_host_cert => /etc/pki/consumer/cert.pem
rh_certificate_consumer_host_key => /etc/pki/consumer/key.pem
rh_certificate_repo_ca_file => /etc/rhsm/ca/katello-server-ca.pem

vrempet-admin@li-lc-1437 ~
$
----------


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

Satellite Server 6.8


Expected results:
----------------

1. Please give the Customer control over the Puppet Modules and Facts.

2. Please remove this RPM dependency from the top-level 'satellite' rpm so i can uninstall rpms that provide Puppet Modules that i am not using.

Comment 2 Brad Buckingham 2022-09-02 20:25:18 UTC
Upon review of our valid but aging backlog the Satellite Team has concluded that this Bugzilla does not meet the criteria for a resolution in the near term, and are planning to close in a month. This message may be a repeat of a previous update and the bug is again being considered to be closed. If you have any concerns about this, please contact your Red Hat Account team.  Thank you.

Comment 3 Brad Buckingham 2022-09-02 20:31:56 UTC
Upon review of our valid but aging backlog the Satellite Team has concluded that this Bugzilla does not meet the criteria for a resolution in the near term, and are planning to close in a month. This message may be a repeat of a previous update and the bug is again being considered to be closed. If you have any concerns about this, please contact your Red Hat Account team.  Thank you.

Comment 5 Brad Buckingham 2022-10-28 18:02:59 UTC
Thank you for your interest in Red Hat Satellite. We have evaluated this request, and while we recognize that it is a valid request, we do not expect this to be implemented in the product in the foreseeable future. This is due to other priorities for the product, and not a reflection on the request itself. We are therefore closing this out as WONTFIX. If you have any concerns about this feel free to contact your Red Hat Account Team. Thank you.

Comment 6 Peter Vreman 2022-10-31 09:18:05 UTC
Sorry, what is the problem of just removing the rpm from dependencies the Satellite rpm?

Comment 7 Brad Buckingham 2022-11-01 20:21:47 UTC
Hi Peter,

It may be possible; however, it needs to be investigated.  I will reach out to see if this something that can be addressed in the near-term.  If so, we can re-open.

Thanks!

Comment 12 Eric Helms 2023-07-14 23:16:09 UTC
*** Bug 2106654 has been marked as a duplicate of this bug. ***

Comment 13 Lukas Pramuk 2023-07-26 18:05:49 UTC
VERIFIED.

@Satellite 6.14.0 Snap8
satellite-6.14.0-3.el8sat.noarch

by the following steps:

# rpm -q puppet-foreman_scap_client
package puppet-foreman_scap_client is not installed

# rpm -qR satellite | grep puppet
<empty>

>>> puppet-foreman_scap_client package is now optional and not installed by default

Comment 16 errata-xmlrpc 2023-11-08 14:17:32 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.14 security and bug fix update), 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-2023:6818


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