diff options
author | Simon Rettberg | 2022-06-10 11:42:18 +0200 |
---|---|---|
committer | Simon Rettberg | 2022-06-10 11:42:18 +0200 |
commit | a9d4093a4f4d139b306d4018c8ce7bb6d6636206 (patch) | |
tree | 2c32bb2eb7761e433fc20e25214a34a3ecdecdb8 /modules-available/rebootcontrol | |
parent | [rebootcontrol] Show error message if user has no action.* permission (diff) | |
download | slx-admin-a9d4093a4f4d139b306d4018c8ce7bb6d6636206.tar.gz slx-admin-a9d4093a4f4d139b306d4018c8ce7bb6d6636206.tar.xz slx-admin-a9d4093a4f4d139b306d4018c8ce7bb6d6636206.zip |
[rebootcontrol] Add dedicated permission to view wol/reboot/exec jobs
Closes #3909
Diffstat (limited to 'modules-available/rebootcontrol')
4 files changed, 8 insertions, 1 deletions
diff --git a/modules-available/rebootcontrol/lang/de/permissions.json b/modules-available/rebootcontrol/lang/de/permissions.json index fb32225d..589db5b9 100644 --- a/modules-available/rebootcontrol/lang/de/permissions.json +++ b/modules-available/rebootcontrol/lang/de/permissions.json @@ -2,6 +2,7 @@ "action.exec": "Befehle als root auf laufenden Clients ausf\u00fchren.", "action.reboot": "Client neustarten.", "action.shutdown": "Client herunterfahren.", + "action.view": "Laufende WOL\/Reboot\/Exec-Tasks sehen.", "action.wol": "Client per WOL starten.", "jumphost.assign-subnet": "Einem Sprung-Host ein Subnetz zuweisen.", "jumphost.edit": "Einen Sprung-Host bearbeiten.", @@ -11,4 +12,4 @@ "subnet.flag": "Eigenschaften eines Subnetzes bearbeiten.", "subnet.view": "Liste der Subnetze sehen.", "woldiscover": "Automatische Ermittlung von subnetz\u00fcbergreifender WOL-F\u00e4higkeit." -} +}
\ No newline at end of file diff --git a/modules-available/rebootcontrol/lang/en/permissions.json b/modules-available/rebootcontrol/lang/en/permissions.json index f5144d18..b925c2b2 100644 --- a/modules-available/rebootcontrol/lang/en/permissions.json +++ b/modules-available/rebootcontrol/lang/en/permissions.json @@ -2,6 +2,7 @@ "action.exec": "Execute commands on clients (as root).", "action.reboot": "Reboot Client.", "action.shutdown": "Shutdown Client.", + "action.view": "See running WOL\/reboot\/exec jobs.", "action.wol": "Send WOL packet to client.", "jumphost.assign-subnet": "Assign subnet to jump host.", "jumphost.edit": "Edit jump host.", diff --git a/modules-available/rebootcontrol/pages/task.inc.php b/modules-available/rebootcontrol/pages/task.inc.php index 933c7721..b3110c66 100644 --- a/modules-available/rebootcontrol/pages/task.inc.php +++ b/modules-available/rebootcontrol/pages/task.inc.php @@ -26,6 +26,8 @@ class SubPage private static function showTask() { + // No permission check here - user had to guess the UUID, not very likely, + // but this way we can still link to some implicitly triggered job $taskid = Request::get("taskid", Request::REQUIRED, 'string'); $type = Request::get('type', false, 'string'); if ($type === 'checkhost') { diff --git a/modules-available/rebootcontrol/permissions/permissions.json b/modules-available/rebootcontrol/permissions/permissions.json index 5416a482..a508f8b6 100644 --- a/modules-available/rebootcontrol/permissions/permissions.json +++ b/modules-available/rebootcontrol/permissions/permissions.json @@ -34,5 +34,8 @@ }, "action.exec": { "location-aware": true + }, + "action.view": { + "location-aware": true } }
\ No newline at end of file |