Urgent: Apache 1.3.6 and authentication bis

From: Date: Sat, 04 Sep 1999 09:57:37 +0000
Subject: Urgent: Apache 1.3.6 and authentication bis
Groups: php.dev 
Request: Send a blank email to php-dev+get-10539@lists.php.net to get a copy of this message
Hi! I do have some troubles installing on a Windows NT Server (with Apache 1.3.6 Win32 pre-compiled distribution, PHP 3.0.11 and MySQL 3.22) the tool we just developped under a SUN machine... Everything works fine until we ask the user to get authentified: We use the Header authentication method by mod_php: **** extract **** if(!isset($PHP_AUTH_USER)) { Header("WWW-authenticate: basic realm=\"tool admin\""); Header("HTTP/1.0 401 Unauthorized"); require("config.inc"); echo"<blockquote>\n <br>\n <message> exit; } etc... **************** It's OK with the SUN server (nothing is transmitted before the Header) Under NT, we never see the authentication popup window, but we get the following error message: ******************** Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator, xxxxxx and inform them of the time the error occurred, and anything you might have done that may have caused the error. More information about this error may be available in the server error log. ********************** And the server error log gives us: ********************** [Thu Sep 02 19:37:15 1999] [error] [client xxxxxx] malformed header from script. Bad header=HTTP/1.0 401 Unauthorized: d:/phpgroup/php3/php.exe ********************** Someone suggested us to set the folowing header Header("Status: 401 Unauthorized"); We finally get the popup window... without passing through... another suggestion was to swapp the order of the two Header. No success! If someone else has a good idea... Thanks a lot Pierre

« previous php.dev (#10539) next »