parent
a40a2b8cfa
commit
3dfae49cda
|
@ -27,6 +27,20 @@
|
||||||
Purpose of file:
|
Purpose of file:
|
||||||
----------------------------------------------------------------------
|
----------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
// For people who want to authenticate with HTTP AUTH
|
||||||
|
if (isset($_GET['http_auth'])) $http_auth=strval($_GET['http_auth']);
|
||||||
|
if ($http_auth) {
|
||||||
|
if (empty($_SERVER['PHP_AUTH_USER']) || empty($_SERVER['PHP_AUTH_PW'])) {
|
||||||
|
header('WWW-Authenticate: Basic realm="Test Authentication System"');
|
||||||
|
header('HTTP/1.0 401 Unauthorized');
|
||||||
|
} else {
|
||||||
|
// Gruiiik
|
||||||
|
$_REQUEST["username"]=$_SERVER['PHP_AUTH_USER'];
|
||||||
|
$_REQUEST["password"]=$_SERVER['PHP_AUTH_PW'];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
require_once("../class/config.php");
|
require_once("../class/config.php");
|
||||||
|
|
||||||
if (!$mem->checkid())
|
if (!$mem->checkid())
|
||||||
|
@ -39,4 +53,4 @@ if (!$mem->checkid())
|
||||||
include("main.php");
|
include("main.php");
|
||||||
exit;
|
exit;
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
|
Loading…
Reference in New Issue