Oops! Google Chrome Could Not Connect To 127.0.0.1

By | September 14, 2013

While I was developing a site with WordPress; all of a sudden, I attempted to access dashboard and I got an error indicating that Google Chrome could not connect to 127.0.0.1

During my research, I figured this blog might of been my solution: http://wordpress.org/support/topic/redirections-to-127001-when-enabling-network
There was even a suggestion about the configuration within the nginx conf file and this did not resolve my issue; although, perhaps it might for you..

So many different suggestions regarding local host, yada, yada, none of the queries seemed to bring me much luck; until, I decided to revert my .htaccess in attempts this would work. YES, I was able to log back into my WordPress. After I reverted to previous .htaccess file, I was able to trouble shoot the issue and here is what I discovered.

Troubleshooting: WordPress 3.5+
My 127.0.0.1 Redirect Loop had to do with the plugin WP Security and the code it used inside .htaccess.

In WordPress, Dashboard; on the tool bar you will see option for WP Security > Firewall

WP Security > Firewall

If I enable the Basic Firewall Settings: fail
If I enable the WordPress Pingback Vulnerability Protection: fail

In either combination of enabling/disabling the above settings, no resolution was achieved.

So, with the Basic Firewall & Pingback Settings disabled, I troubleshooted ‘Brute Force Prevention’.

WP Security > Firewall > Brut Force Prevention: Enabled Brue Force attack Prevention & populated Secrete Word with the Re-Direcdt URL of http://127.0.0.1 (or where ever you want) and save (regenerating .htaccess file).

Conclusion

If you enabled WP Security plugin and in the Firewall options under Brute Force, you are provided a ‘secrete word’ as a login phrase; be sure you login into WordPress with the unique phrase or URL Brute Force provides.

So, instead of going to generic WordPress login: http://domain.com/wordpress/wp-admin
You would go to unique phrase WordPress login: http://domain.com/wordpress/?uniquephrase

And if that solution does not work for you, revert back to your old .htaccess file or copy the contents below and create your own .htaccess file & upload:

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /wordpress/
RewriteRule ^index\.php$ – [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /wordpress/index.php [L]
</IfModule>

# END WordPress

Resources

Hardening WordPress: http://codex.wordpress.org/Hardening_WordPress
Redirecting loop occurs with .htaccess file: http://www.justincener.com/blog/how-to-easily-fix-the-wordpress-redirect-loop-error-without-admin-access/