North Korean hackers blamed for hijacking popular Axios open-source project to spread malware

North Korean hackers blamed for hijacking popular Axios open-source project to spread malware

A suspected North Korean hacker has hijacked and modified a popular open source software development tool to deliver malware that could put millions of developers at risk of being compromised.

On Monday, a hacker pushed malicious versions of the widely used JavaScript library called Axios, which developers rely on to allow their software to connect to the internet. The affected library was hosted on npm, a software repository that stores code for open-source projects. Axios is downloaded tens of millions of times every week. 

The hijack was spotted and stopped in around three hours overnight on Monday into Tuesday, according to security firm StepSecurity, which analyzed the attack

Hackers are increasingly targeting developers of popular open-source projects in an effort to mass-hack anyone who relies on the compromised code, potentially granting the hackers access to vast numbers of affected devices. These kinds of widespread breaches are called supply chain attacks because they target software that allows hackers to then hack whoever downloaded the compromised software. In recent years, hackers have targeted companies like 3CX, Kaseya, and SolarWinds, as well as open source tools such as Log4j and Polyfill.io, to target large numbers of their users.

It’s unclear at this point how many people downloaded the malicious version of Axios during that timespan. Security company Aikido, which also investigated the incident, said anyone who downloaded the code “should assume their system is compromised.”

Google told TechCrunch that its security researchers are linking the Axios compromise to North Korean hackers.

“We have attributed the attack to a suspected North Korean threat actor we track as UNC1069,” said John Hultquist, the chief analyst for Google’s Threat Intelligence Group. “North Korean hackers have deep experience with supply chain attacks, which they’ve historically used to steal cryptocurrency. The full breadth of this incident is still unclear, but given the popularity of the compromised package, we expect it will have far reaching impacts.”

The hacker was able to slip malicious code inside Axios by compromising the account of one of the project’s primary developers, who was authorized to push out updates. The hacker replaced the legitimate developer’s email address on the account with their own, making it more difficult for the developer to regain access.

Once in control of the account, the hacker inserted malicious code designed to deliver a remote access trojan, or RAT — essentially malware that can give hackers full, remote control of a victim’s computer. The hacker then pushed out new versions of Axios in a legitimate-looking update for Windows, macOS, and Linux users. 

The hackers also designed the malware, as well as some of the code used to deliver it, to automatically delete itself after installation in an attempt to hide from anti-malware engines and investigators, according to security researchers.

Updated to include information from Google about the attribution to North Korea.