Home » Authentication » Auth » Bug #1655
page hangs with no error display
Details
| Submitted | 2004-06-16 13:06 UTC |
|---|---|
| From | alessio dot f at cost dot it |
| Status | Bogus |
| Package | Auth |
| PHP Version | 5.0.0RC3 (Release Candidate 3) |
| OS | fedora core 1 |
| Roadmaps | (Not assigned) |
Comments
[2004-06-16 13:06 UTC] alessio dot f at cost dot it
Description:
------------
Just a test using the simple code found in domentation.
I can see nothing. No errors, no warnings, no html.
The page simply hangs.
Reproduce code:
---------------
<?php
require_once 'DB.php';
require_once "Auth/Auth.php";
function loginFunction ()
{
/**
* Change the HTML output so that it fits to your
* application.
*/
echo "<form method=\"post\" action=\"" . $_SERVER['PHP_SELF'] . "\">";
echo "<input type=\"text\" name=\"username\">";
echo "<input type=\"password\" name=\"password\">";
echo "<input type=\"submit\">";
echo "</form>";
}
$dsn = "mysql://dbuser:dbpassword@localhost/test";
$a = new Auth("DB", $dsn, "loginFunction");
$a->start();
echo "Everybody can see this text!<br />";
if (!isset($_GET['login'])) {
echo "<a href=\"testAuth.php\">Click here to log in</a>\n";
}
//if ($a->getAuth())
{
echo "One can only see this if he is logged in!";
}
?>
[2004-07-05 22:02 UTC] slhutson at gmail dot com
I'm having the same issue, with version 1.3.0r2 on fedora core 2, and same php version. getAuth is returning false but seesion is being registed. When I downgrade to version 1.3.0r1, everything works properly.
[2004-07-08 10:32 UTC] alpha at losc dot net
same issue, getAuth() return nothing...
PHP 4.3.7 (cgi)
[2004-07-13 10:54 UTC] martind at boltblue dot com
I think this is a slight bug in: Auth.php
function getAuth() {
if ( isset($this->session['registered']) ) {
$this->session['registered'];
}
return false;
}
As can be seen, getAuth never returns true... I think the return has been ommitted, should be:
function getAuth() {
if ( isset($this->session['registered']) ) {
return $this->session['registered'];
}
return false;
}