[Phplib-users] Patch for auth.inc in 7.2d
Brought to you by:
nhruby,
richardarcher
From: Benjamin B. <b....@si...> - 2003-02-06 13:01:52
|
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hi! I had the problem that I had to go through the phplib-login mechanism even if I posted the username and the password to the Auth-protected page: user enters data -> phplib -> user has to enter data again for phplib - -> user can access page The included patch fixes that "problem" so that: user enters data -> user can access page Please send me your comments if you like. Regards, Benne - --- begin patch --- *** auth.inc.orig Thu Feb 6 11:21:51 2003 - --- auth.inc Thu Feb 6 11:30:09 2003 *************** *** 115,127 **** $this->auth["refresh"] = 0x7fffffff; return true; } else { ! # Show the login form ! $this->auth_loginform(); ! $this->auth["uid"] = "form"; ! $this->auth["exp"] = 0x7fffffff; ! $this->auth["refresh"] = 0x7fffffff; ! $sess->freeze(); ! exit; } break; case "reg": - --- 115,135 ---- $this->auth["refresh"] = 0x7fffffff; return true; } else { ! if ($uid = $this->auth_validatelogin()) { ! $this->auth["uid"] = $uid; ! $this->auth["exp"] = time() + (60 * $this->lifetime); ! $this->auth["refresh"] = time() + (60 * $this->refresh); ! return true; ! } ! else { ! # Show the login form ! $this->auth_loginform(); ! $this->auth["uid"] = "form"; ! $this->auth["exp"] = 0x7fffffff; ! $this->auth["refresh"] = 0x7fffffff; ! $sess->freeze(); ! exit; ! } } break; case "reg": - --- end patch --- -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.0.7 (Darwin) iD8DBQE+Qly7R5U9XkJXZKwRApSXAKCKBlxzDcaXKqVBJOGZ84ugp2/x6wCeLdEB YjnSLwdzdkVHT+8JoLIlqn4= =wwsr -----END PGP SIGNATURE----- |