[phplib] Default authentication again!! From: Dominic Paschke (dominic.paschke <email protected>)
Date: 10/18/00

Hi List!

I still don't know, how to get default login running. I looked into
the source of phplib, but I didn't understand everything, maybe
anybody can explain it to me. Thats the way I understood it:
 
If $nobody=true, I can login to this page without trouble:
<?
# using Default Authentication
 page_open(array("sess" => "My_Session",
                 "auth" => "My_Auth"));
 #$auth->login_if($again);
 #if ($auth->auth["uid"] == "nobody"):
?>
<A HREF="<?php $sess->purl("$PHP_SELF?again=yes") ?>">Login</A>
<?php
 endif;
 page_close();
?>

Then, if I try to relogin as a different user, stands in the <form>-tag of
loginform.ihtml the following action-URL:
<form action="/myAdminManager/index.php3?again=yes&My_Session=
   44ee155594b1c916f01ed35d29e80244" method=post>
But when I try to login now, I get the message username invalid. BTW,
$allowcache is "no".
So what's happening there?
It looks to me, that the user, is authenticated as usual, because the page
starts with:
page_open(array("sess" => "My_Session",
                 "auth" => "My_Auth"));
But then, because of again=yes in the action-URL, he is logged out,
because the function auth->login_if() is called, isn't she?
Maybe that's the reason, why I can't relogin, not even with the test-
page of phplib default.php3!!!
It would be nice, if anybody could explain to me, how this should work!

greetinxxxx

Dominic

---------------------------------------------------------------------
To unsubscribe, e-mail: phplib-unsubscribe <email protected>
For additional commands, e-mail: phplib-help <email protected>