summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZach Copley <zach@status.net>2010-03-26 18:51:01 +0000
committerZach Copley <zach@status.net>2010-03-26 19:58:15 +0000
commitb82e55356d4ea306b1069ba5acc8878ce18c2abc (patch)
tree35e31aaf8ff81d1a87a35a091c6209e145bb60c0
parent94f904bf66112f1d8dab7fc36dd48706bed4473b (diff)
Return an http auth error, when a client sends in an invalid auth user, even when http auth is not required.
-rw-r--r--lib/apiauth.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/apiauth.php b/lib/apiauth.php
index 17f803a1c..e78de618e 100644
--- a/lib/apiauth.php
+++ b/lib/apiauth.php
@@ -267,7 +267,7 @@ class ApiAuthAction extends ApiAction
$this->access = self::READ_WRITE;
- if (empty($this->auth_user) && $required) {
+ if (empty($this->auth_user) && ($required || isset($_SERVER['PHP_AUTH_USER']))) {
// basic authentication failed