PyRoMineIoT spreads via EternalRomance exploit and targets targets IoT devices in Iran and Saudi Arabia.

Pierluigi Paganini June 13, 2018

Fortinet discovered PyRoMineIoT, a new strain of crypto-currency miner that exploits the NSA-linked EternalRomance exploit to spread.

PyRoMineIoT is a new strain of crypto-currency miner that exploits the NSA-linked EternalRomance remote code execution exploit to spread, the malware also abuses infected machines to scan for vulnerable Internet of Things (IoT) devices.

PyRoMineIoT is quite similar to another crypto-currency miner dubbed PyRoMine that was first spotted a few weeks ago, its infections rapidly increased since April, most of them in Singapore, India, Taiwan, Côte d’Ivoire, and Australia.

According to Fortinet, the older miner was improved with some obfuscation, the latest variant PyRoMine is hosted on the same IP address 212[.]83.190[.]122, and both variants leverage the EternalRomance implementation found on the Exploit Database website.

PyRoMineIoT is delivered from a website disguised as security updates for web browsers.

Once the PyRoMineIoT malware has compromised a device, it will download an obfuscated VBScript that has the same functionality as the one used by the PyRoMine variant, but its code appears well organized.

The VBScript also downloads other components, including a Monero miner (XMRig), but differently from previous variant it uses random names for the files.

“As with the previous version of PyRoMine, this new version is hosted on the same IP address The downloaded file is an executable compiled with PyInstaller, which is a program that packages programs written in Python into stand-alone executables. This means that there is no need to install Python on the machine in order to execute the Python program.” reads the analysis published by Fortinet.

Both variants sets up a Default account with the password P@ssw0rdf0rme and adds the account to the local groups “Administrators,” “Remote Desktop Users,” and “Users,” then it enables RDP and adds a firewall rule to allow traffic on port 3389.

Once compromised a device, PyRoMineIoT attempts to remove PyRoMine variant if present.

The analysis of one of the pool addresses used by the threat actors behind the malware revealed it earned around 5 Monero (about $850).

The attack chain

The victim downloads a fake update as .zip archives containing a downloader written in C# that fetches the miner file, a Python-based malware that leverages EternalRomance to spread the downloader, and other malicious components.

“One of the downloaded components is a Python-based malware that takes advantage of the NSA exploit ETERNALROMANCE to spread the agent to vulnerable machines in the network. Another component is a tool that steals user credentials from Chrome browser named ChromePass.” continues the analysis.

“Another component scans for vulnerable IoT devices in Iran and Saudi Arabia that use the login credentials “admin” for username and password.” 


The EternalRomance implementation collects the IPs of local subnets and targets them to spread using credentials with username ‘aa’ and an empty password.

Another component used by the malware is the legitimate software ChromePass that allows seeing credentials from Chrome.

Once the credentials are collected by the malware, it saves them in XML format and uploads the file to an account on DriveHQ’s cloud storage service.

PyRoMineIoT searches for vulnerable IoT devices, but at the time it only targets those in Iran and Saudi Arabia.

“This development confirms yet again that malware authors are very interested in cryptocurrency mining, as well as in capturing a chunk of the IoT threat ecosystem.” Fortinet concludes.

“We predict that this trend will not fade away soon, but will continue as long as there are opportunities for the bad guys to easily earn money by targeting vulnerable machines and devices,” 

[adrotate banner=”9″] [adrotate banner=”12″]

Pierluigi Paganini

(Security Affairs – PyRoMineIoT, hacking)

[adrotate banner=”5″]

[adrotate banner=”13″]

you might also like

leave a comment