mirror of
https://github.com/serghey-rodin/vesta.git
synced 2025-08-14 18:49:17 -07:00
password transmission via tmp files
This commit is contained in:
parent
1021bd4ab2
commit
1a7612cc66
14 changed files with 172 additions and 87 deletions
|
@ -47,7 +47,6 @@ if (!empty($_POST['ok'])) {
|
|||
|
||||
// Protect input
|
||||
$v_username = escapeshellarg($_POST['v_username']);
|
||||
$v_password = escapeshellarg($_POST['v_password']);
|
||||
$v_email = escapeshellarg($_POST['v_email']);
|
||||
$v_package = escapeshellarg($_POST['v_package']);
|
||||
$v_language = escapeshellarg($_POST['v_language']);
|
||||
|
@ -58,9 +57,15 @@ if (!empty($_POST['ok'])) {
|
|||
|
||||
// Add user
|
||||
if (empty($_SESSION['error_msg'])) {
|
||||
$v_password = tempnam("/tmp","vst");
|
||||
$fp = fopen($v_password, "w");
|
||||
fwrite($fp, $_POST['v_password']."\n");
|
||||
fclose($fp);
|
||||
exec (VESTA_CMD."v-add-user ".$v_username." ".$v_password." ".$v_email." ".$v_package." ".$v_fname." ".$v_lname, $output, $return_var);
|
||||
check_return_code($return_var,$output);
|
||||
unset($output);
|
||||
unlink($v_password);
|
||||
$v_password = escapeshellarg($_POST['v_password']);
|
||||
}
|
||||
|
||||
// Set language
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue