Allow authentication to be configured as optional.

This commit is contained in:
Andrew McMillan 2008-10-25 16:52:20 +13:00
parent 85116dc0a4
commit 3acdc1eb7f

View File

@ -126,6 +126,14 @@ class HTTPAuthSession {
}
}
if ( isset($c->allow_unauthenticated) && $c->allow_unauthenticated ) {
$this->user_no = -1;
$this->username = 'guest';
$this->fullname = 'Unauthenticated User';
$this->email = 'invalid';
return;
}
$this->AuthFailedResponse();
// Does not return
}
@ -272,4 +280,3 @@ class HTTPAuthSession {
}
?>