From 3ef41ac7d28e5ea8b7fba5552fb827efae33730f Mon Sep 17 00:00:00 2001 From: antonioCoco Date: Fri, 1 Oct 2021 20:16:58 +0200 Subject: [PATCH] fixed a bug in argument parsing in runas module --- modules/runas.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modules/runas.py b/modules/runas.py index 3e95201..a449f14 100644 --- a/modules/runas.py +++ b/modules/runas.py @@ -335,6 +335,8 @@ class Runas(Module): domain = args_parser.get(3, self.__default_domain) process_ms_timeout = args_parser.get(4, self.__default_process_ms_timeout) logon_type = args_parser.get(5, self.__default_logon_type) + if process_ms_timeout == '' or logon_type == '': + raise self._exception_class('#runas: process_ms_timeout and logon_type field cannot be empty.\n') return cmd, username, password, domain,process_ms_timeout, logon_type def _create_request(self, args):