Analyzing a malicious Raspberry Pi Bash script

Script Known

On the VirusTotal website, a malware analysis service, 25 of 57 scanners detect the script as malware [10]. The "First Seen in the Wild" date cited there is June 13, 2017; the first upload to VirusTotal is dated June 14, 2017. The Linux.MulDrop.14 script is detected by 16 of 56 virus scanners [11]. However, this version of the LinuxMulDrop.14 [3] was uploaded to VirusTotal for the first time by me.

A random test to determine whether these login attempts actually came from Raspberry Pis shows by means of the SSH banner that it is without question the Raspbian operating system.

Conclusions: Lessons Learned

The firewalls in an enterprise or organization should only allow incoming connections to resources that are explicitly approved or centrally managed. Moreover, SSH servers must always be especially secured, because the SSH port is subject to many brute force attacks on passwords.

Additionally, it is very useful to deploy hacker tools – especially ZMap – to search for open ports in your own IP address range. A Raspberry Pi is suitable as a scanner for this purpose. Special vulnerability scanners (e.g., OpenVAS/Greenbone [12]) can also search specifically for services with default passwords. Administrators always should change default passwords, because they cannot rule out early on that the system will not be accessible on the Internet at some point.

The sudo configuration common today, and which is especially open on the Raspberry Pi, is not suitable for computers that are reachable from the Internet. An adapted (i.e., hardened) configuration must be imported before production release.

As the example proves, active Linux malware does exist – here in an incarnation for Raspbian – and can cause trouble and extra work for admins. Linux is by no means resistant to malicious software. This malware is still active and still produces log entries day after day.

The Author

Rainer W. Gerling was Data Protection Officer from 1993 to 2013 and, since 2006, he has served as the IT Security Officer of the Max Planck Society. He also lectures as an honorary professor of IT security in the department of Computer Science and Mathematics at Munich University of Applied Sciences. He is a popular speaker at conferences and seminars.

Buy this article as PDF

Express-Checkout as PDF
Price $2.95
(incl. VAT)

Buy Linux Magazine

Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

comments powered by Disqus

Direct Download

Read full article as PDF:

Price $2.95