I am building a caldav server. It is already working with many other clients but not with IOS caldav client. Server is implemented with python and it is running on the top of Apache 2.
When reading my server logfile I can see that IOS client is making multiple PROPFIND,OPTIONS,PROPPATCH and REPORT requests. (My server does not support PROPPATCH). IOS can find the calendar and calendar is visible as a calendar list on iPad calendar app.
The problem is that iPad calendar does not show any events or vtodos and I can see on logs that clients REPORT request do not contain any "calendar-data" prop's. I don't know why client does not ask calendar-data at any REPORT requests?
(Sorry for bad formatting. I Made lot of work to format content properly, but it was difficult to format XML and result is far from good)
Here some access log lines:
62.44.192.148 - - [15/Jan/2018:10:56:09 +0200] "PROPFIND /juha/neo/ HTTP/1.1" 401 12 "-" "iOS/9.3.5 (13G36) accountsd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:09 +0200] "PROPFIND /juha/neo/ HTTP/1.1" 207 486 "-" "iOS/9.3.5 (13G36) accountsd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:09 +0200] "OPTIONS /juha/neo/ HTTP/1.1" 200 - "-" "iOS/9.3.5 (13G36) accountsd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:14 +0200] "PROPFIND /juha/neo/ HTTP/1.1" 401 12 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:14 +0200] "PROPFIND /juha/neo/ HTTP/1.1" 207 1570 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:14 +0200] "OPTIONS /juha/neo/ HTTP/1.1" 200 - "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:14 +0200] "PROPFIND /juha/neo/ HTTP/1.1" 207 1996 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:15 +0200] "PROPPATCH /juha/neo/ HTTP/1.1" 405 244 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:15 +0200] "PROPFIND /juha/neo/ HTTP/1.1" 207 418 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:15 +0200] "REPORT /juha/neo/ HTTP/1.1" 207 5640 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:15 +0200] "REPORT /juha/neo/ HTTP/1.1" 207 2146 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:17 +0200] "PROPFIND / HTTP/1.1" 401 12 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:17 +0200] "PROPFIND / HTTP/1.1" 207 1570 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:17 +0200] "OPTIONS / HTTP/1.1" 200 - "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:17 +0200] "PROPFIND /juha/neo/ HTTP/1.1" 207 1996 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:17 +0200] "PROPPATCH /juha/neo/ HTTP/1.1" 405 244 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:17 +0200] "PROPFIND /juha/neo/ HTTP/1.1" 207 418 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:18 +0200] "REPORT /juha/neo/ HTTP/1.1" 207 5640 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:18 +0200] "REPORT /juha/neo/ HTTP/1.1" 207 2146 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:25 +0200] "PROPFIND /.well-known/caldav HTTP/1.1" 401 12 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
62.44.192.148 - - [15/Jan/2018:10:56:25 +0200] "PROPFIND /.well-known/caldav HTTP/1.1" 207 506 "-" "iOS/9.3.5 (13G36) dataaccessd/1.0"
Here is some sample requests and responses:
PROPFIND
{'Accept-Encoding': 'gzip, deflate', 'Accept-Language': 'en-gb', 'Brief': 't', 'Depth': '0', 'Prefer': 'return=minimal', 'Host': '192.168.1.202', 'Content-Length': '181', 'Content-Type': 'text/xml', 'Connection': 'keep-alive', 'User-Agent': 'iOS/9.3.5 (13G36) accountsd/1.0', 'Accept': '/', 'Authorization': 'Basic anVoYTpqdWhh'}
<?xml version="1.0" encoding="UTF-8"?>
<A:propfind xmlns:A="DAV:">
<A:prop><A:current-user-principal/><A:principal-URL/>
<A:resourcetype/></A:prop></A:propfind>
Response headers:
{'DAV': '1, calendar-access, calendar-schedule, calendar-query', 'Content-Type': 'application/xml; charset=UTF-8'}
<?xml version="1.0"?>\n<D:multistatus xmlns:D="DAV:">
<D:response><D:href>/juha/neo/</D:href><D:propstat>
<D:status>HTTP/1.1 200 OK</D:status><D:prop><D:resourcetype><D:collection />
<D:calendar xmlns:D="urn:ietf:params:xml:ns:caldav"/></D:resourcetype>
<D:current-user-principal><D:href>/juha/neo/</D:href>
</D:current-user-principal>
</D:prop></D:propstat>
</D:response></D:multistatus>
OPTIONS
{'Content-Length': '0', 'Accept-Encoding': 'gzip, deflate', 'Accept-Language': 'en-gb', 'Connection': 'keep-alive', 'Host': '192.168.1.202', 'Accept': '/', 'User-Agent': 'iOS/9.3.5 (13G36) accountsd/1.0', 'Authorization': 'Basic anVoYTpqdWhh'}
Response headers:
{'Content-Length': '0', 'DAV': 'DAV: 1, calendar-access, calendar-schedule, calendar-query', 'Content-Type': 'application/xml; charset=UTF-8', 'Allow': 'OPTIONS, PROPFIND, REPORT, PUT, GET, DELETE'}
PROPFIND {'Accept-Encoding': 'gzip, deflate', 'Accept-Language': 'en-gb', 'Brief': 't', 'Depth': '0', 'Prefer': 'return=minimal', 'Host': '192.168.1.202', 'Content-Length': '743', 'Content-Type': 'text/xml', 'Connection': 'keep-alive', 'User-Agent': 'iOS/9.3.5 (13G36) dataaccessd/1.0', 'Accept': '/', 'Authorization': 'Basic anVoYTpqdWhh'}
request body:<?xml version="1.0" encoding="UTF-8"?>
<A:propfind xmlns:A="DAV:">\n <A:prop>
<B:calendar-home-set xmlns:B="urn:ietf:params:xml:ns:caldav"/>
<B:calendar-user-address-set xmlns:B="urn:ietf:params:xml:ns:caldav"/>
<A:current-user-principal/><A:displayname/>
<C:dropbox-home-URL xmlns:C="http://calendarserver.org/ns/"/>
<C:email-address-set xmlns:C="http://calendarserver.org/ns/"/>
<C:notification-URL xmlns:C="http://calendarserver.org/ns/"/>
<A:principal-collection-set/><A:principal-URL/><A:resource-id/>
<B:schedule-inbox-URL xmlns:B="urn:ietf:params:xml:ns:caldav"/>
<B:schedule-outbox-URL xmlns:B="urn:ietf:params:xml:ns:caldav"/>
<A:supported-report-set/></A:prop></A:propfind>
response headers:{'DAV': '1, calendar-access, calendar-schedule, calendar-query', 'Content-Type': 'application/xml; charset=UTF-8'}
<?xml version="1.0"?>
<D:multistatus xmlns:C="urn:ietf:params:xml:ns:caldav" xmlns:D="DAV:" xmlns:ID="urn:inverse:params:xml:ns:inverse-dav">
<D:response><D:href>/juha/neo/</D:href>
<D:propstat><D:status>HTTP/1.1 200 OK</D:status><D:prop>
<D:supported-report-set xmlns:ID="urn:inverse:params:xml:ns:inverse-dav">
<D:supported-report><D:report><C:calendar-multiget/></D:report>
</D:supported-report><D:supported-report><D:report>
<C:calendar-query/></D:report></D:supported-report>
<D:supported-report><D:report><ID:acl-query/>
</D:report></D:supported-report>
<D:supported-report><D:report>
<D:sync-collection/></D:report>
</D:supported-report><D:supported-report>
<D:report>
<C:expand-property/>
</D:report>
</D:supported-report>
</D:supported-report-set>
<D:displayname>Juha Martikainen Neo</D:displayname>
<D:current-user-principal>
<D:href>/juha/neo/</D:href>
</D:current-user-principal>
<C:calendar-home-set>
<D:href>http://192.168.1.202/juha/neo/</D:href>
</C:calendar-home-set>
<C:calendar-user-address-set>
<D:href>mailto:juham@anygraaf.fi</D:href>
</C:calendar-user-address-set>
</D:prop></D:propstat>
</D:response>\n</D:multistatus>
REPORT
{'Accept-Encoding': 'gzip, deflate', 'Accept-Language': 'en-gb', 'Brief': 't', 'Depth': '1', 'Prefer': 'return=minimal', 'Host': '192.168.1.202', 'Content-Length': '390', 'Content-Type': 'text/xml', 'Connection': 'keep-alive', 'User-Agent': 'iOS/9.3.5 (13G36) dataaccessd/1.0', 'Accept': '/', 'Authorization': 'Basic anVoYTpqdWhh'}
Request body:
<?xml version="1.0" encoding="UTF-8"?>
<B:calendar-query xmlns:B="urn:ietf:params:xml:ns:caldav">
<A:prop xmlns:A="DAV:"><A:getcontenttype/><A:getetag/>
</A:prop><B:filter>
<B:comp-filter name="VCALENDAR"><B:comp-filter name="VEVENT">
<B:time-range start="20171015T000000Z"/></B:comp-filter></B:comp-filter>
</B:filter></B:calendar-query>
Response:
<?xml version="1.0"?><D:multistatus xmlns:D="DAV:">
<D:response>
<D:href>/juha/neo/c3c15486-03c9-4bf4-a91c-fc406ba605a5.ics</D:href>
<D:propstat><D:prop>
<D:getetag>"d41d8cd98f00b204e9800998ecf8427e"</D:getetag>
<D:getcontenttype>text/calendar;component=vevent
</D:getcontenttype>
<D:status>HTTP/1.1 207 OK</D:status></D:prop></D:propstat>
</D:response><D:response>
<D:href>/juha/neo/16d76c9e-e783-476b-83a3-b3de4c4d4cf9.ics</D:href>
<D:propstat><D:prop>
<D:getetag>"d41d8cd98f00b204e9800998ecf8427e"</D:getetag>
<D:getcontenttype>text/calendar;component=vevent
</D:getcontenttype>
<D:status>HTTP/1.1 207 OK</D:status>
</D:prop></D:propstat></D:response>
<D:response>
<D:href>/juha/neo/64a9fed6-72ae-417d-98f7-b981ae501bbd.ics</D:href>
<D:propstat><D:prop><D:getetag>"d41d8cd98f00b204e9800998ecf8427e"
</D:getetag>
<D:getcontenttype>text/calendar;component=vevent</D:getcontenttype>
<D:status>HTTP/1.1 207 OK</D:status></D:prop>
</D:propstat></D:response><D:response>
<D:href>/juha/neo/7177d736-230e-4639-9df8-d18333bf0428.ics</D:href>
<D:propstat><D:prop><D:getetag>"d41d8cd98f00b204e9800998ecf8427e"
</D:getetag>
<D:getcontenttype>text/calendar;component=vevent</D:getcontenttype>
<D:status>HTTP/1.1 207 OK</D:status></D:prop></D:propstat></D:response>
<D:response><D:href>/juha/neo/1c010891-3822-4c6a...
REPORT
{'Accept-Encoding': 'gzip, deflate', 'Accept-Language': 'en-gb', 'Brief': 't', 'Depth': '1', 'Prefer': 'return=minimal', 'Host': '192.168.1.202', 'Content-Length': '318', 'Content-Type': 'text/xml', 'Connection': 'keep-alive', 'User-Agent': 'iOS/9.3.5 (13G36) dataaccessd/1.0', 'Accept': '/', 'Authorization': 'Basic anVoYTpqdWhh'}
Request body:
<?xml version="1.0" encoding="UTF-8"?>
<B:calendar-query xmlns:B="urn:ietf:params:xml:ns:caldav">
<A:prop xmlns:A="DAV:">
<A:getetag/><A:getcontenttype/>
</A:prop>
<B:filter>
<B:comp-filter name="VCALENDAR">
<B:comp-filter name="VTODO"/>
</B:comp-filter>
</B:filter>
</B:calendar-query>
Response:
<?xml version="1.0"?><D:multistatus xmlns:D="DAV:">
<D:response>
<D:href>/juha/neo/juha.martikainen@anygraaf.fi/neo/4n57t1gead4d.ics</D:href>
<D:propstat><D:prop>
<D:getetag>"d41d8cd98f00b204e9800998ecf8427e"</D:getetag>
<D:getcontenttype>text/calendar;component=vtodo</D:getcontenttype>
<D:status>HTTP/1.1 207 OK</D:status></D:prop></D:propstat></D:response>
<D:response><D:href>/juha/neo/jma-8crr2yyya203728.ics</D:href><D:propstat>
<D:prop><D:getetag>"d41d8cd98f00b204e9800998ecf8427e"</D:getetag>
<D:getcontenttype>text/calendar;component=vtodo</D:getcontenttype>
<D:status>HTTP/1.1 207 OK</D:status></D:prop></D:propstat>
</D:response>
<D:response>
<D:href>/juha/neo/155ca994-856f-430d-9e1f-f3861b33b533.ics</D:href>
<D:propstat><D:prop>
<D:getetag>"d41d8cd98f00b204e9800998ecf8427e"</D:getetag>
<D:getcontenttype>text/calendar;component=vtodo</D:getcontenttype>
<D:status>HTTP/1.1 207 OK</D:status></D:prop></D:propstat>
</D:response><D:response>
<D:href>/juha/neo/cab0d5b4-1d24-4a3f-a796-098387c4f82d.ics</D:href>
<D:propstat><D:prop>
<D:getetag>"d41d8cd98f00b204e9800998ecf8427e"</D:getetag>
<D:getcontenttype>text/calendar;component=vtodo</D:getcontenttype>
<D:status>HTTP/1.1 207 OK</D:status></D:prop></D:propstat>\n
</D:response>\n<D:response>
<D:href>/juha/neo/e37d9662-231c-46c9-add5-beac50...