diff options
author | Simon Rettberg | 2022-07-01 17:50:57 +0200 |
---|---|---|
committer | Simon Rettberg | 2022-07-01 17:50:57 +0200 |
commit | 44558ebd2e97421496e4639ea1fe405b87b5abd8 (patch) | |
tree | a11535849dc079bd70df74d0a423ac8c3ec0f7ac /modules-available | |
parent | [inc/Session] Add call to save session data (diff) | |
download | slx-admin-44558ebd2e97421496e4639ea1fe405b87b5abd8.tar.gz slx-admin-44558ebd2e97421496e4639ea1fe405b87b5abd8.tar.xz slx-admin-44558ebd2e97421496e4639ea1fe405b87b5abd8.zip |
[rebootcontrol] Fix permission check
Diffstat (limited to 'modules-available')
-rw-r--r-- | modules-available/rebootcontrol/inc/rebootcontrol.inc.php | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/modules-available/rebootcontrol/inc/rebootcontrol.inc.php b/modules-available/rebootcontrol/inc/rebootcontrol.inc.php index 94ac7665..36b2b14f 100644 --- a/modules-available/rebootcontrol/inc/rebootcontrol.inc.php +++ b/modules-available/rebootcontrol/inc/rebootcontrol.inc.php @@ -151,7 +151,7 @@ class RebootControl * @param string $command Command or script to execute on client * @param int $timeout in seconds * @param string|false $privkey SSH private key to use to connect - * @return array|false + * @return array|false task struct, false on error */ public static function runScript(array $clients, string $command, int $timeout = 5, $privkey = false) { @@ -451,9 +451,9 @@ class RebootControl public static function prepareExec() { - User::assertPermission('action.exec'); + User::assertPermission('.rebootcontrol.action.exec'); $uuids = array_values(Request::post('uuid', Request::REQUIRED, 'array')); - $machines = RebootUtils::getFilteredMachineList($uuids, 'action.exec'); + $machines = RebootUtils::getFilteredMachineList($uuids, '.rebootcontrol.action.exec'); if ($machines === false) return; $id = mt_rand(); |