New: Can show full password on restore option
This commit is contained in:
parent
1aba0ab93a
commit
049948f89e
@ -117,8 +117,8 @@ if (! empty($_GET["radio_dump"])) print "document.getElementById('mysql_options'
|
||||
print '<br>';
|
||||
print '<textarea rows="1" cols="120">'.$langs->trans("ImportMySqlCommand",$command,$_GET["showpass"]?$paramclear:$paramcrypted).'</textarea><br>';
|
||||
|
||||
if ($_GET["showpass"]) print '<br><a href="'.$_SERVER["PHP_SELF"].'?showpass=0&radio_dump=mysql_options">'.$langs->trans("HidePassword").'</a>';
|
||||
else print '<br><a href="'.$_SERVER["PHP_SELF"].'?showpass=1&radio_dump=mysql_options">'.$langs->trans("UnHidePassword").'</a>';
|
||||
if (empty($_GET["showpass"])) print '<br><a href="'.$_SERVER["PHP_SELF"].'?showpass=1&radio_dump=mysql_options">'.$langs->trans("UnHidePassword").'</a>';
|
||||
//else print '<br><a href="'.$_SERVER["PHP_SELF"].'?showpass=0&radio_dump=mysql_options">'.$langs->trans("HidePassword").'</a>';
|
||||
print '</div>';
|
||||
|
||||
?>
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
<?php
|
||||
/* Copyright (C) 2006 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
/* Copyright (C) 2006-2008 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -89,10 +89,13 @@ if ($what == 'mysql')
|
||||
create_exdir(DOL_DATA_ROOT.'/admin/temp');
|
||||
|
||||
// Parameteres execution
|
||||
$command=escapeshellarg($mysqldump);
|
||||
$command=$mysqldump;
|
||||
if (eregi(" ",$command)) $command=$command=escapeshellarg($command); // Use quotes on command
|
||||
|
||||
//$param=escapeshellarg($dolibarr_main_db_name)." -h ".escapeshellarg($dolibarr_main_db_host)." -u ".escapeshellarg($dolibarr_main_db_user)." -p".escapeshellarg($dolibarr_main_db_pass);
|
||||
$param=$dolibarr_main_db_name." -h ".$dolibarr_main_db_host;
|
||||
$param.=" -u ".$dolibarr_main_db_user;
|
||||
if (! empty($dolibarr_main_db_port)) $param.=" -P ".$dolibarr_main_db_port;
|
||||
$compression=isset($_POST['compression']) ? $_POST['compression'] : 'none';
|
||||
if (! $_POST["use_transaction"]) $param.=" -l --single-transaction";
|
||||
if ($_POST["disable_fk"]) $param.=" -K";
|
||||
|
||||
@ -96,7 +96,7 @@ if ($result)
|
||||
$num = $db->num_rows($result);
|
||||
$i = 0;
|
||||
|
||||
print_barre_liste($langs->trans("ListOfSecurityEvents"), $page, "listevents.php","",$sortfield,$sortorder,'',$num);
|
||||
print_barre_liste($langs->trans("ListOfSecurityEvents"), $page, "listevents.php","",$sortfield,$sortorder,'',$num,0,'setup');
|
||||
|
||||
if ($_GET["action"] == 'purge')
|
||||
{
|
||||
|
||||
@ -461,6 +461,8 @@ DisabledModules=Disabled modules
|
||||
For=For
|
||||
ForCustomer=For customer
|
||||
Signature=Signature
|
||||
HidePassword=Show command with password hidden
|
||||
UnHidePassword=Show real command with clear password
|
||||
# Week day
|
||||
Monday=Monday
|
||||
Tuesday=Tuesday
|
||||
|
||||
@ -462,6 +462,8 @@ DisabledModules=Modules d
|
||||
For=Pour
|
||||
ForCustomer=Pour le client
|
||||
Signature=Sign
|
||||
HidePassword=Afficher commande avec mot de passe masqué
|
||||
UnHidePassword=Afficher commande réelle avec mot de passe en clair
|
||||
# Week day
|
||||
Monday=Lundi
|
||||
Tuesday=Mardi
|
||||
|
||||
@ -193,8 +193,8 @@ if (! defined('NOREQUIREDB'))
|
||||
}
|
||||
}
|
||||
// Now database connexion is known we can forget password
|
||||
$dolibarr_main_db_pass='';
|
||||
$conf->db->pass='';
|
||||
//$dolibarr_main_db_pass=''; // Comment this because pass is used in a lot of pages
|
||||
$conf->db->pass=''; // This is to avoir password to be shown in dump
|
||||
|
||||
/*
|
||||
* Creation objet $user
|
||||
|
||||
Loading…
Reference in New Issue
Block a user