Re: [Phplib-users] Patch for auth.inc in 7.2d
Brought to you by:
nhruby,
richardarcher
From: Giancarlo <gia...@na...> - 2003-02-08 19:17:44
|
Benjamin Boksa wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Hi Marko, > > take a look at auth.inc and I tell you the idea behind my patch: > > So what happens if you haven't authorized and call a page? First 'if > ($this->is_authenticated())' (line 67), which you are not, so the else > block is executed which sets $state to 1 (line 91). Then you go into the > block for 'case 1' (line 95). As you want to login you are in "log"-mode > so you go into the block for "log"-mode (line 109). If nobody is not set > you go into the block after else (line 117). > > This is the point were my patch jumps in. Usually the phplib would now > display the login form, ignoring that the username and password passed > to the page might already contain the information necessary to login. + What is the value of $auth->auth[uid] at this moment? If you are expecting username/passqord then auth->auth[uid] should value 'form', because whenever a login form is shown, an thus before its content can be taken taken into consideration, it has to value 'form'. This is the way phplib used to work. Try set &auth->auth[uid]='form' anytime anywhere (at the very start of every page if you are to have a logoin form everywhere), that should unblock this. > All I do now is calling $uid = $this->auth_validatelogin() at this point > to check these information passed to the page. > > If you have got further questions just drop me an eMail. > > Regards, > > Benne > > > Am Freitag, 07.02.03, um 10:54 Uhr (Europe/Berlin) schrieb Marko Kaening: > >> Hi Benjamin, >> >>> does it still happen after you applied the patch to auth.inc? >> >> still didn't apply the patch, since couldn't really figure out how to >> reproduce this strange behaviour. So there is no real test of this >> possible. just have to live with it so far. I also wait for some response >> from the list whether other people patched and what they thinkr about >> this >> approach. >> >> Marko > > > > - -- > Benjamin Boksa > b....@si... > > side by site GmbH & Co. KG > Druckgestaltung & Webdesign > > Barbarastr. 3-9 (Block 6) > D-50735 Koeln > > Fon: +49 221 2790964 > Fax: +49 221 2790965 > > http://www.sidebysite.de/ > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.0.7 (Darwin) > > iD8DBQE+RN8IR5U9XkJXZKwRAtfPAJwMNZd9flGk1N6Qvgf6fxkIQ+yFEQCeJ/QT > BK/MmuGAxC405b/ARsiToWM= > =qcux > -----END PGP SIGNATURE----- > > > > ------------------------------------------------------- > This SF.NET email is sponsored by: > SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! > http://www.vasoftware.com > _______________________________________________ > Phplib-users mailing list > Php...@li... > https://lists.sourceforge.net/lists/listinfo/phplib-users > |