Some files should never leave the server. A copy of wp-config.php that an editor or FTP client left behind holds your database password in plain text. So does a .env file. A .git folder holds the site's code and its history, and an error log tells strangers how the site is built. Bots try these addresses on every site they find, all day long.
What WP Moo looks at
What the problems mean
Out of the box: Urgent when a config file is public · Important when .git is public or error_log is public · Notice for an open uploads folder. What each priority means: Problem priority.
How to fix it
For your developer
Each run asks for the first 4,096 bytes (with a Range header) of /wp-config.php, /wp-config.php.bak, /wp-config.php.old, /wp-config.php.save, /wp-config.php.orig, /wp-config.php~, /.env, /.git/HEAD, /error_log, /wp-admin/error_log and /wp-content/uploads/, on the site's main address. When WordPress runs in a folder, like /blog, which we read from its login address, the wp-config.php files, both error_log files and the uploads folder are asked for in that folder too, for example /blog/wp-config.php.bak. .env and .git are only asked for at the root. To see what we see:
curl -sL -A 'WPMooBot/1.0 (+https://wp-moo.com/bot)' -r 0-4095 https://example.com/wp-config.php.bak
A file counts on a 200 or 206 at the path asked for, also after a redirect that kept the path and the host, with or without www, when its first bytes show it: define( 'DB_PASSWORD' for wp-config.php and its copies, three or more KEY=value lines and no HTML for .env, ref: refs/ or a commit hash for .git/HEAD, a line starting with PHP's log timestamp ([02-Nov-2026 10:00:00) for error_log, and an Index of / title for the uploads folder. A file that gets no answer, a server error or a firewall's block page keeps what the last run found, so one bad request doesn't clear a problem for a day. To block them (on nginx, keep the wp-config.php rule above your .php location, because nginx uses the first regex that matches):
# nginx
location ~ /\.(env|git) { deny all; }
location ~* /wp-config\.php { deny all; }
location ~* /error_log$ { deny all; }
autoindex off;
# Apache 2.4 (.htaccess)
Options -Indexes
<FilesMatch "^(\.env|wp-config\.php.*|error_log)$">
Require all denied
</FilesMatch>
RedirectMatch 404 /\.git
Something unclear on this page? Email [email protected]