Home Cyber Security News MacOS Zero-Day Vulnerability Allows Synthetic Mouse-Click Attacks

MacOS Zero-Day Vulnerability Allows Synthetic Mouse-Click Attacks

by Abeerah Hashim
mouse-click attacks

While the majority of people consider Apple a paradigm of online security, researchers are proving this wrong. Amidst all the exciting reports from the Black Hat USA and Def Con 2018 events, we also received some interesting news regarding Apple vulnerabilities. Initially, we came to know about MDM vulnerability that allowed hacking Macs right out the box. This time, we share another report about a zero-day MacOS vulnerability that allows hackers to infect Macs via ‘synthetic’ mouse-click attacks.

Zero-Day Flaw Allows Hackers Access With Simulated Mouse-Click Attacks

The researcher Patrick Wardle from Digita Security delivered a presentation at DEF CON 2018, revealing a zero-day Apple vulnerability. He explained how a Mac OS flaw lets hackers remotely infect a Mac via synthetic mouse-click attacks. This vulnerability could actually permit the attacker to click a security prompt virtually and load the payload to the infected system.

Wardle discovered this flaw while he was trying to copy and paste some code.

“I was just kind of goofing around with this feature. I copied and pasted the code for a synthetic mouse down twice accidentally – forgetting to change a value of a flag that would indicate a mouse “up” event. Without realizing my ‘mistake,’ I compiled and ran the code, and honestly was rather surprised when it generated an allowed synthetic click!”

After the possibility of synthetic mouse-click attacks was made known, Apple patched the flaw by adding security prompts in UI. Macs now ask permission from the users prior allowing any apps to run. This way, Macs prevent malware and malicious apps from running automatically on the system.

Synthetic clicks are allowed by Mac OS for some programs such as AppleScript, Wardle said that the Mac OS also allows synthetic clicks on prompts seeking permission to access calendar, contacts, location recording, and network identification. It is because of the vulnerability in Mac OS that reads two consecutive mouse “down” events as a manual approval with a “down” and “up”.

“For some unknown reason the two synthetic mouse ‘down’ events confuse the system and the OS sees it as a legitimate click. This fully breaks a foundational security mechanism of High Sierra.”

Mac OS Will Ditch Synthetic Clicks In ‘Mojave’

According to Wardle, the vulnerability (CVE-2017-7150) affected all latest Mac OS versions that allowed code interaction with UI components. Although Apple released a patch by introducing ‘User Assisted Kernel Extension Loading (Kext)’, Wardle calls it “incomplete”. The newly discovered zero-day vulnerability could easily bypass Kext owing to Mac’s incorrect interpretation of clicks.

“Armed with the bug, it was trivial to programmatically bypass Apple’s touted ‘User-Approved Kext’ security feature, dump all passwords from the keychain, bypass 3rd-party security tools, and much more! And as Apple’s patch was incomplete (surprise surprise) we’ll drop a 0day that (still) allows unprivileged code to post synthetic events and bypass various security mechanisms on a fully patched macOS box.”

Considering the dangers associated with this trivial yet harmful bug, Wardle states that Apple will entirely ditch the flawed feature. The upcoming version of Mac OS ‘Mojave’ will block all synthetic events. Although it will cause a problem for  legitimate apps, an added burden on the users with frequent security prompts. However, it may certainly help alleviate such vulnerabilities welcoming malware attacks.

Let us know your thoughts in the comments section.

You may also like

Latest Hacking News

Privacy Preference Center


The __cfduid cookie is used to identify individual clients behind a shared IP address and apply security settings on a per-client basis.

cookie_notice_accepted and gdpr[allowed_cookies] are used to identify the choices made from the user regarding cookie consent.

For example, if a visitor is in a coffee shop where there may be several infected machines, but the specific visitor's machine is trusted (for example, because they completed a challenge within your Challenge Passage period), the cookie allows Cloudflare to identify that client and not challenge them again. It does not correspond to any user ID in your web application, and does not store any personally identifiable information.

__cfduid, cookie_notice_accepted, gdpr[allowed_cookies]


DoubleClick by Google refers to the DoubleClick Digital Marketing platform which is a separate division within Google. This is Google’s most advanced advertising tools set, which includes five interconnected platform components.

DoubleClick Campaign Manager: the ad-serving platform, called an Ad Server, that delivers ads to your customers and measures all online advertising, even across screens and channels.

DoubleClick Bid Manager – the programmatic bidding platform for bidding on high-quality ad inventory from more than 47 ad marketplaces including Google Display Network.

DoubleClick Ad Exchange: the world’s largest ad marketplace for purchasing display, video, mobile, Search and even Facebook inventory.

DoubleClick Search: is more powerful than AdWords and used for purchasing search ads across Google, Yahoo, and Bing.

DoubleClick Creative Solutions: for designing, delivering and measuring rich media (video) ads, interactive and expandable ads.



The _ga is asssociated with Google Universal Analytics - which is a significant update to Google's more commonly used analytics service. This cookie is used to distinguish unique users by assigning a randomly generated number as a client identifier. It is included in each page request in a site and used to calculate visitor, session and campaign data for the sites analytics reports. By default it is set to expire after 2 years, although this is customisable by website owners.

The _gat global object is used to create and retrieve tracker objects, from which all other methods are invoked. Therefore the methods in this list should be run only off a tracker object created using the _gat global variable. All other methods should be called using the _gaq global object for asynchronous tracking.

_gid works as a user navigates between web pages, they can use the gtag.js tagging library to record information about the page the user has seen (for example, the page's URL) in Google Analytics. The gtag.js tagging library uses HTTP Cookies to "remember" the user's previous interactions with the web pages.

_ga, _gat, _gid