SANSAR Linux Cryptomining Malware Uses Modified NVIDIA Library to Hide GPU Activity
About 4 min read
securityaisoftwarehardware
A new Linux‑focused cryptomining campaign, identified as threat cluster REF3364, has been observed tampering with NVIDIA GPU telemetry to conceal high‑intensity mining activity. The operation, first seen in late October 2026, relies on a Rust‑based toolkit named SANSAR that receives commands over the Tor anonymity network and coordinates both CPU and GPU miners. Elastic Security Labs disclosed the details in a report released last week, highlighting a sophisticated chain of intrusion, persistence mechanisms, and anti‑detection techniques that target organizations running GPU‑heavy workloads such as artificial‑intelligence and large‑language‑model training.
The initial foothold is gained through an exposed Ray job agent, a component commonly used to schedule distributed compute tasks. By exploiting the open agent, the attacker can execute arbitrary commands on the host, including running the NVIDIA System Management Interface (nvidia‑smi) to enumerate the GPU inventory and exfiltrate that data to an external server. After this reconnaissance step, the threat actor drops a Python reverse‑shell job that connects back to a remote listener. To cement long‑term access, an SSH public key is added to the compromised account’s authorized_keys file, allowing the attacker to log in directly without further exploitation of the Ray service.
Once root privileges are obtained, the intruder stages the SANSAR toolkit under the directory /opt/vadi_. The attacker then builds a custom kernel module named acpi_thermal_mgr.ko using Dynamic Kernel Module Support (DKMS) and installs an initramfs loader into the boot image. The initramfs, a temporary root filesystem loaded early in the boot process, ensures that the malicious module is reloaded each time the system starts, providing a durable foothold that survives reboots. The kernel module functions as a rootkit, employing the Linux Function Tracer (ftrace) framework to hide cryptomining processes, files, and socket entries from standard system utilities. By intercepting termination signals and directory‑listing system calls, the rootkit returns “No such file or directory” or “No such process” for any objects it wishes to conceal.
A critical element of the evasion strategy is a modified NVIDIA Management Library (NVML) wrapper. This library intercepts calls made by monitoring tools such as nvidia‑smi and forces them to report a GPU utilization of zero percent, regardless of the actual load. Temperature and power metrics are also falsified, with the wrapper substituting random values between 36 °C and 46 °C (approximately 97 °F to 115 °F) and power draw between 100 W and 200 W. By presenting benign telemetry, the malware avoids triggering alerts that would otherwise flag the abnormal GPU usage typical of cryptomining.
Communication with the command‑and‑control (C2) infrastructure occurs through an onion service identified as efxisnqldelyr5ra25oqfrsut54b34g26e7zrsiuupsoekjof2gho2id[.]onion. The SANSAR orchestrator uses the Arti Tor client to reach this hidden service, where it receives instructions, reports host and GPU status, and obtains the appropriate miner executable—CPU‑only or GPU‑accelerated—based on the response. Before establishing the Tor connection, the malware performs an anti‑debugging check by reading the TracerPid value; if a debugger is attached (TracerPid non‑zero), the process terminates, reducing the chance of analysis.
In addition to the rootkit and NVML wrapper, the operation deploys a separate backdoor named netns, registered as a systemd service. This component extracts a controller IPv4 address from an Ethereum smart contract (address 0x43eb291f56688c63c93e8a93c4591fc997cf6349) and then opens a plain TCP connection to that address on port 8080. The netns service creates a reverse‑shell channel to the specified host, providing a direct line for the attacker to issue commands outside of the Tor network. The use of a blockchain‑based address lookup adds a layer of indirection that can be updated without modifying the malware itself.
Elastic Security Labs noted Turkish language comments embedded in the rootkit’s source code, though no definitive attribution has been made. The report warns that organizations expanding GPU capacity for AI and large‑language‑model workloads are especially vulnerable. Because the modified NVML library masks mining activity, standard GPU monitoring solutions may fail to detect the illicit compute consumption, leading to diverted processing power, degraded performance for legitimate tasks, and increased electricity and hardware wear costs.
For defenders, the findings suggest several practical steps. First, audit access controls on job‑submission interfaces such as Ray agents to ensure they are not exposed to unauthenticated users. Second, verify the integrity of NVIDIA management libraries on all GPU‑enabled hosts; any unexpected modifications to NVML or nvidia‑smi binaries should be investigated. Third, monitor for the presence of unusual kernel modules, especially those loaded via DKMS and referenced in initramfs images, and check systemd service listings for unknown entries like netns. Finally, consider network‑level detection of Tor traffic to known onion addresses and scrutinize any outbound connections that resolve IP addresses from blockchain contracts, as these patterns are indicative of the described threat chain.
The SANSAR campaign illustrates how financially motivated actors are adapting to the growing prevalence of high‑performance GPU clusters. By blending kernel‑level rootkits, library tampering, and decentralized C2 mechanisms, the attackers achieve both stealth and resilience. As AI workloads continue to drive GPU adoption across enterprises, the risk of cryptojacking that silently siphons compute resources is likely to rise, making comprehensive monitoring and hardening of GPU infrastructure an essential component of modern cybersecurity strategies.
A new technique called Weight2Shell has been disclosed by cybersecurity researchers, which allows artificial intelligence (AI) models to produce different behavior on different machines, eve…
Season 2: Legacy for Gears of War: E‑Day launches tomorrow, marking the franchise’s twentieth anniversary and offering a wave of new content for both veteran players and newcomers. The updat…
Hela: of Mice & Magic is set to launch on December 1, 2026 for Xbox Series X|S, and the title will be available on day one through Xbox Game Pass. The game presents an open‑world adventure i…