Powering millions of websites around the world makes WordPress a frequent target for hacking attacks.
In April 2013, WordPress installations around the world were subjected to a worldwide brute-force attack.
These attacks were caused by botnets (networks of infected computers programmed to attack other sites with security vulnerabilities).
How To Protect Your WordPress Site From A Brute-Force Attack
About Brute Force Attacks
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)
One of the many ways hackers will attempt to break into a WordPress site is by trying to guess the site’s administration login username and password. This is done with software tools that can guess hundreds of possible login combinations in minutes.
If you’re using predictable login details, your website can be easily hacked by the software’s repeated attempts to work out your site’s login details.
This is called a “brute-force” attack.
What Are Botnets
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.
(Source: Wikipedia)
”Botnets” are networks of private computers that have been compromised and infected with malicious code or scripts, which can then be controlled remotely as a group, typically without the unsuspecting computer owners’ knowledge.
Botnets are regularly used to blast mass spam emails from computers of unsuspecting users.
Below is a screenshot taken from an internet security monitoring site showing the locations of the command centers of ZeuS – a botnet that has been actively compromising computer networks all around the globe since 2009 …
(ZeuS is a botnet that has been actively compromising computer networks all around the globe since 2009. Image source: SecureList.com)
These were highly distributed and well organized attacks on WordPress sites. Over 90,000 IP addresses were identified by several hosting companies just in the initial attack, when millions of attempts to force their way into WordPress user administration areas took place. The mass brute force attacks continued after this, with over 30,000 WordPress sites and blogs being hacked each day.
Coverage of this large-scale brute-force botnet attack was widely reported in all of the major webhosting companiesand leading technology media publications, such as Forbes, TechNews Daily, PC Magazine, Tech Crunch, BBC News, and even on the official US Department of Homeland Security website …
(Powering millions of websites around the world makes WordPress a target for hacker attacks)
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 about website security.
We explain what makes WordPress a very secure platform for websites in this article: Is WordPress Secure?
It’s important to understand that, in the case of April 2013 brute force attack described above, no specific WordPress vulnerability was being exploited (the same script was also targeting sites built using platforms like Joomla).
Mike Little, one of the co-founders of WordPress with Matt Mullenweg, said this about the brute-force 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 – Ten Security Checks
Every website with a vulnerability can present an opportunity to hackers. A vulnerable website offers hackers with a platform for stealth attacks, spreading malware and as a source of information theft.
If someone can find a vulnerability that allows them to access and take over your blog, that web site can then be used as a “bot” in a planned cyber attack against larger and more highly-valued websites.
Additional undesirable impacts of having your site hacked and your site security compromised include getting blacklisted by search engines, having stealthy spam links advertising things like gambling, cheap offers on brand names, etc. in your content and page title and descriptions, redirecting visitors to phishing sites, drive-by downloads (adding malicious programs on your visitors’ computers), and many other nasty things.
The harsh reality is that malicious bots are most likely looking for vulnerabilities and trying to hack into your blog while you are reading this right now. Whether they will do this successfully will depend on how difficult or easy you have made it for hackers and botnets to keep trying until they work out a way to break in, or are forced to decide to look for an easier target.
How Much Information About Your WordPress Site Are You Broadcasting To Hackers?
If you visit a site like Hackertarget.com and run your website through their WordPress security scan …
(WP Security Scan Image source: Hackertarget.com)
You will see that the scan returns various results and details about your website setup …
(Hackertarget – website security check results. Product image source: Hackertarget.com)
It should be obvious after using the tool shown above that if you are able to freely access all of this information about your site, then hackers can too.
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 all be valuable information to hackers, as these can inform them about any security weaknesses, especially where site owners haven’t updated their files.
If your website is powered by WordPress and you are not taking appropriate steps to bolster the security of your site, then we can practically guarantee that, at some point in time, someone will attempt to hack your site, because these brute-force attacks are systematically hitting WordPress sites worldwide!
When a website or blog is compromised, website owners will discover much to their dismay that they have been “locked out” of their own site, or notice that their content has been vandalized or even entirely wiped out. Typically, most sites will be infected with malicious scripts without the owner’s knowledge or awareness.
To help avoid the heartache and aggravation (and potential loss of valuable business data) of having your website or blog being hacked into, we have listed below ten simple, yet essential and effective security measures that will help to protect your WordPress site from brute force attacks.
Note: A few of the recommended steps below need some technical understanding of how to modify core WordPress and server files. If you have no technical skills, or don’t want to mess around with code on your site, then ask your web host or a professional WordPress technical provider for help.
***
Security Measure #1 – Get In Touch With Your Web Host
Contact your host and ask them what precautions are in place to protect your site from brute force attacks, and what they are doing to make sure that your server files and data get backed up.
Make sure that your webhosting provider backs up your sites and that, if anything happens, you can quickly and easily get your files and data back.
Security Measure #2 – Back Up Your WordPress Data And Files And Keep Your Website Or Blog Frequently Maintained
Never rely just on your webhosting provider for your site backups. Instead, learn how to maintain your WordPress site or get this service done for you and maintain a habit of performing a full WordPress site maintenance routine on a regular basis (e.g. daily, weekly, monthly, etc …)
A full WordPress maintenance routine ensures that:
- All unnecessary data and files are removed,
- All WP files and data are free of errors, optimized and backed up,
- All themes, plugins and software components are up-to-date,
- etc …
A complete WP site maintenance routine looks like this …
(Maintaining your WP website or blog fully backed up and up-to-date is vitally important for WordPress security. Screenshot: WPTrainMe.com)
Again, we cannot stress enough how vitally important it is to maintain your WordPress web site regularly backed up and up-to-date. 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 don’t want to learn how to do WP site maintenance yourself, pay a professional 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 you still have a pulse!
If you don’t want to back up your data manually, there are a number of free and paid WordPress plugins you can use. You can read about a WordPress backup plugin that can fully automate your backup process here: Back Up, Copy & Protect Your WordPress Website With Backup Creator WP Plugin
Security Measure #3 – Do Not Use “Admin” As Your Username
The large scale brute-force attack on WordPress sites was mostly an attempt to compromise website administrator panels by exploiting sites with “admin” as the username.
For reasons of website security, never set up sites with the username admin. This is the first area of potential vulnerability hackers will test. If your blog’s username is admin, then make sure you change it immediately.
We have created a step-by-step tutorial on how to change your username here: How To Change Your WordPress Admin Username To Another User Name
Security Measure #4 – Use Strong Passwords
A “brute force” attack occurs when a malicious script continually tries to guess the right combination of characters in a username and password that will unlock your website.
Unless some measure is put into place to block the brute force attack from happening (see further below for a couple of effective suggestions for doing this), the “bot” will just keep attacking your site until it eventually breaks into your admin area.
Weak passwords, therefore, are really easy targets for hackers. Make sure that you change your password to a string that is at least eight or nine characters long, with upper and lowercase letters, combined with “special” characters (^%$#&@*).
If you have trouble coming up with strong passwords or feel reluctant to set up different passwords for all of your online logins, then use a password software tool like Roboform …
(Roboform is a password management tool that lets you easily create secure login passwords)
For a simple tutorial on how to change your WordPress admin password, go here: Changing Login Passwords In WordPress
Security Measure #5 – Deny Access To Your wp-config.php File
The wp-config.php file contains information about your blog’s database and is used to define advanced WordPress options.
(WordPress WP Config file)
If hackers break into your WordPress website, they will try to access the wp-config.php file, because this file contains important information about your site’s database, security keys, etc. Getting access to this information would allow them to change anything in your database, create a user account, upload files and take control of your site.
In order to protect your WordPress site from being attacked and even being used as part of a bot net, therefore, prevent people getting to your wp-config.php file. 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 your install.php, upgrade.php and readme.html files.
You can remove these files after installation, as they are unnecessary. If you don’t want to delete these files, then just rename them.
Security Measure #7 – Keep Your WordPress Installation, Plugins And Themes Up-To-Date
Hackers look for vulnerabilities in previous versions of WordPress that they can exploit, including out-of-date versions of themes and plugins.
Make sure to keep your WordPress application files, themes, plugins, etc. up-to-date.
Security Measure #8 – Disable The Theme Editor
WordPress comes with a built-in editor that allows you to edit plugin and theme files inside the dashboard area.
In WordPress, you can access your WordPress Theme Editor by selecting Appearance > Editor in your dashboard menu …
(The WordPress theme editor is accessible using the admin menu)
This means that anyone logging into your blog’s admin area can view and change your files, or create mayhem on your site.
To prevent unauthorized people from being able to access your 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 The Site’s Uploads Folder
The “uploads” folder stores all the media that gets uploaded to your website.
By default, this folder is visible to all users online. All someone has to do to view all of the contents in your “uploads” directory is visit your directory using their web browser …
(WordPress uploads directory)
If any files stored in his folder have weaknesses or vulnerabilities that can be exploited by hackers or malicious users, someone could 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, adding a blank index.php file (this is literally a blank file 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 – Security Plugins
A number of WordPress security plugins are available that will address most common security issues faced by WordPress site owners, such as preventing hackers from gaining access to vital information about your site, protecting your website from botnets, preventing unauthorized file uploads, etc.
Most WordPress plugins address some but not all areas of WordPress security. One WordPress plugin that does a comprehensive job of scanning, fixing and preventing potential issues that could lead to hackers accessing your site files and damaging your site is SecureScanPro.
(SecureScanPro – complete security plugin for WordPress)
SecureScanPro is easy to install and easy to use, and takes care of most of the security areas that WordPress users need to address.
Another plugin you may want to look at using is BlogDefender.
Blog Defender
(Blog Defender WordPress Security Suite)
Blog Defender 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 WordPress site are …
And then shows you how to fix these quickly and easily …
If you don’t want to buy a security plugin like SecureScanPro or BlogDefender, then use various free plugins, such as Limit Login Attempts …
WordPress is a secure web platform, but neglecting essential maintenance tasks like keeping your WP installation, plugins and WP themes up-to-date, tightening file and data protection and taking other necessary precautions can have disastrous consequences.
Regardless of the type of business you run or plan to run online and how small you think your web presence is, website security is something you 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 website security to all WordPress users after the global brute-force attacks by botnets 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 very important if you run a WordPress site. Hopefully, the above article will help keep your WordPress site protected from brute force attacks. If you need any further help or assistance with WordPress security, please seek help from a professional 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 via email when we publish new information on WordPress security and tutorials about new security plugins.
***
"These tutorials have so much information and are easy to understand. If you use WordPress or plan to in the future these will help you with everything you need to know." - Valisa (Mesa, Arizona)
***