Wednesday, January 29, 2025
HomeCyber Security NewsNew malicious NPM packages Used by Attackers Install njRAT Remote Access Trojan

New malicious NPM packages Used by Attackers Install njRAT Remote Access Trojan

Published on

SIEM as a Service

Follow Us on Google News

No, not the one that nibbles at your Thanksgiving leftovers. RAT, Remote Access Trojan, is a type of malware that enables attackers to take over an infected system, execute arbitrary commands, run keyloggers, and discreetly conduct other surveillance activities. 

This Thanksgiving weekend, Sonatype discovered a new malware within the npm registry. The malicious packets being “jdb.js” and “db-json.js”, both published by the same author.

Upon further investigation, it was found that the author behind “jdb.js” had published another malicious npm package “db-json.js”. “jdb.js” is a malicious package that has been clubbed with njRAT a.k.a Bladabindi, which had in 2014 caused Microsoft to shut down 4 million sites.

Variants of njRAT have recently been circulated via Bitcoin scams on Youtube and via Excel phishing emails.

Investigation on “jdb.js”

“jdb.js” is an npm package with the only version 1.0.0.

This contains 3 files in it:

  • package.json, the manifest file
  • module.js, an obfuscated script
  • patch.exe, Windows executable containing the njRAT payload

Once the package is installad, the package.json file first launches ‘module.js’ file which is a strongly obfuscated script containing multiple base64-encoded chunks that cannot be easily deciphere. This script does data gathering and reconnaissance and launches patch.exe file

The patch.exe file runs and copies itself into the local “TEMP” folder on the system and renames itself to “dchps.exe” establishes a connection to 46.185.116.2:5552 also the malicious executable edits Windows firewall rules to ensure it would have no trouble communicating with the hardcoded IP. To do so, it issues the legitimate “netsh” command multiple times, starting with:

netsh firewall add allowedprogram “C:\Users\admin\AppData\Local\Temp\dchps.exe” “dchps.exe” ENABLE

RAt 3

Just by infecting the target with the malware, a remote attacker gains the ability to log keystrokes, modify registry values, initiate system shutdown or restart at will, edit web browser (IE) start page, “speak” to the user via text-to-speech synthesis (via SAPI.Spvoice), kill or relaunch critical system processes like task manager, system restore, and PING, in addition to taking control of hardware devices like CD drives, monitors, mouse, keyboard, etc.

Investigation on “db-json.js

After investigation, it is seen that the Genuine-looking “db-json.js” hides “jdb.js” within.

“db-json.js” had a proper README page with working documetation on npm pretending to be JsonDb, which has now been removed for goodness saying ‘This package contained malicious code and was removed from the registry by the npm security team. A placeholder was published to ensure users are not affected in the future’

Therefore, if someone is able to dodge “jdb.js,” by using “db-json.js” in their application, they will put other developers at risk and just limit to risking themselves.

You can follow us on LinkedinTwitterFacebook for daily Cybersecurity and hacking news updates.

Also Read

Linux Foundation Releases List of Most commonly used open-source Software & Security Problems

Gurubaran
Gurubaran
Gurubaran is a co-founder of Cyber Security News and GBHackers On Security. He has 10+ years of experience as a Security Consultant, Editor, and Analyst in cybersecurity, technology, and communications.

Latest articles

Vulnerability in Airline Integration Service enables A Hacker to Gain Entry To User Accounts

A recent security vulnerability in a widely used airline integration service has exposed millions...

Hackers Seize Control of 3,000 Companies Through Critical Vulnerabilities

In a groundbreaking cybersecurity investigation, researchers identified several critical vulnerabilities in a target system,...

PoC Exploit Released for Critical Cacti Vulnerability Let Attackers Code Remotely

A critical vulnerability in the Cacti performance monitoring framework tracked as CVE-2025-22604, has been...

TorNet Backdoor Exploits Windows Scheduled Tasks to Deploy Malware

Cisco Talos researchers have identified an ongoing cyber campaign, active since mid-2024, deploying a...

API Security Webinar

Free Webinar - DevSecOps Hacks

By embedding security into your CI/CD workflows, you can shift left, streamline your DevSecOps processes, and release secure applications faster—all while saving time and resources.

In this webinar, join Phani Deepak Akella ( VP of Marketing ) and Karthik Krishnamoorthy (CTO), Indusface as they explores best practices for integrating application security into your CI/CD workflows using tools like Jenkins and Jira.

Discussion points

Automate security scans as part of the CI/CD pipeline.
Get real-time, actionable insights into vulnerabilities.
Prioritize and track fixes directly in Jira, enhancing collaboration.
Reduce risks and costs by addressing vulnerabilities pre-production.

More like this

Vulnerability in Airline Integration Service enables A Hacker to Gain Entry To User Accounts

A recent security vulnerability in a widely used airline integration service has exposed millions...

Hackers Seize Control of 3,000 Companies Through Critical Vulnerabilities

In a groundbreaking cybersecurity investigation, researchers identified several critical vulnerabilities in a target system,...

PoC Exploit Released for Critical Cacti Vulnerability Let Attackers Code Remotely

A critical vulnerability in the Cacti performance monitoring framework tracked as CVE-2025-22604, has been...