This commit is contained in:
Klaus-Uwe Mitterer 2017-10-09 09:27:59 +02:00
parent cc3cb6e99c
commit 35f44e4e36

View file

@ -15,6 +15,7 @@ $realm = 'GPS Tracker';
if (empty($_SERVER['PHP_AUTH_DIGEST'])) {
header('HTTP/1.1 401 Unauthorized');
header('WWW-Authenticate: Digest realm="'.$realm.
'",qop="auth",nonce="'.uniqid().'",opaque="'.md5($realm).'"');
die('Authentication failed.');
}