Intelligence operatives targeting Ukrainian rebels and cyber-criminals targeting businesses used the same zero-day attack exploiting a vulnerability in Microsoft Word, according to an analysis published by FireEye on April 12.

Microsoft patched the issue earlier this week, but not before attackers had a chance to widely use the exploit to compromise systems and install malware. Security firms identified attacks as far back as November 2016 that used the exploit, with most firms pointing to the Dridex banking trojan as the major culprit.

In its analysis, FireEye concluded—with what it characterized as “moderate confidence”—that the specific exploit code used by two groups — cyber-criminals spreading malware known as LatentBot and nation-state actors spreading a surveillance program known as FinSpy — was the same.

“Actors leveraging FINSPY and LATENTBOT used the zero-day as early as January and March, and similarities between their implementations suggest they obtained exploit code from a shared source,” researchers Ben Read and Jonathan Leathery wrote.

The vulnerability exploited by the attacks, identified as CVE-2017-0199, allowed attackers to create a malicious documents that run a Visual Basic script to download malicious code to infect victims' systems. To the user, the attack appears as if the document is updating content from other files, but in reality the document is retrieving a payload from the internet.

Telltale artifacts in the code and documents used in the two attacks suggest a link, FireEye said.

Cyber-spies had used the zero-day Word exploit to target pro-Ukrainian rebels with a surveillance tool known as FinSpy. In January 2017, a military training manual carrying the exploit targeted anti-Kyiv rebels in eastern Ukraine to deliver the cyber-espionage attack. FinSpy is a program produced by U.K.-based Gamma Group and sold to various national governments as a surveillance tool.

Cyber-criminals used what appears to be the same exploit developed by the same source to target businesses and consumers. Six weeks after the FinSpy campaign appeared, criminal attackers began using the same exploit to spread LatentBot—malware that can steal credentials, remotely control computers and disable security software. FireEye has tracked that malware since December 2015 and has linked it to financially-motivated crime.

Both campaigns used an exploit that shares the same ‘builder’ and revision times, suggesting that the code used in each attack came from the same source, the company’s analysis stated.

While FireEye did not speculate as to the reason the same exploit may be being used by two separate groups, the most likely explanation for the link is that the same person sold the exploit to both Gamma Group and the cyber-criminals. Another possibility is that the intelligence operatives are either conducting criminal campaigns on the side or selling exploits to criminals. A third possibility is that Gamma, or one of its employee, sold the exploit to the criminals.

The FireEye analysis noted that the use of the Word exploit by another botnet—Dridex—only happened after public reports of the vulnerability. On April 10, the attackers behind LatentBot started using the exploit to deliver a different payload, another piece of malware known as Terdot.

“Though only one FINSPY user has been observed leveraging this zero-day exploit, the historic scope of FINSPY, a capability used by several nation states, suggests other customers had access to it,” FireEye wrote. “Additionally, this incident exposes the global nature of cyber-threats and the value of worldwide perspective—a cyber-espionage incident targeting Russians can provide an opportunity to learn about and interdict crime against English speakers elsewhere.”