diff options
author | Bill Marquette <billm@pfsense.org> | 2005-05-16 03:14:26 +0000 |
---|---|---|
committer | Bill Marquette <billm@pfsense.org> | 2005-05-16 03:14:26 +0000 |
commit | 5a9edd86aadf8083e5c4a7f1057619698dac8b13 (patch) | |
tree | b7e3784779fe257c9f06e095c274af551ff45d92 /etc/inc/auth.inc | |
parent | bf786a5dff870bffaa916b5526f39599a8ca65e7 (diff) | |
download | pfsense-5a9edd86aadf8083e5c4a7f1057619698dac8b13.zip pfsense-5a9edd86aadf8083e5c4a7f1057619698dac8b13.tar.gz |
ensure .htpasswd doesn't exist
Diffstat (limited to 'etc/inc/auth.inc')
-rw-r--r-- | etc/inc/auth.inc | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/etc/inc/auth.inc b/etc/inc/auth.inc index 4eba572..64ba50a 100644 --- a/etc/inc/auth.inc +++ b/etc/inc/auth.inc @@ -84,6 +84,9 @@ function htpasswd_backed_basic_auth() { $authfile = file("/var/run/htpasswd"); + /* sanity check to ensure that /usr/local/www/.htpasswd doesn't exist */ + unlink_if_exists("/usr/local/www/.htpasswd"); + /* Prompt three times and give up */ for($attempt = 0; $attempt <= 3; basic_auth_prompt()){ $attempt++; |