Bug 1109432 - Staypuft should not have a default password and should offer ssh key provisioning
Summary: Staypuft should not have a default password and should offer ssh key provisio...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: rhel-osp-installer
Version: Foreman (RHEL 6)
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ga
: Installer
Assignee: Marek Hulan
QA Contact: Ido Ovadia
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-06-13 21:37 UTC by Lars Kellogg-Stedman
Modified: 2016-04-26 13:23 UTC (History)
8 users (show)

Fixed In Version: rhel-osp-installer-0.0.25-6.el6ost
Doc Type: Bug Fix
Doc Text:
internal only, no doc text needed
Clone Of:
Environment:
Last Closed: 2014-08-21 18:04:31 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2014:1090 0 normal SHIPPED_LIVE Red Hat Enterprise Linux OpenStack Platform Enhancement Advisory 2014-08-22 15:28:08 UTC

Description Lars Kellogg-Stedman 2014-06-13 21:37:36 UTC

Comment 1 Lars Kellogg-Stedman 2014-06-13 21:40:43 UTC
Staypuft should not ship with a default password in place, because this will invariably lead to someone deploying on globally accessible systems and promptly having everyone in the world logging in just because they can.

Staypuft should offer the option of not configuring any root password, and instead should allow one to provision an ssh public key via the web interface.

Hsving both options (password-based and key-based) available keeps security policy under the control of the local administrator.

Comment 3 Mike Burns 2014-06-17 12:27:40 UTC
Marek,

Can we prompt for a default password rather than hardcode it to spengler?  (We might also consider defacing this field in the settings).

Comment 4 Mike Burns 2014-06-17 12:47:35 UTC
Proposed flow:

(at configuration)
Configure client authentication
1.  SSH pubkey authentication
2.  Root Password
3.  Done

If 3 when neither 1 or 2 done, then error (or hide it until 1 or 2 is completed)

If choose 1, prompt for ssh pub key (copy/paste)
If choose 2, Prompt for root password (blank to disable and lock root account password)


If no root password is set, do passwd -l root in kickstart
If set, configure it correctly

If pubkey set, then add it as authorized key in kickstart %post

User must set one or the other to proceed.

Comment 5 Marek Hulan 2014-06-17 12:55:50 UTC
Makes sense to me, I'd also consider adding option to use a file to read key from and leave default for people just testing openstack deployment.

Comment 6 Marek Hulan 2014-06-24 07:54:25 UTC
I was not able to disable password completely. Foreman can't manage host if it does not have root password (it won't pass the validation). Therefore I added a password validation to installer and we allow to set ssh key (either by specifying a path or the whole key). This was released in 0.0.21.

Comment 8 Omri Hochman 2014-06-30 18:06:43 UTC
The current solution does not seem to address the requested behavior from the bug title and body.  

Currently : 
(A) There's is a default password "spengler" 
(B) There a message indicates about the default password :  

"Please set a default root password for newly provisioned machines.  If you choose not to set a password, it will be defaulted to 'spengler'.  The password must be a minimum of 8 characters.  You can also set a p
e deployed to newly provisioned machines."

                     
I would suggest the installer won't offer default passwords and force entering either: ssh-key or password. (in case of choosing ssh-key the generated password should be randomize)

Comment 10 Mike Burns 2014-07-01 14:16:10 UTC
(In reply to Omri Hochman from comment #8)

> I would suggest the installer won't offer default passwords and force
> entering either: ssh-key or password. (in case of choosing ssh-key the
> generated password should be randomize)

we can't do blank password, afaik, due to foreman limitations.

Comment 12 Mike Burns 2014-07-03 09:01:12 UTC
installer now generates a random password during install and prompts the user to change it during the install process.

Comment 19 Ido Ovadia 2014-08-06 10:48:49 UTC
Verified
========
rhel-osp-installer-0.1.6-5.el6ost.noarch

Comment 21 errata-xmlrpc 2014-08-21 18:04:31 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.

http://rhn.redhat.com/errata/RHBA-2014-1090.html


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