diff options
-rw-r--r-- | data/interactive-defaults.ks | 1 | ||||
-rw-r--r-- | pyanaconda/ui/gui/spokes/password.py | 12 |
2 files changed, 4 insertions, 9 deletions
diff --git a/data/interactive-defaults.ks b/data/interactive-defaults.ks index 0046cc3f2..f692ccdc8 100644 --- a/data/interactive-defaults.ks +++ b/data/interactive-defaults.ks @@ -2,4 +2,3 @@ # This is not loaded if a kickstart file is provided on the command line. auth --enableshadow --passalgo=sha512 firstboot --enable -rootpw --lock diff --git a/pyanaconda/ui/gui/spokes/password.py b/pyanaconda/ui/gui/spokes/password.py index 9f5d4d93f..74acd4e3a 100644 --- a/pyanaconda/ui/gui/spokes/password.py +++ b/pyanaconda/ui/gui/spokes/password.py @@ -55,8 +55,6 @@ class PasswordSpoke(NormalSpoke): def initialize(self): NormalSpoke.initialize(self) - # Set the rootpw to locked by default, setting a password is optional - self.data.rootpw.lock = True # place holders for the text boxes self.pw = self.builder.get_object("pw") self.confirm = self.builder.get_object("confirm") @@ -77,10 +75,12 @@ class PasswordSpoke(NormalSpoke): def status(self): if self._error: return _("Error setting root password") + if self.data.rootpw.password: + return _("Root password is set") elif self.data.rootpw.lock: return _("Root account is disabled") else: - return _("Root password is set") + return _("Root password is not set") def apply(self): if self._password: @@ -95,11 +95,7 @@ class PasswordSpoke(NormalSpoke): @property def completed(self): - # FUTURE -- update completed to false if package payload doesn't - # include firstboot and some environment to run it in - # We are by default complete, but locked. If a user attempts to set - # a password but fails, then we are no longer complete. - return not self._error + return bool(self.data.rootpw.password or self.data.rootpw.lock) def _validatePassword(self): # Do various steps to validate the password |