Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
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 1513599

Summary: foreman-maintain lower cases the uppercase characters while saving hammer credentials
Product: Red Hat Satellite Reporter: sthirugn <sthirugn>
Component: Satellite MaintainAssignee: Anurag Patel <apatel>
Status: CLOSED ERRATA QA Contact: Katello QA List <katello-qa-list>
Severity: high Docs Contact:
Priority: unspecified    
Version: 6.3.0CC: ahumbe, amaliver, apatel, bbuckingham, brubisch, cwelton, inecas, kgaikwad, lzap, mmccune, sabnave
Target Milestone: UnspecifiedKeywords: PrioBumpField, PrioBumpQA, Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-01-04 17:54:03 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: 1122832, 1533259    

Description sthirugn@redhat.com 2017-11-15 16:33:50 UTC
Description of problem:
foreman-maintain lower cases the uppercase characters while saving hammer credentials

Version-Release number of selected component (if applicable):
rubygem-foreman_maintain-0.0.11-1.el7sat.noarch

How reproducible:
Always

Steps to Reproduce:
1. Say Satellite hammer password is CHANGEME!@#$%
2. Install rubygem-foreman_maintain 
3. Run any foreman-maintain command: Example:
# foreman-maintain upgrade check --target-version 6.3.z

Running preparation steps required to run the next scenarios
================================================================================
Setup hammer: 
Hammer username [admin]: 
Hammer password: 
Invalid credentials

Actual results:
The foreman-maintain fails with invalid credentials even though you enter the right password

/etc/foreman-maintain/foreman-maintain-hammer.yml saves the password as `changeme!@#$%`

All the upper case characters are lowercased.  As far as I checked, the special characters look fine.

Expected results:
credentials should be saved properly

Additional info:
Changing the credentials in /etc/foreman-maintain/foreman-maintain-hammer.yml works fine.

Comment 1 Anurag Patel 2017-11-15 20:26:53 UTC
Looks to me like the common ask() method is downcasing user's responses, and would affect uppercase usernames too. Will address this.

Comment 3 Ivan Necas 2017-11-28 12:04:34 UTC
*** Bug 1518203 has been marked as a duplicate of this bug. ***

Comment 4 Satellite Program 2017-12-06 13:21:59 UTC
Moving this bug to POST for triage into Satellite 6 since the upstream issue http://projects.theforeman.org/issues/21721 has been resolved.

Comment 7 Mike McCune 2017-12-15 21:06:19 UTC
This works perfectly with the update to foreman-maintain 0.1

Comment 10 errata-xmlrpc 2018-01-04 17:54:03 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://access.redhat.com/errata/RHBA-2018:0033

Comment 11 Anurag Patel 2018-01-10 12:47:06 UTC
*** Bug 1523702 has been marked as a duplicate of this bug. ***