This time we have identified the use of the latest version of the remote desktop activeX control class that was introduced for Windows 10. The attackers utilize the activeX control for automatic execution of the malicious Macro following an enable of the Document content.
As newer features are introduced to a constantly updating OS, so too the detection vendors need to update their techniques to protect the system. This may become very exhausting and time–consuming work, which can lead to the opposite effect of pushing defenders even farther behind the attacker. Trickbot distributors have yet again taken advantage of the opportunity this change presents.
While tracing this group abusing the remote activeX control we also identified other groups misusing the same and earlier controls although with a slightly different technique.
Examining the activeX control revealed the use of the MsRdpClient10NotSafeForScripting class (which is used for remote control). The Server field is empty in the script, which will later cause an error that the attackers will actually abuse to properly execute their own code.
Inspection of the macro revealed an interesting trigger method — “<name>_OnDisconnected” — which will be the main function that is first executed. This method didn’t execute immediately as it takes time for it to try and resolve DNS to an empty string and then return an error. The OSTAP will not execute unless the error number matches exactly to “disconnectReasonDNSLookupFailed” (260); the OSTAP wscript command is concatenated with a combination of characters that are dependent on the error number calculation.
Going over the documentation for the msrdpclient10 reveals that it will not work on workstations that are not updated to windows 10.
As soon as OSTAP is created in the form of a BAT file, this file is executed, and the word document form is closed.
The BAT will execute wscript back with its own content — an old trick using comments that the BAT will disregard during the execution of wscript (non-recognized command) while skipped together with its content when executed by wscript (or any other interpreter that adheres to the comments syntax).
Updating your operating system is necessary for better security, even though it doesn’t always serve that purpose. This example with OSTAP makes it clear that this doesn’t always work. Even with an updated OS, there remains a need for preventive measures such as attack surface reduction, moving target defense, and hardening.
There are hundreds more objects that have been introduced in the latest Windows 10 and even dozens more methods in the described object that sophisticated attackers can abuse. There might also be opportunities for vulnerability exploitation with every new feature but this is not in the scope of this blog post.
*** This is a Security Bloggers Network syndicated blog from Morphisec Moving Target Defense Blog authored by Michael Gorelik. Read the original post at: https://blog.morphisec.com/trickbot-delivery-method-gets-a-new-upgrade-focusing-on-windows