Bug #13319: possible fix
Jasper Olbrich <[email protected]>
| Newsgroups | gmane.comp.horde.devel |
|---|---|
| Message-ID | <[email protected]> |
Hello, I think I've implemented a fix for http://bugs.horde.org/ticket/13319. The main problem is that external calendars are no longer working if they expect HTTP Basic Auth. The problem is that in kronolith/lib/Driver/Ical.php the variable $sabreOptions['userName'] is set, but this breaks the request method in pear/php/Horde/Dav/Client.php because the authType of the SabreDAV client is AUTH_BASIC | AUTH_DIGEST. That leads to the DIGEST method being used in the Horde_Dav_Client class. My idea is to use the HTTP 401 response from the external calendar provider when the user is adding the external calendar, because that's the place where the provider tells us which authentication mode is required. In my (AFAI can tell, working) solution, this information is collected in Horde/Dav/Client.php and passed along using the Horde_Dav_Exception and the following Kronolith_Exception back to the Browser. Then the user enters his credentials and the desired authentication mode is sent back to the horde server as well. There it is used to access the calendar provider and finally stored in the database. I don't know why the user name is set in the sabreOptions in the first place (the change was introduced here https://github.com/horde/horde/commit/477f2c46041bde1b3bfa572d7fbac535046c3be6#diff-2a209d195528a6339e273da67af8fd86), but now something has to be done to fix this. If my approach is not completely wrong, I could provide a patch. Should I attach it to the bug tracker ticket? Or are there other, better ways to get the external calendars working again? -- Jasper -- dev mailing list Frequently Asked Questions: http://wiki.horde.org/FAQ To unsubscribe, mail: [email protected]