Question

How to prevent cryptojacking?

Posted October 16, 2020 86 views
Security

Over 12 months droplets on my account have been compromised 5-10 times and always the same story: CPU goes to 100% and in ./root folder is some crypto mining software downloaded/installed (moneroocean).

Can you suggest how to prevent these?

PS. password and root access to the droplets are disabled, so only non-root users can ssh to a droplet.

Thanks

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
1 answer

Hi there @slobodandjordjevic,

As a start I could suggest a few things here:

  • First make sure that you follow the steps from this tutorial here on how to Harden OpenSSH

  • Make sure to run your web servers like Apache or Nginx as a low privileged user

  • Enable a firewall and lock down all ports that should not be accessed from the outside world

  • Make sure that you regularly patch your server and install all of the latest security updates

  • I also strongly suggest following the steps here on how to do your initial server setup.

Besides that, it is also very important to secure your application as well. For example, if you are running a CMS like WordPress or any other, make sure that all of the themes, plugins and etc are up to date.

If you are running Apache, you could also consider installing Mod Security to prevent some known application-level attacks.

I have seen this with a lot of WordPress websites where the site is poorly maintained and no updates are being made or due to a specific plugin that attackers easily exploit and use as a backdoor.

Hope that this helps.
Regards,
Bobby

by Justin Ellingwood
When you first create a new Ubuntu 18.04 server, there are a few configuration steps that you should take early on as part of the basic setup. This will increase the security and usability of your server and will give you a solid foundation for subsequent...
Submit an Answer