MSHTA
MSHTA code execution - bypass application whitelisting.
Execution
Writing a scriptlet file that will launch calc.exe when invoked:
http://10.0.0.5/m.sct
Invoking the scriptlet file hosted remotely:
attacker@victim
Observations
As expected, calc.exe is spawned by mshta.exe. Worth noting that mhsta and cmd exit almost immediately after invoking the calc.exe:
As a defender, look at sysmon logs for mshta establishing network connections:
Also, suspicious commandlines:
Bonus
The hta file can be invoked like so:
or by navigating to the file itself, launching it and clicking run:
http://10.0.0.5/m.hta
References
Last updated