views:

54

answers:

0

Hello all, I am trying to set up Digest Auth on shared server.

I am using the script found here. Works on my home set up but when i use it on the host i get the error...

Notice: HTTP Digest headers not being passed to PHP by the server, unable to authenticate user in <filename>

Last time encountered this with another host they said they could not alter the setting to enable the script to work. The error msg given above is produced by this bit of code

if (isset($_SERVER['Authorization'])) {
            $authorization = $_SERVER['Authorization'];
    } elseif (function_exists('apache_request_headers')) {
        $headers = apache_request_headers();
        if (isset($headers['Authorization'])) {
            $authorization = $headers['Authorization'];
        }
    } else {
        trigger_error('HTTP Digest headers not being passed to PHP by the server, unable to authenticate user');
        exit;

Could anyone help me solve this or is there another method i could use?

Thank for any help!