fix escaping in smbexec
parent
5ec969c733
commit
1b97cebac3
|
@ -114,7 +114,7 @@ class SMBEXEC:
|
|||
self.__batchFile = gen_random_string(6) + ".bat"
|
||||
|
||||
if self.__retOutput:
|
||||
command = self.__shell + "echo " + data + f" ^> \\\\127.0.0.1\\{self.__share_name}\\{self.__output} 2^>^&1 > %TEMP%\\{self.__batchFile} & %COMSPEC% /Q /c %TEMP%\{self.__batchFile} & %COMSPEC% /Q /c del %TEMP%\\{self.__batchFile}"
|
||||
command = self.__shell + "echo " + data + f" ^> \\\\127.0.0.1\\{self.__share_name}\\{self.__output} 2^>^&1 > %TEMP%\\{self.__batchFile} & %COMSPEC% /Q /c %TEMP%\\{self.__batchFile} & %COMSPEC% /Q /c del %TEMP%\\{self.__batchFile}"
|
||||
else:
|
||||
command = self.__shell + data
|
||||
|
||||
|
|
Loading…
Reference in New Issue