Apple Calendar Authentication Cookies

Has anyone ever got Calendar to send cookies?


We are currently developing a CalDAV Service for an online platform with Basic Authentication over HTTPS. So far everything works fine with Apple Calendar on OSX and iOS.


When Calendar tries to sync events it contacts our Server which answers with a 401 status code asking for a HTTP Basic Authentication. Calendar then sends the credentials and is granted access. At the same time our server sends an PHP Session Cookie in order to keep the device logged in for some time.


This works fine with Calendar on iOS but Calendar on OSX for some reason refuses to send the session cookie.


Syncing still works but as 7 calendars are checked on every sync for every user this results in permanent reauthentication and thousands of new sessions in our database.


I would appreciate any hint on how we could get OSX Calendar to either send cookies or any other kind of identifying token. Maybe there are better ways for authentication than HTTP Basic Auth. Digest Auth wouldn't work as we are only storing hashed passwords and I haven't found documentation about how to implement an OAuth2 like authentication for Calendar.


Thanks in advance, Michael

Apple Calendar Authentication Cookies
 
 
Q