[horde] Horde4/BCBreaking

Christopher Neuhaus cne at ruhrverband.de
Wed Nov 2 11:55:39 UTC 2011


Am 02.11.2011 04:10, schrieb Michael M Slusarz:
> Quoting Christopher Neuhaus <cne at ruhrverband.de>:
>
>> Am 26.10.2011 20:22, schrieb Michael M Slusarz:
>>> Quoting Christopher Neuhaus <cne at ruhrverband.de>:
>>>
>>>> In our multi IMAP-/one Horde-Server environment, we use a
>>>> preauthentication hook to autoselect the IMAP-Server for the user.
>>>> Here
>>>> we extract the information of one of many IMAP-servers where the user
>>>> should authenticate. (just like http://wiki.horde.org/ImapSelect)
>>>>
>>>> After the H4 authentication cleaning process ..
>>>>
>>>>     http://wiki.horde.org/Horde4/BCBreaking: "Remove confusing mess of
>>>>     hooks and other ways of muddling logins (especially with IMP), and
>>>>     replace them _all_ with the preauthenticate and postauthenticate
>>>>     hooks + appropriate examples for things like vhosting. *(DONE)"*
>>>>     **
>>>>
>>>>  this solution doesn`t  work any more cause there are several changes,
>>>> that make this method impossible.
>>>
>>> How is it impossible?  Just disable the server selection list on the
>>> login page and set the desired server in the preauthenticate() hook.
>>> See imp/config/hooks.php.dist
>>>
>>> michael
>>>
>>> ___________________________________
>>> Michael Slusarz [slusarz at horde.org]
>>>
>>
>> Hi Michael,
>>
>> while we where searching, why our H3-hook doesn`t work for H4, we found
>> f.e. that in imp/lib/Auth.php $_SERVER['HTTP_HOST'] is take for
>> identifying the users authentication host. This has to be changed for
>> each user who authenticates against a different server.
>
> No - this is only used if 'preferred' is set in backends.php.  Don't
> set preferred.
>
>> I think we are not alone with our problem. Perhaps you have an idea how
>> our solution could be realised in a imp preauthenticate() hook?
>
> public function preauthenticate($userId, $credentials)
> {
>     // Do magic here to determine the preferred server.  Store the
> preferred server key (from backends.php)
>     // in $key
>
>     $credentials['server'] = $key;
>
>     return $credentials;
> }
>
> michael
>
> ___________________________________
> Michael Slusarz [slusarz at horde.org]
>
That`s it.
Sometimes it can be so simple!

Thanks.

Christopher

-- 

Dipl.-Ing. Christopher Neuhaus

Ruhrverband
Abteilung Datenverarbeitung
Kronprinzenstr. 37
45128 Essen

Telefon: 0201/178-1531
Telefax: 0201/178-1545
E-Mail: cne at ruhrverband.de
Internet: www.ruhrverband.de


Verbandsrat: Dr. Bernhard Görgens, Vorsitzender
Vorstand: Prof. Dr.-Ing. Harro Bode, Vorsitzender, Norbert Frece



More information about the horde mailing list