diff options
Diffstat (limited to 'core/command/user/resetpassword.php')
-rw-r--r-- | core/command/user/resetpassword.php | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/core/command/user/resetpassword.php b/core/command/user/resetpassword.php index d7893c291e4..10a21960849 100644 --- a/core/command/user/resetpassword.php +++ b/core/command/user/resetpassword.php @@ -48,6 +48,16 @@ class ResetPassword extends Command { if ($input->isInteractive()) { /** @var $dialog \Symfony\Component\Console\Helper\DialogHelper */ $dialog = $this->getHelperSet()->get('dialog'); + + if (\OCP\App::isEnabled('files_encryption')) { + $output->writeln( + '<error>Warning: Resetting the password when using encryption will result in data loss!</error>' + ); + if (!$dialog->askConfirmation($output, '<question>Do you want to continue?</question>', true)) { + return 1; + } + } + $password = $dialog->askHiddenResponse( $output, '<question>Enter a new password: </question>', |