0421 033 433

Is There Any Security Benefit To Moving The WordPress Configuration File?

WordPress utilizes a file called wp-config. php to keep some essential setup settings. This file consists of to name a few things, your database username and password. So it is essential for the security of your site that no one will have access to the contents of that file.

The setup file (wp-config. php) is by default situated in the root directory site however under typical situations it’s contents are not openly available. If you attempt to access it through a web browser you will see that it does not produce any output.

A typical recommendation is to move wp-config.php one directory above the root directory for security factors. If WordPress is set up in the public_html directory, this in the majority of servers implies that you will need to move it to the /home/username/ directory on your server.

If no one can check out the contents of that file then why bother protect it?

Because of how much damage not protecting it can do. The reason to secure your wp-config.php file is for the uncommon instances when your hosting server’s PHP handler breaks or gets hacked and it’s content ends up being available to the general public.

In this instance everyone who wishes to will have access to your WordPress database details just by pointing their web browser to your wp-config.php file.

Why the idea of moving wp-config is not a great concept

    1. The only method for somebody to see the wp-config. php is by bypassing the server’s PHP interpreter. If that occurs you remain in difficulty anyway. It indicates that your server is hacked and the aggressor will have total administrative control of your website. Therefore anywhere you move wp-config.php to will still be visible.
    1. The majority of hosts utilise open_basedir security which indicates that if a php script attempts to open a file, the file location is examined and if it is outside the root directory defined by open_basedir it will not open. So if a hacker succeeds in injecting a destructive php script on your website it will provide him access to just this particular directory. Moving your wp-conig.php file above the root directory indicates that you need to broaden the open_basedir scope to let PHP gain access to scripts outside the web root.
  1. You can secure wp-config.php by utilising htaccess guidelines to reject HTTP demands to it. That method lets you attain the exact same level of security without the need to move the file and without broadening open_basedir. Simply include the following code in your the.htaccess file:
  1. << files wp-config. php>>
    order permit, reject
    reject from all
    <

Will protecting wp-config.php make your WordPress site 100% secure? Definitely not. However it’s another security procedure that may prevent your site being hacked

Fix My Hacked Website

Emergency Website Repair Can Fix Your Website Within The Next 15 Minutes & Help You Secure Your Website & Protect Against Future Attacks. With Our No Fix, No Fee Guarantee You Really Have Nothing To Lose 

Prevent and Remove Malware in WordPress

Prevent and Remove Malware in WordPress

WordPress is the most popular CMS, presently powering over 70 million sites online. From the very first version of WordPress, to the most recent, there have been numerous updates offered - a few of which are fixes for huge security vulnerabilities due to the rise in...

Top 5 Reasons Why WordPress Maintenance Is Essential

Top 5 Reasons Why WordPress Maintenance Is Essential

Although WordPress is most typically utilized for blogging, you can likewise utilize it to host other kinds of websites, such as online shops and media galleries. The design template system and plugin architecture are on the list of the most popular functions of...

The Importance of WordPress Website Security

The Importance of WordPress Website Security

[ad_1] Some people think that they don't need to care much about the security of their WordPress website. Unfortunately, most people realize the importance of security only when their website or blog gets hacked. WordPress is on the list of most user-friendly and...