Authentication doesn't work with caching enabled in Drupal 5
naquah - May 8, 2007 - 17:58
| Project: | HTTP authentication |
| Version: | 5.x-1.x-dev |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | naquah |
| Status: | closed |
Jump to:
Description
Because of the following checks introduced in Drupal 5:
<?php
function sess_read($key) {
...
// Handle the case of first time visitors and clients that don't store cookies (eg. web crawlers).
if (!isset($_COOKIE[session_name()])) {
$user = drupal_anonymous_user();
return '';
}
..
}
function sess_write($key, $value) {
...
// If the client doesn't have a session, and one isn't being created ($value), do nothing.
if (empty($_COOKIE[session_name()]) && empty($value)) {
return TRUE;
}
...
}
?>cookie-less authentication doesn't work when caching is enabled.

#1
It is no longer (or shouldn't be) necessary to do a redirect, so we don't need to pass the session ID by cookie nor by query string anymore.
Therefore this bug has been fixed.
#2
Automatically closed -- issue fixed for two weeks with no activity.