Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 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 "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". 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 "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-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 1240553

Summary: Imported cert doesnot feature in the MySubscriptions Tab of GUI but it does show up when list --consumed command is executed
Product: Red Hat Enterprise Linux 7 Reporter: Shwetha Kallesh <skallesh>
Component: subscription-managerAssignee: William Poteat <wpoteat>
Status: CLOSED ERRATA QA Contact: John Sefler <jsefler>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.2CC: crog, stoner, wpoteat
Target Milestone: rcKeywords: Regression
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-11-19 11:48:58 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: 1246123    
Attachments:
Description Flags
Cert imported thro CLI command
none
Cert imported thro GUI
none
Cert sucessfully imported
none
Imported cert being listed in Mysubscriptions tab none

Description Shwetha Kallesh 2015-07-07 08:32:09 UTC
Created attachment 1049169 [details]
Cert imported thro CLI command

Description of problem:
Imported cert doesnot feature in the MySubscriptions Tab of GUI but it does show up when list --consumed command is executed

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

subscription-manager-1.15.2-1.git.90.3c43eb8.el7.x86_64
python-rhsm: 1.15.2-1.git.12.e61eaee.el7
subscription management server: 2.0.3-1
subscription management rules: 5.16

How reproducible:


Steps to Reproduce:

CLI:

a) Attach a subscription

[root@dhcp35-155 product]# subscription-manager attach --pool 8ac681e44e62a52b014e62a6711c05f7
Successfully attached a subscription for: Awesome OS Instance Based one socket


b)List the consumed subscriptions

 [root@dhcp35-155 product]# subscription-manager list --consumed
+-------------------------------------------+
   Consumed Subscriptions
+-------------------------------------------+
Subscription Name:   Awesome OS Instance Based one socket
Provides:            Awesome OS Instance Server Bits
SKU:                 awesomeos-onesocketib
Contract:            1
Account:             12331131231
Serial:              7892381667299029701
Pool ID:             8ac681e44e62a52b014e62a6711c05f7
Provides Management: No
Active:              True
Quantity Used:       1
Service Level:       Standard
Service Type:        L1-L3
Status Details:      Subscription is current
Subscription Type:   Instance Based
Starts:              07/06/2015
Ends:                07/05/2016
System Type:         Physical

c) Create cert to be imported

[root@dhcp35-155 product]# cat /etc/pki/entitlement/7892381667299029701.pem >> cert.pem
[root@dhcp35-155 product]# cat /etc/pki/entitlement/7892381667299029701-key.pem >> cert.pem

d) remove the data locally 

[root@dhcp35-155 product]# subscription-manager clean
All local data removed

e) import the cert 

[root@dhcp35-155 ~]# subscription-manager import --cert /root/cert.pem
Successfully imported certificate cert.pem

d) List the consumed subscriptions to check if the imported cert is in the consumed list or not

[root@dhcp35-155 ~]# subscription-manager list --consumed
+-------------------------------------------+
   Consumed Subscriptions
+-------------------------------------------+
Subscription Name:   Awesome OS Instance Based one socket
Provides:            Awesome OS Instance Server Bits
SKU:                 awesomeos-onesocketib
Contract:            1
Account:             12331131231
Serial:              7892381667299029701
Pool ID:             8ac681e44e62a52b014e62a6711c05f7
Provides Management: No
Active:              True
Quantity Used:       1
Service Level:       Standard
Service Type:        L1-L3
Status Details:      Subscription management service doesn't support Status Details.
Subscription Type:   
Starts:              07/06/2015
Ends:                07/05/2016
System Type:         Physical


GUI:

a) Launch GUI
b) In the "System" menu select "Import Cert" option
c) Select the cert as above in step c)
d) Select MySubscriptions tab

Actual results:
Imported cert is not listed in the MySubscriptions tab


Expected results:

Imported cert should be listed in the MySubscriptions tab
Additional info:

Comment 1 Shwetha Kallesh 2015-07-07 08:32:36 UTC
Created attachment 1049171 [details]
Cert imported thro GUI

Comment 4 William Poteat 2015-08-07 16:45:04 UTC
master commit 6857d9ce2f1251c5aaf2e47570680c1cdd7ae0a6

Comment 6 Chris "Ceiu" Rog 2015-08-12 17:01:25 UTC
commit 6857d9ce2f1251c5aaf2e47570680c1cdd7ae0a6
Author: Adrian Likins <alikins>
Date:   Fri Aug 7 11:33:40 2015 -0400

    1240553: Fix detection of cert dir changes
    
    The timeout that called the file monitor objects was
    not returning True, so it would run once, and then be
    removed from the event loop sources. Now it returns
    True forever.
    
    This fixes issues where changes to certificate directories
    (/etc/pki/entitlement/ for ex) were not being noticed by the
    gui. This included changes by running the cli command at the
    same time, or using the "Import cert" dialog to import an
    entitlement certificate.

Comment 7 Adrian Likins 2015-08-14 16:12:21 UTC
*** Bug 1245261 has been marked as a duplicate of this bug. ***

Comment 9 Shwetha Kallesh 2015-08-17 13:36:16 UTC
Created attachment 1063859 [details]
Cert sucessfully imported

Comment 10 Shwetha Kallesh 2015-08-17 13:37:39 UTC
Created attachment 1063860 [details]
Imported cert being listed in Mysubscriptions tab

Marking verified as imported cert feature in the Mysubscriptions list

[root@dhcp35-236 ~]# subscription-manager version
server type: This system is currently not registered.
subscription management server: 2.0.6-1
subscription management rules: 5.16
subscription-manager: 1.15.9-6.el7
python-rhsm: 1.15.4-3.el7

Comment 11 errata-xmlrpc 2015-11-19 11:48:58 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, 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://rhn.redhat.com/errata/RHBA-2015-2122.html