[horde] Horde4: CompositeAuthentication
Michael Gröne
michael.groene at zel.uni-hannover.de
Thu Mar 24 20:50:28 UTC 2011
Am 24.03.2011 19:52, schrieb Michael M Slusarz:
> Quoting Michael Gröne <michael.groene at zel.uni-hannover.de>:
>
>> Am 24.03.2011 18:10, schrieb Michael M Slusarz:
>>> Quoting Michael Gröne <michael.groene at zel.uni-hannover.de>:
>>>
>>>> Am Mi 23 Mär 2011 06:07:47 CET schrieb Michael M Slusarz
>>>> <slusarz at horde.org>:
>>>>
>>>>> Quoting Michael Gröne <michael.groene at zew.uni-hannover.de>:
>>>>>
>>>>>> Am Fr 18 Mär 2011 10:57:20 CET schrieb Michael Gröne
>>>>>> <michael.groene at zew.uni-hannover.de>:
>>>>>>
>>>>>>> Missing admin_driver parameter.
>>>>>>> 5. Horde_Auth::factory()
>>>>>>> /usr/share/php/Horde/Core/Factory/Auth.php:150
>>>>>>
>>>>>> Ah, I see: Auth.php, line 83ff
>>>>>> case 'composite':
>>>>>> // TODO
>>>>>> $params['admin_driver'] = null;
>>>>>> $params['auth_driver'] = null;
>>>>>> break;
>>>>>>
>>>>>> Can you estimate, whether this will be working in any of the
>>>>>> upcoming releases, though it is not listed as showstopper?
>>>>>
>>>>> This has been fixed. Note that the format of the configuration entry
>>>>> has changed.
>>>>
>>>> Thank you so far.
>>>>
>>>> But now I got another error:
>>>> Ein schwerer Fehler ist aufgetreten:
>>>> Horde_Auth: Class definition of H not found.
>>>> 1. Horde_Registry::appInit()
>>>> /var/www/horde4_test/services/portal/index.php:12
>>>> 2. Horde_Registry->pushApp() /usr/share/php/Horde/Registry.php:238
>>>> 3. Horde_Registry->checkExistingAuth()
>>>> /usr/share/php/Horde/Registry.php:1259
>>>> 4. Horde_Core_Factory_Auth->create()
>>>> /usr/share/php/Horde/Registry.php:2169
>>>> 5. Horde_Core_Factory_Auth->_create()
>>>> /usr/share/php/Horde/Core/Factory/Auth.php:61
>>>> 6. Horde_Core_Factory_Auth->_create()
>>>> /usr/share/php/Horde/Core/Factory/Auth.php:108
>>>> 7. Horde_Auth::factory() /usr/share/php/Horde/Core/Factory/Auth.php:178
>>>
>>> Did you update your configuration?
>>
>> Yes, I had changed it, according the howto in the Wiki.
>> $conf['auth']['params']['admin_driver']['driver'] = 'ldap';
>> $conf['auth']['params']['admin_driver']['params']=array(
>> ...specific params...
>> );
>> and
>> $conf['auth']['params']['auth_driver']['driver'] = 'application';
>> $conf['auth']['params']['auth_driver']['params'] =array(
>> "app"=>"imp"
>> );
>
> I can't reproduce using this configuration:
>
> $conf['auth']['driver'] = 'composite';
> $conf['auth']['params']['admin_driver']['driver'] = 'application';
> $conf['auth']['params']['admin_driver']['params'] = array('app' => 'imp');
> $conf['auth']['params']['auth_driver']['driver'] = 'application';
> $conf['auth']['params']['auth_driver']['params'] = array('app' => 'imp');
Okay, thank you, got it working so far, I had my config messed up.
Now my config looks like this:
$conf['auth']['driver'] = 'composite';
$conf['auth']['params']['admin_driver']['driver'] = 'sql';
$conf['auth']['params']['admin_driver']['params']=array(
"driverconfig"=>"custom",
"phptype"=>"mysql",
"protocol"=>"unix",
"hostspec"=>"localhost",
"username"=>"username",
"password"=>"pw",
"database"=>"standard_django_pcdb",
"splitread"=>false,
"table"=>"pcinventory_zewuser",
"username_field"=>"email_zew",
"password_field"=>""
);
$conf['auth']['params']['auth_driver']['driver'] = 'application';
$conf['auth']['params']['auth_driver']['params'] =array(
"app"=>"imp"
);
First issue I notice now, is that on the login-page (imp) the serverlist
is missing, although $conf[server][server_list] is "shown".
Second issue: Going to http://horde4/admin/user.php I get an error:
QUERY FAILED: Table 'horde4.pcinventory_zewuser' doesn't exist SELECT
email_zew FROM pcinventory_zewuser
1. Horde_Core_Auth_Application->listUsers()
/var/www/horde4_test/admin/user.php:253
2. Horde_Auth_Composite->listUsers()
/usr/share/php/Horde/Core/Auth/Application.php:250
3. Horde_Auth_Sql->listUsers() /usr/share/php/Horde/Auth/Composite.php:146
Details
Horde_Auth_Exception Object
(
[details] =>
[message:protected] => QUERY FAILED: Table
'horde4.pcinventory_zewuser' doesn't exist
SELECT email_zew FROM pcinventory_zewuser
[string:Exception:private] =>
[code:protected] => 1146
[file:protected] => /usr/share/php/Horde/Auth/Sql.php
[line:protected] => 298
[trace:Exception:private] => Array
(
[0] => Array
(
[file] => /usr/share/php/Horde/Auth/Composite.php
[line] => 146
[function] => listUsers
[class] => Horde_Auth_Sql
[type] => ->
[args] => Array
(
)
)
...
As you can see, the usernames (here: the mailaddresses) are looked up in
a wrong database. "Horde4"-database is configured on the sql-tab in the
horde-configuration, but here we have to use another database which I
set in the admin_driver --> standard_django_pcdb. Apparently this is not
respected by the Sql-Driver?
michael
--
Michael Gröne
ZELSW - Zentrale Einrichtung Lehre, Studium und Weiterbildung
Abt.3: Weiterbildung, EDV
Leibniz Universität Hannover
Schloßwender Str. 5
30159 Hannover
Tel. +49 511 762 5437
Fax: +49 511 762 5686
http://www.zew.uni-hannover.de
More information about the horde
mailing list