mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-11-07 12:52:54 -05:00
Added more user permissions removal. #3065
This commit is contained in:
@@ -874,7 +874,7 @@ function handleServerCommand(data) {
|
||||
case 'msg': {
|
||||
switch (data.type) {
|
||||
case 'console': { // Process a console command
|
||||
if ((typeof data.rights != 'number') || ((data.rights & 16) == 0)) break; // Check console rights
|
||||
if ((typeof data.rights != 'number') || ((data.rights & 8) == 0) || ((data.rights & 16) == 0)) break; // Check console rights (Remote Control and Console)
|
||||
if (data.value && data.sessionid) {
|
||||
MeshServerLogEx(17, [data.value], "Processing console command: " + data.value, data);
|
||||
var args = splitArgs(data.value);
|
||||
|
||||
@@ -911,7 +911,7 @@ require('MeshAgent').AddCommandHandler(function (data) {
|
||||
{
|
||||
switch (data.type) {
|
||||
case 'console': { // Process a console command
|
||||
if ((typeof data.rights != 'number') || ((data.rights & 16) == 0)) break; // Check console rights
|
||||
if ((typeof data.rights != 'number') || ((data.rights & 8) == 0) || ((data.rights & 16) == 0)) break; // Check console rights (Remote Control and Console)
|
||||
if (data.value && data.sessionid) {
|
||||
var args = splitArgs(data.value);
|
||||
processConsoleCommand(args[0].toLowerCase(), parseArgs(args), data.rights, data.sessionid);
|
||||
|
||||
Reference in New Issue
Block a user