When you are the world’s leading content management system and the online publishing platform of choice for millions of websites and loved by thousands of website developers and website designers, it’s inevitable that at some point in time, WordPress will come under attack from hackers.
In April 2013 a large-scale brute force attack hit WordPress installations on virtually every host server in existence.
These attacks were caused by botnets (networks of infected computers programmed to attack other vulnerable computers).
- How To Protect Your WordPress Site From A Brute-Force Attack
- What Is A Brute Force Attack?
- Botnet – What Is This?
- Preventing Your WordPress Website From Brute Force Attacks – 10 Security Measures
- How Much Information Are You Broadcasting To Hackers About Your Site?
- Security Measure #1 – Get In Touch With Your Hosting Service
- Security Measure #2 – Back Up Your WordPress Data And Files And Keep Your Website Regularly Updated
- Security Measure #3 – Make Sure That Your Username Is Not “Admin”
- Security Measure #4 – Change Your Password
- Security Measure #5 – Deny Access To Your wp-config.php File
- Security Measure #6 – Delete Or Rename Unnecessary Installation Files
- Security Measure #7 – Keep Your WordPress Site, Plugins & Themes Up-To-Date
- Security Measure #8 – Disable Your WordPress Theme Editor
- Security Measure #9 – Remove Access To Your WordPress Uploads Folder
- Security Measure #10 – Install Security Plugins
- Blog Defender
How To Protect Your WordPress Site From A Brute-Force Attack
What Is A Brute Force Attack?
A brute-force attack is a technique used to break an encryption or authentication system by trying all possibilities.
(Source: Chinese University Of Hong Kong)
There are many methods hackers use to try and break into a WordPress site. One of these is by trying to guess the site’s administration login username and password. This can be done with scripts and tools that can work through hundreds of login permutations in minutes.
If you’re using obvious usernames and passwords, your site could be easily hacked by persistent attempts to work out your site’s login details.
This is called a “brute force” attack.
Botnet – What Is This?
A botnet is a number of Internet-connected computers communicating with other similar machines in an effort to complete repetitive tasks and objectives. This can be as mundane as keeping control of an Internet Relay Chat (IRC) channel, or it could be used to send spam email or participate in distributed denial-of-service attacks. The word botnet is a combination of the words robot and network.
”Botnets” are networks of computers that have been compromised and infected with malicious code or scripts, which are then controlled remotely as a group, typically without the computer owners’ knowledge or awareness.
Botnets are regularly used to blast mass spam emails from the infected computers of compromised user accounts.
The screenshot below was taken from an online security monitoring site showing the locations of the command centers of ZeuS – a botnet that has been actively compromising computer networks all around the world since 2009 …
(ZeuS is a botnet that has been actively infecting computer networks all around the globe since 2009. Image: SecureList.com)
The botnet attacks were well organized and highly distributed. Over 90,000 IP addresses were identified by a number of hosting companies in the initial attack alone, when millions of attempts to force their way into WordPress site admin areas took place. The mass brute force attacks continued after this, with over 30,000 WordPress sites being hacked each day.
News of the April 2013 brute force attack was widely reported in all the major webhosting companies, as well as the leading technology media publications, such as TechNews Daily, Forbes, PC Magazine, Tech Crunch, BBC News, and even on the official US Department of Homeland Security website …
(WordPress is frequently the target of malicious attempts by hackers, due to its global popularity)
Does This Mean WordPress Is Not Secure And We Should Stop Using It?
No. In fact, there are lots of very good reasons why you should choose WordPress if you are concerned at all about the security of your online presence.
To learn what makes WordPress a very secure web platform, read this article: Why WordPress Is A Secure Platform For Websites –
It’s important to understand that, in the case of the large-scale brute force attack described above, there was no WordPress vulnerability being exploited (the same script was also targeting sites built using other platforms like Joomla).
Mike Little, one of the co-founders of WordPress, made the following comment about the botnet attacks:
It is a “simple” script that attempts to login using the admin login and a generated password. So if your password is too short or based on dictionary words it will be guessed and then the script can login legitimately and do whatever it wants including installing scripts (as plugins) or editing files. The attack tries to guess your password, if it succeeds, the most secure site in the world is wide open because they have your password.
Preventing Your WordPress Website From Brute Force Attacks – 10 Security Measures
Every web site with a security vulnerability offers some value to hackers. No matter what kind of business you run or plan to run online and how small you think your web presence is, you cannot afford to ignore the importance of web security. Corporate web sites, personal blogs, government websites … even sites owned by online security and anti-hacking experts can and have been targeted.
If a hacker can find a way to access and take over your blog, that website or blog can then be employed to attack larger and more highly-valued sites.
Additional undesirable effects of having your website hacked include being blacklisted by Google, having spammy links advertising things like casinos, discounted fashion, etc. inserted into your content and meta data, malicious redirects to phishing sites, drive-by downloads (adding malicious software on your visitors’ computers), and many other nasty things.
The truth is that software-driven bots are scouring for security weaknesses and trying to hack into your blog right now. Whether they will be successful or not, will depend on how hard you can make it for hackers or bots to keep trying until they can discover how to get access, or give up and go look for a less protected target.
How Much Information Are You Broadcasting To Hackers About Your Site?
If you visit a site like Hackertarget.com and run your website through their WordPress security scan …
You will see that the test returns a number of results and information about your website setup …
(Hackertarget – WP security check results. Product image: Hackertarget.com)
It should be obvious after using the tool shown above that if you can access all of this information about your site, so can hackers.
(Product image: BlogDefender.com)
Being able to see what version of WordPress you are using, which plugins and themes you have installed on your site, and which files have been uploaded to certain directories can be potentially useful information to hackers, as this informs them about potentially exploitable holes or weaknesses, especially where site owners haven’t updated their software versions.
If your site or blog runs on WordPress and you’re not taking appropriate steps to toughen up your site, then we can practically guarantee that, at some time in the near future, someone will attempt to hack your site, because these attacks are systematically targeting WordPress sites all the world!
Whenever a site is broken into, site owners can find themselves completely “locked out” of their own site, or notice that their files have been modified or even that their content has been entirely wiped out. Typically, most sites will become infected with malicious software or viruses without the owner’s knowledge or awareness.
To help avoid the heartache and aggravation that comes with having your site being hacked into, we have listed below 10 simple, yet essential and effective security checks that will help to protect your WordPress site from being brute-force attacked.
Note: Some of the measures listed below need some technical skills to modify core WordPress and server files. If you have no web skills, or don’t want to mess around with code on your site, then ask your web host or search for a professional WordPress technical provider in our WordPress Services Directory.
Security Measure #1 – Get In Touch With Your Hosting Service
Get in touch with your web host and ask them what security measures have been put in place to help prevent your site from brute-force attacks, and what is done to make sure that your WordPress sites are regularly being backed up.
Check that your hosting company backs up your sites and that, if anything should happen, you can quickly and easily get back your files.
Security Measure #2 – Back Up Your WordPress Data And Files And Keep Your Website Regularly Updated
You should never rely just on your webhosting company for your site backups. Instead, learn how to maintain and manage your WordPress site or pay someone to get this done for you and maintain a habit of religiously performing a complete site maintenance routine frequently (e.g. daily, weekly, fortnightly, etc …)
A full WordPress maintenance routine ensures that:
- All unnecessary files and data are removed,
- All WordPress data and files are free of errors, optimized and backed up,
- All WordPress software, themes and plugins are up-to-date,
- etc …
A proper WP maintenance routine looks like this …
(Maintaining your WP website backed up and up-to-date is vitally important for WordPress security. Source: WPTrainMe.com)
Again, we cannot stress enough how important maintaining your WP website backed up and updated is. WP site maintenance is not hard to do or time-consuming, but it must be done to ensure the security of your website or blog. If you do not want to learn how to do WP maintenance yourself, pay someone to do it but make sure this gets done. Backing up your site is the second most important thing you must do after making sure that your heart is still beating!
If you don’t want to back up your data manually, there are many WordPress plugins you can use. Learn about a WordPress backup plugin that can automate your site backups here: Backup, Copy & Keep Your WP Web Site Protected With Backup Creator WP Plugin
Security Measure #3 – Make Sure That Your Username Is Not “Admin”
The brute force attack on WordPress sites was mostly an attempt to compromise website administrator panels by exploiting WordPress sites that used “admin” as the user name.
For reasons of website security, don’t set up a WordPress site with the username “admin”. This is the first thing hackers will test. If your blog’s user name is “admin”, you will need to change it immediately.
For a detailed tutorial for non-technical WordPress admin users on how to change your WordPress username, go here: Changing Your WP User Name From Admin To A Different User Name
Security Measure #4 – Change Your Password
A “brute force” attack occurs when malicious software continually and persistently hits a username and password field with different character strings in an attempt to guess the right login combination that will unlock your website.
Unless some measure is put into place to prevent the brute force attack from happening (see further below for a couple of simple and effective suggestions for doing this), the “bot” will just keep attacking your site until it eventually gets access.
Weak passwords, therefore, make very easy targets for hacking attacks. Make sure that you change your password to something that contains at least 8 characters long, and that includes upper and lowercase letters, combined with a few “special” characters (%^#$@&*).
Roboform is a password program that lets you easily generate different hard-to-guess passwords …
(Roboform is a password software that lets you easily create different strong passwords)
We have created a simple tutorial for WordPress users on how to change your login password here: How To Change Passwords In WordPress
Security Measure #5 – Deny Access To Your wp-config.php File
The wp-config.php file allows WordPress to communicate with the database to store and retrieve data and is used to define advanced options for WordPress.
(WP Config file)
If a hacker breaks into your WordPress website, they will typically search for the wp-config.php file, because this is the file that contains important information about your site’s database, security keys, etc. Getting access to this information would allow someone to change anything in your database, create a user account, upload files and take control of your site.
To protect your WordPress site from attacks and even being used as part of a bot net, therefore, prevent your wp-config.php file from being accessible. This requires knowing how to edit database information, move files around in your server and changing access permissions.
Security Measure #6 – Delete Or Rename Unnecessary Installation Files
Delete or rename the install.php, upgrade.php and readme.html files from your server.
You can remove these files after installation. If you don’t want to remove these files, then just rename them.
Security Measure #7 – Keep Your WordPress Site, Plugins & Themes Up-To-Date
Hackers are always on the lookout for vulnerabilities in older versions of WordPress that they can exploit, including out-of-date versions of plugins and themes.
Ensure that all of your application files, themes, plugins, etc. are always up to date.
Security Measure #8 – Disable Your WordPress Theme Editor
WordPress installations come with a built-in editor feature that allows site administrators to edit plugin and theme files from the dashboard area.
In WordPress, you can access the WordPress Theme Editor by selecting Appearance > Editor in your dashboard menu …
(The WordPress theme editor is accessible via the main menu)
The WordPress theme editor allows anyone accessing your site to view and edit your WP theme template files, and create havoc on your site.
To prevent people from being able to access the WordPress Theme editor, you will need to disable it. This can be done by adding code to your wp-config.php file.
Security Measure #9 – Remove Access To Your WordPress Uploads Folder
The “uploads” directory contains all the media that gets uploaded to your site.
Normally, this folder is visible to online users. All someone has to do to view all of the contents in the “uploads” directory is visit the directory using a web browser …
(WordPress uploads folder)
If any directories in your website have weaknesses or vulnerabilities that can be exploited by hackers, anyone can upload unauthorized file types to your site.
Protecting your directories will prevent unauthorized people from viewing your ‘uploads’ folder and other important directories. This can be done using plugins, setting file permissions, uploading a blank index.php file (this is literally a file with nothing in it named “index.php”) to your uploads directory, and so on. Again, it’s best to get professional help if you are unsure about what to do.
Security Measure #10 – Install Security Plugins
A number of great WordPress security plugins are available that will address most security issues WordPress site owners face, such as preventing hackers from accessing your site, protecting your files from brute-force attacks, preventing injections of code into files, etc.
Many WordPress plugins address some but not all areas of WordPress security. One security plugin that seems to do a comprehensive job of scanning, fixing and preventing potential issues that could lead to hackers accessing your files and causing damage to your site is SecureScanPro.
(SecureScanPro – security plugin for WordPress)
SecureScanPro is easy to install and easy to use, and addresses most of the security issues that WordPress users need to address.
Another plugin you may want to look at using is BlogDefender.
This product is a suite of WordPress security video tutorials, plugins and tools, plus a WordPress security PDF/DOC file.
BlogDefender shows you where potential security holes in your website are …
WordPress is a secure web platform, but neglecting essential maintenance tasks like keeping your WP core files, WordPress plugins and WP themes updated to their latest versions, tightening file and data protection and taking other necessary precautions can expose your website to malicious by hackers and bots.
No matter what type of business you run or plan to run online and how small you think your web presence is, securing your site is something you simply cannot afford to ignore.
As a final reminder of the importance of keeping your websites protected, below is the advice given by an expert on web security to all WordPress users after the worldwide brute force attacks on WordPress in April 2013 …
Owners of websites based on WordPress CMS must improve at least basic security settings and implement best practices such as the use of robust passwords and the accurate management of “admin” accounts.
Pierluigi Paganini, Chief Information Security Officer, Security Affairs
As you can see, website security is of the utmost importance if you run a WordPress site. Hopefully, the above article will help prevent brute-force attacks on your WordPress site. If you need any further help or assistance with WordPress security, please seek help from a WordPress security specialist, or search for a WordPress technical provider in our WordPress Services Directory.
We also recommend subscribing to WPCompendium.org to be notified whenever we publish new information on WordPress security and tutorials about new WordPress security plugins and solutions.
"I was absolutely amazed at the scope and breadth of these tutorials! The most in-depth training I have ever received on any subject!" - Myke O'Neill, DailyGreenPost.com
Disclaimer: We are not associated with WordPress or any of the WordPress products written about on this site. We may receive affiliate commissions from purchases of any third-party services and/or products advertised, endorsed or linked from our website. All images and information sourced from product websites remain the copyright of their respective owners and have been used solely for illustrative or training purposes.
Did you enjoy this post? Please feel free to share this post with other website owners using the social buttons below.