My account has been compromised. How do I fix it?

If your web hosting account has been compromised you should proceed with the following steps to secure/fix it.

1. You need to check if the script you use for your web site is up to date. You must update it to latest version. You need to contact your software vendor or web developer regarding steps how you can do the update.

2. You should scan your account for any files uploaded by the attacker under your public_html folder. They may upload php shells to be able to edit your files even after you update your software. Any files not uploaded by you must be removed from public_html.

3. You must change the permissions of your configuration files which contain passwords to 600. Each script has such a file which contains the login details for MySQL. It needs to be chmod to 600 so that others can’t read it and steal the password.

4. You must change your password for cPanel to a hard to guess password. A hard to guess password is [email protected]!z;[email protected]%Zdf.

5. Change the MySQL password to a new one which is hard to guess and then update it in the configuration file of your script. For WordPress the configuration file is called wp-config.php. The MySQL password can be changed from cPanel -> MySQL databases.

6. You should scan your computer for viruses in case your password was stolen by a trojan on your computer.

If your web site files were injected with malware, you should follow the steps above and also remove the malware code from your files. The malware is a virus which usually resides within iframe html code. You need to check your files and remove the malware from the infected ones.

There is nothing else you need to do regarding this. If your account gets compromised again after you have updated your software, that means you missed to update/secure some script which was used to hack your account. You will need to recheck everything from scratch and see if you missed to update any modules/extensions you installed in your account. It is very important to keep your account up to date and secure.

Was this helpful?

Do you want to make your WordPress/WooCommerce site lightning fast?

We guarantee to make your WordPress site load in less than 2 seconds on a managed VPS with ScalaHosting or give your money back. Just fill in the form below and we will get in touch with you.

Please enter a valid name
Please enter a valid website
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Do you want to learn how to grow your website in 2023?

An all-star team of SEO and web influencers are sharing their secret knowledge for the first time in years. You will learn about:

  • What is the future of SEO and how you can be ahead of the curve
  • Web Design best practices and why they matter
  • Secrets to getting the foundation for your website to thrive

An Exclusive Insiders Look Behind The SEO and Web Development Curtain

Rado
Author

Working in the web hosting industry for over 13 years, Rado has inevitably got some insight into the industry. A digital marketer by education, Rado is always putting himself in the client's shoes, trying to see what's best for THEM first. A man of the fine detail, you can often find him spending 10+ minutes wondering over a missing comma or slightly skewed design.