diff --git a/actions/actions b/actions/actions index 9264b5cfe..e012b4b3c 100755 --- a/actions/actions +++ b/actions/actions @@ -62,9 +62,6 @@ def main(): def _call(module_name, action_name, arguments): """Import the module and run action as superuser""" - if os.getuid() != 0: - raise PermissionError('This action is reserved for root') - if '.' in module_name: raise SyntaxError('Invalid module name') diff --git a/plinth/tests/test_actions_actions.py b/plinth/tests/test_actions_actions.py index 76802f111..05c18b20c 100644 --- a/plinth/tests/test_actions_actions.py +++ b/plinth/tests/test_actions_actions.py @@ -22,11 +22,6 @@ def test_call_syntax_checks(getuid, get_module_import_path, import_module, """Test that calling a method results in proper syntax checks.""" call = actions_module._call - # Test for root permissions - getuid.return_value = 1000 - with pytest.raises(PermissionError): - call('x-module', 'x-action', {}) - # Module name validation getuid.return_value = 0 with pytest.raises(SyntaxError, match='Invalid module name'):