FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » PEAR Auth package woes
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
PEAR Auth package woes [message #178375] Tue, 12 June 2012 00:32 Go to previous message
Eli the Bearded is currently offline  Eli the Bearded
Messages: 22
Registered: April 2011
Karma:
Junior Member
I've looked over the (sparse) docs here:

http://pear.php.net/manual/en/package.authentication.php

And I can find no mention of using this in a multiple webserver
configuration, that is N web servers (possibly with M database
servers) for N > 1 all trying to use the same authentication
cookies.

In my experiments with N=4 and M=1, I cannot get the servers
to recognize cookies set by other servers. I only used this
package instead of writing my own because I was assured it did
work for the M=1 case. Unfortunately the person who gave me
that advice is not available to talk to for another week or so.

Is there some secret setting to get this to work?

My configuration looks like this:

function loginFunction($username, $status, $auth) {
// make a login page then exit so nothing else gets shown
exit;
}


$options = array(
'dsn' => $dsn,
'usernamecol' => 'username',
'passwordcol' => 'password',
'table' => 'site_auth',
'db_fields' => array('name',
'company',
'user_id'),
'cryptType' => 'crypt',
'db_options' => array('portability' =>
MDB2_PORTABILITY_ALL ^
MDB2_PORTABILITY_FIX_CASE)
);

$a = new Auth("MDB2", $options, "loginFunction", $optional);

$a->start();

/* problem: only get here if they've logged in on THIS server */

Elijah
------
has solved this problem before in PHP using encrypt info in cookies
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Freelance Web deveeloper/designer required
Next Topic: json_decode problem
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Thu Nov 28 02:01:14 GMT 2024

Total time taken to generate the page: 0.05242 seconds