Add a warning to warn about security leak
This commit is contained in:
parent
76fc8330a3
commit
a4fb16b4f3
@ -376,8 +376,7 @@ foreach ($configfileparameters as $key => $value)
|
||||
print "<td>";
|
||||
if ($newkey == 'dolibarr_main_db_pass') print preg_replace('/./i', '*', ${$newkey});
|
||||
elseif ($newkey == 'dolibarr_main_url_root' && preg_match('/__auto__/', ${$newkey})) print ${$newkey}.' => '.constant('DOL_MAIN_URL_ROOT');
|
||||
elseif ($newkey == 'dolibarr_main_document_root_alt')
|
||||
{
|
||||
elseif ($newkey == 'dolibarr_main_document_root_alt') {
|
||||
$tmparray = explode(',', ${$newkey});
|
||||
$i = 0;
|
||||
foreach ($tmparray as $value2)
|
||||
@ -391,9 +390,7 @@ foreach ($configfileparameters as $key => $value)
|
||||
}
|
||||
++$i;
|
||||
}
|
||||
}
|
||||
elseif ($newkey == 'dolibarr_main_instance_unique_id')
|
||||
{
|
||||
} elseif ($newkey == 'dolibarr_main_instance_unique_id') {
|
||||
//print $conf->file->instance_unique_id;
|
||||
global $dolibarr_main_cookie_cryptkey;
|
||||
$valuetoshow = ${$newkey} ? ${$newkey} : $dolibarr_main_cookie_cryptkey; // Use $dolibarr_main_instance_unique_id first then $dolibarr_main_cookie_cryptkey
|
||||
@ -402,9 +399,14 @@ foreach ($configfileparameters as $key => $value)
|
||||
print img_warning("EditConfigFileToAddEntry", 'dolibarr_main_instance_unique_id');
|
||||
}
|
||||
print ' <span class="opacitymedium">('.$langs->trans("HashForPing").'='.md5('dolibarr'.$valuetoshow).')</span>';
|
||||
}
|
||||
else
|
||||
{
|
||||
} elseif ($newkey == 'dolibarr_main_prod') {
|
||||
print ${$newkey};
|
||||
|
||||
$valuetoshow = ${$newkey};
|
||||
if (empty($valuetoshow)) {
|
||||
print img_warning($langs->trans('SwitchThisForABetterSecurity'));
|
||||
}
|
||||
} else {
|
||||
print ${$newkey};
|
||||
}
|
||||
if ($newkey == 'dolibarr_main_url_root' && ${$newkey} != DOL_MAIN_URL_ROOT) print ' (currently overwritten by autodetected value: '.DOL_MAIN_URL_ROOT.')';
|
||||
|
||||
@ -2022,3 +2022,4 @@ MeasuringScaleDesc=The scale is the number of places you have to move the decima
|
||||
TemplateAdded=Template added
|
||||
TemplateUpdated=Template updated
|
||||
TemplateDeleted=Template deleted
|
||||
SwitchThisForABetterSecurity=Switching this value to 1 is recommended for more security
|
||||
|
||||
Loading…
Reference in New Issue
Block a user