Liveuser - can't create auth container instance
| From: | Jeroen Houben | Date: | Wed, 31 Aug 2005 10:26:24 +0000 |
| Subject: | Liveuser - can't create auth container instance | ||
| Groups: | php.pear.general | ||
| Request: | Send a blank email to pear-general+get-20679@lists.php.net to get a copy of this message | ||
Me again ;-)
I'm trying to execute the getUsers() method on a liveruser admin instance
$LUOptions = array(
'autoInit' => true,
'login' => array(
'force' => true
),
'logout' => array(
'destroy' => true,
),
'authContainers' => array(
'radius' => array(
'type' => "PEARAuth",
'pearAuth' => new TERENA_Auth_Radius(null, false)
),
),
'permContainer' => array(
'type' => 'Medium',
'storage' => array(
'DB' => array(
'dsn' => $dsn,
'prefix' => 'lu_',
)
),
),
);
$lu_admin = LiveUser_Admin::factory($LUOptions);
var_dump($lu_admin->getUsers());
That throws the following exception:
Error stack: array(7) {
["code"]=>
int(-1)
["params"]=>
array(1) {
["msg"]=>
string(40) "Could not create auth container instance"
}
["package"]=>
string(14) "LiveUser_Admin"
["level"]=>
string(9) "exception"
["time"]=>
float(1125483594.4072)
["context"]=>
array(4) {
["file"]=>
string(44) "/usr/local/share/php/pear/LiveUser/Admin.php"
["line"]=>
int(334)
["function"]=>
string(21) "setAdminAuthContainer"
["class"]=>
string(14) "LiveUser_Admin"
}
["message"]=>
string(58) "An error occurred Could not create auth container instance"
}
It seems the admin class calls
$auth = &LiveUser::authFactory(
$this->_conf['authContainers'][$authName],
$authName,
'LiveUser_Admin_'
);
this fails because the authFactory method tries to load a class called LiveUser_Admin_Auth_PEARAuth - which does not exist.
Could somebody point me in the right direction?
I also get a second exception, but maybe that's related to the above
Error stack: array(7) {
["code"]=>
int(-1)
["params"]=>
array(1) {
["msg"]=>
string(23) "Perm container not set."
}
["package"]=>
string(14) "LiveUser_Admin"
["level"]=>
string(9) "exception"
["time"]=>
float(1125483791.2727)
["context"]=>
array(4) {
["file"]=>
string(44) "/usr/local/share/php/pear/LiveUser/Admin.php"
["line"]=>
int(598)
["function"]=>
string(15) "_getUsersByPerm"
["class"]=>
string(14) "LiveUser_Admin"
}
["message"]=>
string(41) "An error occurred Perm container not set."
}
TIA,
Jeroen