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 1235849 - subscription-manager GUI and FIRSTBOOT should allow hosted registration using an activation key
Summary: subscription-manager GUI and FIRSTBOOT should allow hosted registration using...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: subscription-manager
Version: 6.7
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: rc
: ---
Assignee: candlepin-bugs
QA Contact: John Sefler
URL:
Whiteboard:
Depends On:
Blocks: 1235850
TreeView+ depends on / blocked
 
Reported: 2015-06-25 22:22 UTC by John Sefler
Modified: 2016-05-10 20:36 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1235850 (view as bug list)
Environment:
Last Closed: 2016-05-10 20:36:58 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
subscription-manager-gui (39.01 KB, image/png)
2016-03-30 18:58 UTC, John Sefler
no flags Details
subscription-manager-firstboot (77.69 KB, image/png)
2016-03-30 19:10 UTC, John Sefler
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2016:0797 0 normal SHIPPED_LIVE python-rhsm and subscription-manager bug fix and enhancement update 2017-01-06 16:31:50 UTC

Description John Sefler 2015-06-25 22:22:01 UTC
Description of problem:
For awhile, the Red Hat Customer Portal did not support creation of activation keys.  Hence the subscription-manager-gui and subscription-manager-firstboot were programmed to keep the "I will use an Activation Key" checkbox disabled whenever the "I will register with:" field contained a hostname matching the default subscription.rhn.redhat.com (or some redhat.com variant of this).  This restriction should now be removed.

Version-Release number of selected component (if applicable):
This applies to both RHEL6 and RHEL7 versions of
 subscription-manager-gui
 subscription-manager-firstboot



How reproducible:


Steps to Reproduce:
1. launch subscription-manager-gui and click register
2. click the Default button which should set the hostname field to "subscription.rhn.redhat.com"
3. try to register with a valid activation key

Actual results:
"I will use an Activation Key" checkbox is disabled

Expected results:
enabled


Additional info:
The workaround for this bug is to use the CLI version of subscription-manager to register with an activation key.

Comment 1 Adrian Likins 2015-09-21 17:31:45 UTC
https://github.com/candlepin/subscription-manager/commit/88b405ff9aff2965a4682a587dff79395306ded0#diff-c1a6559034ed7c3618c7baf20ef27b37L1127

part of https://github.com/candlepin/subscription-manager/commit/88b405ff9aff2965a4682a587dff79395306ded0

commit 88b405ff9aff2965a4682a587dff79395306ded0
Author: Adrian Likins <alikins>
Date:   Fri Jul 31 15:46:10 2015 -0400

    884288: Better registergui for initial-setup
    
    Also fixes: 1248546, 1257179, 1250451, 1251527, 1255805
    
    Implement RegisterWidget flow with proceed and finished signals
    
    Make SubManBaseWidget also a GObject.GObject. So that
    sub classes of it can use gobject signals and properties.
    
    Add 'proceed' signal to RegisterWidget, and a handler that
    will move it to the next screen. To drive the widget, another
    widget that provides cancel/register buttons makes them
    emit the 'proceed' signal on registerWidget.
    
    RegisterWidget also emits a 'finished' signal when registration
    is done. The parent widget needs to deal with that. The default
    RegisterDialog just hides the register window.
    
    Try making RegisterInfo a GObject with properties
    Connect RegisterInfo's 'notify::username' and password
    signals to callback that updates the cp_provider
    
    Start splitting error handling up and using signals
    
    ie, register error, register failure, attach error, attach
    failure raise signals so they can get different handlers, depending
    on the dialog that holds the register widget.
    
    add RegisterDialog handlers for attach/register error and failure
    
    Registration state (as used in global STATE) is now
    a property on the registration widget, and the labels/titles
    that need to be updated when it changes are hooked to the
    notify signal on RegisterWidget's 'register_state' property.
    
    Ditto for RegisterWidget's 'details-label-txt', ie, the
    txt for the label under the progress bar ('Finding suitable service
    levels', etc).
    
    There is now a 'stay-on-screen' signal raise from applies or
    async callbacks to indicate to stay on the current screen, replacing
    the previous use of sending the widget to the 'DONT_CHANGE' screen.
    
    Stop using handle_gui_exception for non-exceptions
    
    Passing None as the 'exception' eventually causes
    the last exception handled in the main context to
    get logged as an exception, and also prevents the
    dialog from displaying the message, and generally
    confusing the event loop.
    
    Also update SelectSLAScreen to use a tuple of
    (sla_name, sla_map) in its model for the set of
    radio buttons, to avoid referncing the
    now removed self._sla_data_map
    
    Prevent gui from disabling act keys to prod.
    
    Split handle_gui_exception msg formatting into methods
    
    Start emitting error signals from RegisterWidget with msgs
    
    rhsm_gui can use initial-setup spoke's set_error(msg) to show
    errors and failures.
    
    Screen and NoGuiScreen, RegisterWidget, and RegisterDialog
    all know of 'register-error' signal.
    
    Screens can emit it, where RegisterWidget catches it, logs
    it, stops emission of that signal. (Either the screens
    or RegisterWidget could provide a class closure do_register_error
    that that would see the signal first, and that can be used
    to move to approriate screen to fix the error).
    RegisterWidget then emits RegisterWidget's
    'register-error' signal, that RegisterDialog is connected to.
    
    RegisterDialog._on_register_error will call
    RegisterDialogs handle_register_error or
    handle_register_exception
    
    Any errors that need to present a dialog or other info
    now need to emit a 'register-error' with the args
    of (msg, exc_info). exc_info can be None.

    Add register dialog/widget glade for rhel6
    
    Update the rhel6 fb module to new registergui api
    
    Use signal based error handling instead of the
    multiple levels of overrided methods. In the process
    also remove the RHEL5 firstboot support and the
    firstboot_base.py module it required.
    
    The custom screens that were included in rhsm_login
    were just to alter the UI flow as firstboot needed
    (and really, for the way this module doesn't fit the
    normal firstboot module or moduleSet approach).
    
    Ditch the rhel5 firstboot compat stuff as well.
    
    Fix 'slow' progress bars in register gui.
    
    The timeout used to pulse the progress bar was
    getting added to the main loop twice, causing odd
    progress bar behavior.

Comment 3 John Sefler 2016-03-30 18:58:49 UTC
Created attachment 1141899 [details]
subscription-manager-gui

Verifying Version...

[root@jsefler-6 ~]# rpm -q subscription-manager-gui
subscription-manager-gui-1.16.8-8.el6.x86_64

The 'I will use an Activation Key' widget in the subscription-manager-gui is now enabled/checkable when the default registration server is set.

Comment 4 John Sefler 2016-03-30 19:10:31 UTC
Created attachment 1141900 [details]
subscription-manager-firstboot

Verifying Version...

[root@jsefler-6 ~]# rpm -q subscription-manager-firstboot
subscription-manager-firstboot-1.16.8-8.el6.x86_64

The 'I will use an Activation Key' widget in the subscription-manager-firstboot is now enabled/checkable when the default registration server is set.

Comment 6 errata-xmlrpc 2016-05-10 20:36: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-2016-0797.html


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