aboutsummaryrefslogtreecommitdiff
path: root/app/install.php
diff options
context:
space:
mode:
authorGravatar Alexandre Alapetite <alexandre@alapetite.fr> 2016-01-26 19:34:56 +0100
committerGravatar Alexandre Alapetite <alexandre@alapetite.fr> 2016-01-26 19:34:56 +0100
commit56a80af242a45c40d2cc710db39d4b66633b81df (patch)
tree407430d8ea3bbbb39effbc02d1196e119c025fc4 /app/install.php
parent1d4c9d3b3daa321d601ee74275e3dbd93d3b9a4d (diff)
parentdfd0b9e9355c1e44e72b95583dd5e730f0ad5230 (diff)
Merge branch 'array_replace_recursive' into dev
Diffstat (limited to 'app/install.php')
-rw-r--r--app/install.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/install.php b/app/install.php
index 83526b60c..7ac1c4cec 100644
--- a/app/install.php
+++ b/app/install.php
@@ -130,7 +130,7 @@ function saveStep2() {
$_SESSION['mail_login'] = filter_var(param('mail_login', ''), FILTER_VALIDATE_EMAIL);
$password_plain = param('passwordPlain', false);
- if ($password_plain !== false) {
+ if ($password_plain !== false && cryptAvailable()) {
if (!function_exists('password_hash')) {
include_once(LIB_PATH . '/password_compat.php');
}
@@ -681,10 +681,10 @@ function printStep2() {
}
$auth_type = isset($_SESSION['auth_type']) ? $_SESSION['auth_type'] : '';
?>
- <option value="form"<?php echo $auth_type === 'form' || no_auth($auth_type) ? ' selected="selected"' : '', cryptAvailable() ? '' : ' disabled="disabled"'; ?>><?php echo _t('install.auth.form'); ?></option>
+ <option value="form"<?php echo $auth_type === 'form' || (no_auth($auth_type) && cryptAvailable()) ? ' selected="selected"' : '', cryptAvailable() ? '' : ' disabled="disabled"'; ?>><?php echo _t('install.auth.form'); ?></option>
<option value="persona"<?php echo $auth_type === 'persona' ? ' selected="selected"' : ''; ?>><?php echo _t('install.auth.persona'); ?></option>
<option value="http_auth"<?php echo $auth_type === 'http_auth' ? ' selected="selected"' : '', httpAuthUser() == '' ? ' disabled="disabled"' : ''; ?>><?php echo _t('install.auth.http'); ?>(REMOTE_USER = '<?php echo httpAuthUser(); ?>')</option>
- <option value="none"<?php echo $auth_type === 'none' ? ' selected="selected"' : ''; ?>><?php echo _t('install.auth.none'); ?></option>
+ <option value="none"<?php echo $auth_type === 'none' || (no_auth($auth_type) && !cryptAvailable()) ? ' selected="selected"' : ''; ?>><?php echo _t('install.auth.none'); ?></option>
</select>
</div>
</div>