forked from p15670423/monkey
Agent: Refactor MSSQL create directory commands
Use _run_mssql_command() and remove the dependency on MSSQLLimitedSizePayload.
This commit is contained in:
parent
7b356cf893
commit
522e62ad14
|
@ -103,10 +103,9 @@ class MSSQLExploiter(HostExploiter):
|
|||
|
||||
def create_temp_dir(self):
|
||||
logger.debug(f"Creating a temporary directory: {MSSQLExploiter.TMP_DIR_PATH}")
|
||||
dir_creation_command = MSSQLLimitedSizePayload(
|
||||
command="mkdir {}".format(MSSQLExploiter.TMP_DIR_PATH)
|
||||
)
|
||||
self.run_mssql_command(dir_creation_command)
|
||||
|
||||
mkdir_command = f"mkdir {MSSQLExploiter.TMP_DIR_PATH}"
|
||||
self._run_mssql_command(mkdir_command)
|
||||
|
||||
def run_mssql_command(self, mssql_command):
|
||||
array_of_commands = mssql_command.split_into_array_of_smaller_payloads()
|
||||
|
|
Loading…
Reference in New Issue