Re: User authorisation class

From: Date: Sat, 22 Jun 2002 18:36:58 +0000
Subject: Re: User authorisation class
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-7295@lists.php.net to get a copy of this message
Markus Wolff wrote:
1. The user class has a list of servers with their respective login information stored in an XML file. When a user tries to login, the class makes a new connection to each of the servers/containers until a match is found. 2. The user class does not do any connections by itself, but you can pass connection objects to it (ie. a PEAR::DB object that already contains an open connection) that are then used in the order they are passed. 3. The user class _always_ uses SOAP or XML/RPC to connect to a central authentication server. That server then manages the connection to the true storage containers. Just an idea:
The class has a list of servers as described in solution one. Then, when using the class you can pass to it already open connection objects as in solution two. For every connection object passed, the class uses it instead of the next item in the list. If no object was passed, the class would open the connection if necessary. This would mean of course putting the already used connections (local db etc.) on the top of the list. But it solves your problem. -- Best Regards, Sagie Maoz n0nick@php.net http://n0nick.dns2go.com/n0where/ ~ Personal mumblings http://sodans.sourceforge.net/ ~ Hebrew CMS

« previous php.pear.dev (#7295) next »