Bug 1572837 - Error loading certificate: /etc/pki/product-default/135.pem
Summary: Error loading certificate: /etc/pki/product-default/135.pem
Keywords:
Status: CLOSED DUPLICATE of bug 1573181
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: subscription-manager
Version: 6.10
Hardware: Unspecified
OS: Unspecified
urgent
urgent
Target Milestone: rc
: ---
Assignee: candlepin-bugs
QA Contact: Red Hat subscription-manager QE Team
URL:
Whiteboard:
: 1576201 (view as bug list)
Depends On:
Blocks: 1383344 1425546 1431706 1445438
TreeView+ depends on / blocked
 
Reported: 2018-04-28 02:53 UTC by qianzhan
Modified: 2018-05-17 14:11 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-05-03 12:28:49 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1573181 1 None None None 2021-01-20 06:05:38 UTC

Internal Links: 1573181

Description qianzhan 2018-04-28 02:53:04 UTC
Description of problem:
When using subscription-manager/subscription-manager-gui,error happens:
'Error loading certificate: /etc/pki/product-default/135.pem'

Version-Release number of selected component (if applicable):
[root@dhcp-129-9 ~]# rpm -qa | grep subscription
subscription-manager-gui-1.20.10-6.el6.x86_64
subscription-manager-rhsm-certificates-1.20.10-6.el6.x86_64
subscription-manager-1.20.10-6.el6.x86_64
subscription-manager-firstboot-1.20.10-6.el6.x86_64
subscription-manager-rhsm-1.20.10-6.el6.x86_64


How reproducible:
always

Steps to Reproduce:
1. Install RHEL-6.10-20180427.0.
2. Try to launch subscription-manager-gui:

[root@dhcp-129-9 ~]# subscription-manager-gui 
Error loading certificate: /etc/pki/product-default/135.pem


3. Check rhsm.log:

[root@dhcp-129-9 ~]# cat /var/log/rhsm/rhsm.log 
2018-04-27 22:45:13,293 [ERROR] subscription-manager-gui:13862:MainThread @subscription-manager-gui:233 - Error loading certificate: /etc/pki/product-default/135.pem
Traceback (most recent call last):
  File "/usr/sbin/subscription-manager-gui", line 216, in <module>
    main = managergui.MainWindow(auto_launch_registration=options.register)
  File "/usr/lib64/python2.6/site-packages/subscription_manager/gui/managergui.py", line 207, in __init__
    self.backend = backend or Backend()
  File "/usr/lib64/python2.6/site-packages/subscription_manager/gui/managergui.py", line 116, in __init__
    self.cs = require(CERT_SORTER)
  File "/usr/lib64/python2.6/site-packages/subscription_manager/injection.py", line 106, in require
    return FEATURES.require(feature, *args, **kwargs)
  File "/usr/lib64/python2.6/site-packages/subscription_manager/injection.py", line 80, in require
    self.providers[feature] = provider(*args, **kwargs)
  File "/usr/lib64/python2.6/site-packages/subscription_manager/cert_sorter.py", line 322, in __init__
    self.installed_mgr = inj.require(inj.INSTALLED_PRODUCTS_MANAGER)
  File "/usr/lib64/python2.6/site-packages/subscription_manager/injection.py", line 106, in require
    return FEATURES.require(feature, *args, **kwargs)
  File "/usr/lib64/python2.6/site-packages/subscription_manager/injection.py", line 80, in require
    self.providers[feature] = provider(*args, **kwargs)
  File "/usr/lib64/python2.6/site-packages/subscription_manager/cache.py", line 446, in __init__
    self._setup_installed()
  File "/usr/lib64/python2.6/site-packages/subscription_manager/cache.py", line 501, in _setup_installed
    for prod_cert in self.product_dir.list():
  File "/usr/lib64/python2.6/site-packages/subscription_manager/certdirectory.py", line 230, in list
    default_prod_list = self.default_prod_dir.list()
  File "/usr/lib64/python2.6/site-packages/subscription_manager/certdirectory.py", line 122, in list
    listing.append(create_from_file(path))
  File "/usr/lib64/python2.6/site-packages/rhsm/certificate.py", line 56, in create_from_file
    return _CertFactory().create_from_file(path)
  File "/usr/lib64/python2.6/site-packages/rhsm/certificate2.py", line 74, in create_from_file
    return self._read_x509(_certificate.load(path), path, pem)
  File "/usr/lib64/python2.6/site-packages/rhsm/certificate2.py", line 87, in _read_x509
    raise CertificateException("Error loading certificate: %s" % path)
CertificateException: Error loading certificate: /etc/pki/product-default/135.pem
2018-04-27 22:45:13,380 [INFO] rhsmd:13868:MainThread @rhsmd:279 - rhsmd started

4. Try to register the system in CLI:
[root@dhcp-129-9 ~]# subscription-manager register
System certificates corrupted. Please reregister.

5. Try to clean local data:
[root@dhcp-129-9 ~]# subscription-manager clean
All local data removed
System certificates corrupted. Please reregister.

6. Check rhsm.log:
[root@dhcp-129-9 ~]# cat /var/log/rhsm/rhsm.log 

2018-04-27 22:45:27,206 [INFO] subscription-manager:13880:MainThread @managercli.py:452 - X-Correlation-ID: dd21e9ec44c8401095c926e1e7613ab0
2018-04-27 22:45:27,207 [INFO] subscription-manager:13880:MainThread @managercli.py:341 - Client Versions: {'subscription-manager': '1.20.10-6.el6'}
2018-04-27 22:45:27,207 [INFO] subscription-manager:13880:MainThread @connection.py:868 - Connection built: host=subscription.rhsm.stage.redhat.com port=443 handler=/subscription auth=identity_cert ca_dir=/etc/rhsm/ca/ insecure=False
2018-04-27 22:45:27,208 [INFO] subscription-manager:13880:MainThread @connection.py:868 - Connection built: host=subscription.rhsm.stage.redhat.com port=443 handler=/subscription auth=none
2018-04-27 22:45:27,208 [INFO] subscription-manager:13880:MainThread @managercli.py:341 - Client Versions: {'subscription-manager': '1.20.10-6.el6'}
2018-04-27 22:45:27,219 [INFO] subscription-manager:13880:MainThread @managercli.py:317 - Consumer Identity name=None uuid=None
2018-04-27 22:45:27,220 [ERROR] subscription-manager:13880:MainThread @managercli.py:505 - Error loading certificate: /etc/pki/product-default/135.pem
2018-04-27 22:45:31,071 [INFO] subscription-manager:13886:MainThread @managercli.py:452 - X-Correlation-ID: 616cc09b18d64c8d8032a0ba5f8e6347
2018-04-27 22:45:31,071 [INFO] subscription-manager:13886:MainThread @managercli.py:341 - Client Versions: {'subscription-manager': '1.20.10-6.el6'}
2018-04-27 22:45:31,073 [INFO] subscription-manager:13886:MainThread @managerlib.py:869 - Cleaned local data
2018-04-27 22:45:31,073 [ERROR] subscription-manager:13886:MainThread @managercli.py:505 - Error loading certificate: /etc/pki/product-default/135.pem
[root@dhcp-129-9 ~]# 


Actual results:
As above steps, the error blocks usages of subscription-manager and subscription-manager-gui.

Expected results:
No error happens when using subscription-manager/subscription-manager-gui

Additional info:

Comment 3 qianzhan 2018-05-02 03:39:56 UTC
This bug still blocks RHEL-6.10-Snapshot-1.1 (RHEL-6.10-20180430.0)

Comment 7 Barnaby Court 2018-05-03 12:28:49 UTC

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

Comment 8 Kevin Howell 2018-05-17 14:11:12 UTC
*** Bug 1576201 has been marked as a duplicate of this bug. ***


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