Security

Research

Bad apps bypass Windows security alerts for six years using newly unveiled trick

Windows SmartScreen and Smart App Control both have weaknesses of which to be wary


Elastic Security Labs has lifted the lid on a slew of methods available to attackers who want to run malicious apps without triggering Windows' security warnings, including one in use for six years.

The research focused on ways to bypass Windows SmartScreen and Smart App Control (SAC), the go-to built-in protections against running potentially nasty software downloaded from the web in Windows 8 and 11 respectively.

Among the techniques uncovered by Joe Desimone, tech lead at Elastic, was one he dubbed "LNK Stomping," a bug in the way Windows shortcut files (.LNK) are handled that nullifies Windows' Mark of the Web (MotW) – a digital tag placed on downloaded files that could be malicious if executed.

SmartScreen only scans files that are tagged with MotW and SAC is set up to block certain file types if they're marked, so any method that can circumvent MotW will naturally be a boon to malware miscreants.

This is far from the first MotW bypass technique that's been introduced over the years, but the fact it has been in use for so long and, as Desimone said, is "trivial" to exploit, makes it worth defenders taking some time to understand how it works.

But that's all that is on offer so far: understanding. The researcher said Elastic engaged Microsoft about mitigation and the tech giant said the it might be fixed at a later date – no patching promises here.

This "trivial" technique involves crafting LNK files with non-standard target paths or internal structures. This forces Windows Explorer to correct these small errors before launching the malicious app, but in the process of correcting these errors, MotW is removed, which means SmartScreen and SAC don't flag it as malicious.

Desimone said the easiest way to trigger this bug is to simply append a period or a space somewhere in the target executable path. Something like target.exe. would work, as would .\target.exe, for example.

Windows Explorer then recognizes the error in the target path and searches for the real executable, corrects the target path, and updates the file which in turn removes MotW.

"We identified multiple samples in VirusTotal that exhibit the bug, demonstrating existing in the wild usage," said Desimone. "The oldest sample identified was submitted over six years ago. 

"We also disclosed details of the bug to the MSRC. It may be fixed in a future Windows update. We are releasing this information, along with detection logic and countermeasures, to help defenders identify this activity until a patch is available."

In the meantime, security pros are advised to adjust their detection engineering in line with the coverage gaps that are on display by SmartScreen and SAC.

Other bypasses

SmartScreen and SAC are both reputation-based protections, and the historically tried and tested, yet difficult to execute, method of bypassing these was to sign a malicious app with a code-signing certificate.

In theory, these should be difficult to acquire given that certificate authorities should only be issuing these to legitimate businesses, although it's still very much a viable practice.

Desimone also highlighted a number of other methods for bypassing reputation-based protections, including one technique he called Reputation Hijacking, which involves identifying an existing program with a good reputation and meddling with it for malicious means.

The researcher said script hosts are ideal for this kind of attack, although any app that's controlled without any common line parameters would work. If it includes a foreign function interface (FFI) capability, even better, because this can be used to load bad code into memory. Lua, Node.js, and AutoHotkey interpreters are ideal targets for repurposing here, he said.

Reputation Seeding appears to work best with SAC. SmartScreen sets a higher threshold before trusting an application, Desimone said. This attack involves an attacker dropping a binary that appears trustworthy but can be exploited at a later time, such as when certain conditions are met. It could also contain a vulnerability an attacker can exploit later on, for example.

Lastly, Desimone said Reputation Tampering is also an option. This method involves carefully changing specific code sections of apps that are deemed benign by SAC in a way that lends support for an attack, all while maintaining their benign reputation.

"Through trial and error, we could identify segments that could be safely tampered with and keep the same reputation. We crafted one tampered binary with a unique hash that had never been seen by Microsoft or SAC. This embedded an 'execute calc' shellcode and could be executed with SAC in enforcement mode," the Elastic tech lead said. ®

Send us news
16 Comments

How Windows got to version 3 – an illustrated history

With added manga and snark. What's not to like?

FBI wipes Chinese PlugX malware from thousands of Windows PCs in America

Hey, Xi: Zài jiàn!

Microsoft preps for a year of enterprise-impacting M365 retirements

Hey administrators – buckle up. 2025 is going to be a wild ride

Japanese police claim China ran five-year cyberattack campaign targeting local orgs

‘MirrorFace’ group found ways to run malware in the Windows sandbox, which may be worrying

Microsoft declares 2025 'the year of the Windows 11 PC refresh'

Slumping market share, unwanted features ... no, it's the consumers who are wrong!

Security pros baited with fake Windows LDAP exploit traps

Tricky attackers trying yet again to deceive the good guys on home territory

How the OS/2 flop went on to shape modern software

Even Microsoft's lead architect misunderstood the failure

Microsoft fixes under-attack privilege-escalation holes in Hyper-V

Plus: Excel hell, angst for Adobe fans, and life's too Snort for Cisco

Where does Microsoft's NPU obsession leave Nvidia's AI PC ambitions?

While Microsoft pushes AI PC experiences, Nvidia is busy wooing developers

Microsoft tests 45% M365 price hikes in Asia-Pacific to see how much you enjoy AI

Won’t say if other nations will be hit, but will ‘listen, learn, and improve’ as buyers react – so far with anger

Windows Insiders can now turn on Administrator Protection from settings

Security feature widens out to more Windows 11 users, including those at home

Microsoft sues 'foreign-based' cyber-crooks, seizes sites used to abuse AI

Scumbags stole API keys, then started a hacking-as-a-service biz, it is claimed