diff --git a/admin_customers.php b/admin_customers.php index edc0577c..5056d4ea 100644 --- a/admin_customers.php +++ b/admin_customers.php @@ -632,7 +632,7 @@ if ($page == 'customers' } if ($password == '') { - $password = substr(md5(uniqid(microtime(), 1)), 12, 6); + $password = generatePassword(); } $_theme = Settings::Get('panel.default_theme'); diff --git a/scripts/jobs/cron_tasks.php b/scripts/jobs/cron_tasks.php index 395c91e3..d1e2f657 100644 --- a/scripts/jobs/cron_tasks.php +++ b/scripts/jobs/cron_tasks.php @@ -98,7 +98,11 @@ while ($row = $result_tasks_stmt->fetch(PDO::FETCH_ASSOC)) { && !in_array(Settings::Get('system.httpuser'), $groupinfo['members']) ) { // webserver has no access, add it - safe_exec('usermod -a -G ' . escapeshellarg(Settings::Get('phpfpm.vhost_httpgroup'))." ".escapeshellarg(Settings::Get('system.httpuser'))); + if (isFreeBSD()) { + safe_exec('pw user mod '.escapeshellarg(Settings::Get('system.httpuser')).' -G '.escapeshellarg(Settings::Get('phpfpm.vhost_httpgroup'))); + } else { + safe_exec('usermod -a -G ' . escapeshellarg(Settings::Get('phpfpm.vhost_httpgroup')).' '.escapeshellarg(Settings::Get('system.httpuser'))); + } } }