[Davical-general] DAViCal carddav and iOS

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

[Davical-general] DAViCal carddav and iOS

Vincent Van Houtte-2
Dear list,

I have been following the list for several years now, and have been aware of several issues with iDevices over the years, but I cannot seem to fix the issue that I'm having with a new install:

* Debian Jessie, fully up to date
* Apache 2.4.10 + mod_php
* DAViCal and awl from the backports repo
* subdomain installation, https only (Let's Encrypt certificate), port 8443
* LDAP authentication

Working:
* DAViCal web interface
* infCloud webclient (caldav+carddav)
* Evolution (caldav+carddav)
* Android Devices (caldav+carddav, both via 'caldav_sync' and 'davdroid' apps)
* iDevices (caldav only)

Not working:
* iDevices (carddav)

Symptom:
No matter which formatting I try in the iPhone's account settings (with and without https-prefix, with and without trailing slash, collection and principal level), the (advanced) Account-URL keeps being rewritten from the resource "/club/abook" to "/caldav.php/<username>"

The iPhone does not complain, but show the empty addressbook (related to the <username>).

The log does not show any errors, and even the debug -mode does not reveal anything relvant (other than the "caldav.php/<username>" being fetched.

Excerpt from the apache virtualhost (which I don't suspect to be faulty, but maybe I'm missing some mod_rewrite nuance...)

--
<VirtualHost *:80>
  Include               inc_server.conf
  ServerAlias           cal.<DOMAIN>

  # Redirect /.well-known URLs
  RewriteEngine on
  RewriteRule /.well-known(.*)$ /caldav.php/.well-known$1 [NC,L]

  # Redirect everything else to https (redirect gets executed after rewrite, independent of the order in which we put them here)
  Redirect permanent    / https://cal.<DOMAIN>:8443/
</VirtualHost>

<VirtualHost *:8443>
  Include               inc_server.conf
  Include               inc_ssl.conf
  DocumentRoot          /usr/share/davical/htdocs
  ServerAlias           cal.<DOMAIN>

  LogLevel              warn 
  ErrorLog              /var/log/apache2/cal-error.log

  DirectoryIndex        index.php /client/index.html
  FallbackResource      /index.php
  SetEnv                no-gzip=1

  Alias /images/        /usr/share/davical/htdocs/images/
  AcceptPathInfo        On

  php_value             include_path /usr/share/awl/inc
  php_value             magic_quotes_gpc 0
  php_value             register_globals 0
  php_value             error_reporting 1
  php_value             default_charset "utf-8"
  php_admin_flag        suhosin.server.strip off
  php_value             magic_quotes_runtime 0

  RewriteEngine On
  <IfModule mod_headers.c>
    Header unset Access-Control-Allow-Origin
    Header unset Access-Control-Allow-Methods
    Header unset Access-Control-Allow-Headers
    Header unset Access-Control-Allow-Credentials
    Header unset Access-Control-Expose-Headers

    # If your setup is working and complete you can replace the "*" with CardDavMATE instalation
    #  origin (protocol/host/port) - see the examples below (for multiple origins use multiple headers)
    Header always set Access-Control-Allow-Origin "https://cal.<DOMAIN>:8443"

#    Header always set Access-Control-Allow-Origin "*"
    Header always set Access-Control-Allow-Methods "GET,POST,OPTIONS,PROPFIND,PROPPATCH,REPORT,PUT,MOVE,DELETE,LOCK,UNLOCK"
    Header always set Access-Control-Allow-Headers "User-Agent,Authorization,Content-type,Depth,If-match,If-None-Match,Lock-Token,Timeout,Destination,Overwrite,Prefer,$
    Header always set Access-Control-Allow-Credentials false
    Header always set Access-Control-Expose-Headers "Etag,Preference-Applied"

    RewriteCond %{HTTP:Access-Control-Request-Method} !^$
    RewriteCond %{REQUEST_METHOD} OPTIONS
    RewriteRule ^(.*)$ $1 [R=200,L]
  </IfModule>

  <IfModule mod_rewrite.c>
#        RewriteEngine   On
        # Not if it's the root URL
        RewriteCond     %{REQUEST_URI} !^/$
        # Not if it is the directory for InfCloud
        RewriteCond     %{REQUEST_URI} !^/client/
        # Not if it is a .php program, script, stylesheet or image
        RewriteCond     %{REQUEST_URI} !\.(php|css|png|gif|js|jpg)
#       RewriteRule     /.well-known(.*)$ /caldav.php/.well-known$1 [NC,L]
        RewriteRule     ^(.*)$ /caldav.php$1  [NC,L]
        RewriteRule     ^/principals/users(.*)$ /caldav.php$1  [NC,L]
#       RewriteRule     .* - [E=AUTHORIZATION:%{HTTP:Authorization},L]
  </IfModule>

  <Directory /usr/share/davical/htdocs>
    SSLRequireSSL
    SSLOptions +StrictRequire
    Options FollowSymLinks
    Order Deny,Allow
    Allow from all
  </Directory>

 <Directory /usr/share/davical/htdocs/client/>
    AllowOverride FileInfo Limit
     <IfVersion >= 2.3>
         Require all granted
     </IfVersion>
     <IfVersion < 2.3>
         Order allow,deny
         Allow from all
     </IfVersion>
  </Directory>

# Add "Content-Type: text/cache-manifest" header for .manifest files
<IfModule mod_mime.c>
    AddType text/cache-manifest .manifest
</IfModule>

# Add "Cache-Control: max-age=0, must-revalidate, no-cache, no-transform, private" header for all files
#  for more information see: https://tools.ietf.org/html/rfc7234
<IfModule mod_headers.c>
    Header set Cache-Control "max-age=0, must-revalidate, no-cache, no-transform, private"
</IfModule>

<IfModule mod_deflate.c>
    SetOutputFilter DEFLATE
</IfModule>

# If you use mod_cache set the correct path for the cache.manifest here
#<IfModule mod_cache.c>
#    CacheDisable cache.manifest
#</IfModule>

</VirtualHost>
--

Thx for any hints pointing me in the right direction!

Vincent

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Davical-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/davical-general
Reply | Threaded
Open this post in threaded view
|

Re: DAViCal carddav and iOS

Vincent Van Houtte-2
I have enabled debugging and this is the output when I use a borrowed iPhone to connect to /club/abook/:

DAViCal: LOG: :***************** Request Header ****************
DAViCal: LOG: :PROPFIND /club/abook/
DAViCal: LOG: headers:-->Host: cal.<domain>:8443
DAViCal: LOG: headers:-->User-Agent: iOS/9.3.4 (13G35) accountsd/1.0
DAViCal: LOG: headers:-->Depth: 0
DAViCal: LOG: headers:-->Content-Type: text/xml
DAViCal: LOG: headers:-->Content-Length: 181
DAViCal: LOG: headers:-->Brief: t
DAViCal: LOG: headers:-->Accept: */*
DAViCal: LOG: headers:-->Accept-Language: nl-be
DAViCal: LOG: headers:-->Accept-Encoding: gzip, deflate
DAViCal: LOG: headers:-->Connection: keep-alive
DAViCal: LOG: headers:-->Prefer: return=minimal
DAViCal: LOG: :******************** Request ********************
DAViCal: LOG: request:--><?xml version="1.0" encoding="UTF-8"?>
DAViCal: LOG: request:--><A:propfind xmlns:A="DAV:">
DAViCal: LOG: request:-->  <A:prop>
DAViCal: LOG: request:-->    <A:current-user-principal/>
DAViCal: LOG: request:-->    <A:principal-URL/>
DAViCal: LOG: request:-->    <A:resourcetype/>
DAViCal: LOG: request:-->  </A:prop>
DAViCal: LOG: request:--></A:propfind>
DAViCal: LOG: request:-->
 AH02034: Subsequent (No.2) HTTPS request received for child 1 (server srv.<domain>:443)
 AH01626: authorization result of Require all granted: granted
 AH01626: authorization result of <RequireAny>: granted
 AH01626: authorization result of Require all granted: granted
 AH01626: authorization result of <RequireAny>: granted
DAViCal: LOG: :***************** Request Header ****************
DAViCal: LOG: :PROPFIND /club/abook/
DAViCal: LOG: headers:-->Host: cal.<domain>:8443
DAViCal: LOG: headers:-->User-Agent: iOS/9.3.4 (13G35) accountsd/1.0
DAViCal: LOG: headers:-->Accept-Language: nl-be
DAViCal: LOG: headers:-->Accept-Encoding: gzip, deflate
DAViCal: LOG: headers:-->Accept: */*
DAViCal: LOG: headers:-->Content-Type: text/xml
DAViCal: LOG: headers:-->Prefer: return=minimal
DAViCal: LOG: headers:-->Depth: 0
DAViCal: LOG: headers:-->Connection: keep-alive
DAViCal: LOG: headers:-->Authorization: Delicious tasty password eaten by debugging monster!
DAViCal: LOG: headers:-->Content-Length: 181
DAViCal: LOG: headers:-->Brief: t
DAViCal: LOG: :******************** Request ********************
DAViCal: LOG: request:--><?xml version="1.0" encoding="UTF-8"?>
DAViCal: LOG: request:--><A:propfind xmlns:A="DAV:">
DAViCal: LOG: request:-->  <A:prop>
DAViCal: LOG: request:-->    <A:current-user-principal/>
DAViCal: LOG: request:-->    <A:principal-URL/>
DAViCal: LOG: request:-->    <A:resourcetype/>
DAViCal: LOG: request:-->  </A:prop>
DAViCal: LOG: request:--></A:propfind>
DAViCal: LOG: request:-->
DAViCal: LOG: :Response status 207 for PROPFIND /club/abook/
DAViCal: LOG: :***************** Response Header ****************
DAViCal: LOG: headers:-->Server: 1.1
DAViCal: LOG: headers:-->DAV: 1, 2, 3, access-control, calendar-access, calendar-schedule
DAViCal: LOG: headers:-->DAV: extended-mkcol, bind, addressbook, calendar-proxy
DAViCal: LOG: headers:-->ETag: "f99e5df4487debfbd6245c6dcc4e71b7"
DAViCal: LOG: headers:-->X-DAViCal-Version: DAViCal/1.1.4; DB/1.2.12
DAViCal: LOG: headers:-->Content-type: text/xml; charset="utf-8"
DAViCal: LOG: :******************** Response ********************
DAViCal: LOG: response:--><?xml version="1.0" encoding="utf-8" ?>
DAViCal: LOG: response:--><multistatus xmlns="DAV:" xmlns:C="urn:ietf:params:xml:ns:carddav">
DAViCal: LOG: response:--> <response>
DAViCal: LOG: response:-->  <href>/club/abook/</href>
DAViCal: LOG: response:-->  <propstat>
DAViCal: LOG: response:-->   <prop>
DAViCal: LOG: response:-->    <current-user-principal>
DAViCal: LOG: response:-->     <href>/caldav.php/vvanhoutte/</href>
DAViCal: LOG: response:-->    </current-user-principal>
DAViCal: LOG: response:-->    <principal-URL>
DAViCal: LOG: response:-->     <href>/caldav.php/club/</href>
DAViCal: LOG: response:-->    </principal-URL>
DAViCal: LOG: response:-->    <resourcetype>
DAViCal: LOG: response:-->     <collection/>
DAViCal: LOG: response:-->     <C:addressbook/>
DAViCal: LOG: response:-->    </resourcetype>
DAViCal: LOG: response:-->   </prop>
DAViCal: LOG: response:-->   <status>HTTP/1.1 200 OK</status>
DAViCal: LOG: response:-->  </propstat>
DAViCal: LOG: response:--> </response>
DAViCal: LOG: response:--></multistatus>
DAViCal: LOG: response:-->
DAViCal: DBG: statistics:Method: PROPFIND, Status: 207, Script: 0.076s, Queries: 0.036s, URL: /club/abook/, Memory: 596k, Peak: 1536k
 AH01384: Zlib: Compressed 518 to 269 : URL /club/abook/
 AH02034: Subsequent (No.3) HTTPS request received for child 1 (server srv.<domain>:443)
 AH01626: authorization result of Require all granted: granted
 AH01626: authorization result of <RequireAny>: granted
 AH01626: authorization result of Require all granted: granted
 AH01626: authorization result of <RequireAny>: granted
DAViCal: LOG: :***************** Request Header ****************
DAViCal: LOG: :OPTIONS /caldav.php/vvanhoutte/
DAViCal: LOG: headers:-->Host: cal.<domain>:8443
DAViCal: LOG: headers:-->Accept-Encoding: gzip, deflate
DAViCal: LOG: headers:-->Accept: */*
DAViCal: LOG: headers:-->Content-Length: 0
DAViCal: LOG: headers:-->Connection: keep-alive
DAViCal: LOG: headers:-->Accept-Language: nl-be
DAViCal: LOG: headers:-->User-Agent: iOS/9.3.4 (13G35) accountsd/1.0
DAViCal: LOG: :******************** Request ********************



-> This confirms what I suspected: iOS tries to PROPFIND the /club/abook/ URL and sends a second request immediately for the 'current-user-principal', after which the URL for the current principal is used instead of the url set in 'Advanced URL'...

Has anyone seen this behaviour? Is there a solution?

Thx!
Vincent


Vincent Van Houtte schreef op di 04-10-2016 om 09:05 [+0200]:
Dear list,

I have been following the list for several years now, and have been aware of several issues with iDevices over the years, but I cannot seem to fix the issue that I'm having with a new install:

* Debian Jessie, fully up to date
* Apache 2.4.10 + mod_php
* DAViCal and awl from the backports repo
* subdomain installation, https only (Let's Encrypt certificate), port 8443
* LDAP authentication

Working:
* DAViCal web interface
* infCloud webclient (caldav+carddav)
* Evolution (caldav+carddav)
* Android Devices (caldav+carddav, both via 'caldav_sync' and 'davdroid' apps)
* iDevices (caldav only)

Not working:
* iDevices (carddav)

Symptom:
No matter which formatting I try in the iPhone's account settings (with and without https-prefix, with and without trailing slash, collection and principal level), the (advanced) Account-URL keeps being rewritten from the resource "/club/abook" to "/caldav.php/<username>"

The iPhone does not complain, but show the empty addressbook (related to the <username>).

The log does not show any errors, and even the debug -mode does not reveal anything relvant (other than the "caldav.php/<username>" being fetched.

Excerpt from the apache virtualhost (which I don't suspect to be faulty, but maybe I'm missing some mod_rewrite nuance...)

--
<VirtualHost *:80>
  Include               inc_server.conf
  ServerAlias           cal.<DOMAIN>

  # Redirect /.well-known URLs
  RewriteEngine on
  RewriteRule /.well-known(.*)$ /caldav.php/.well-known$1 [NC,L]

  # Redirect everything else to https (redirect gets executed after rewrite, independent of the order in which we put them here)
  Redirect permanent    / https://cal.<DOMAIN>:8443/
</VirtualHost>

<VirtualHost *:8443>
  Include               inc_server.conf
  Include               inc_ssl.conf
  DocumentRoot          /usr/share/davical/htdocs
  ServerAlias           cal.<DOMAIN>

  LogLevel              warn 
  ErrorLog              /var/log/apache2/cal-error.log

  DirectoryIndex        index.php /client/index.html
  FallbackResource      /index.php
  SetEnv                no-gzip=1

  Alias /images/        /usr/share/davical/htdocs/images/
  AcceptPathInfo        On

  php_value             include_path /usr/share/awl/inc
  php_value             magic_quotes_gpc 0
  php_value             register_globals 0
  php_value             error_reporting 1
  php_value             default_charset "utf-8"
  php_admin_flag        suhosin.server.strip off
  php_value             magic_quotes_runtime 0

  RewriteEngine On
  <IfModule mod_headers.c>
    Header unset Access-Control-Allow-Origin
    Header unset Access-Control-Allow-Methods
    Header unset Access-Control-Allow-Headers
    Header unset Access-Control-Allow-Credentials
    Header unset Access-Control-Expose-Headers

    # If your setup is working and complete you can replace the "*" with CardDavMATE instalation
    #  origin (protocol/host/port) - see the examples below (for multiple origins use multiple headers)
    Header always set Access-Control-Allow-Origin "https://cal.<DOMAIN>:8443"

#    Header always set Access-Control-Allow-Origin "*"
    Header always set Access-Control-Allow-Methods "GET,POST,OPTIONS,PROPFIND,PROPPATCH,REPORT,PUT,MOVE,DELETE,LOCK,UNLOCK"
    Header always set Access-Control-Allow-Headers "User-Agent,Authorization,Content-type,Depth,If-match,If-None-Match,Lock-Token,Timeout,Destination,Overwrite,Prefer,$
    Header always set Access-Control-Allow-Credentials false
    Header always set Access-Control-Expose-Headers "Etag,Preference-Applied"

    RewriteCond %{HTTP:Access-Control-Request-Method} !^$
    RewriteCond %{REQUEST_METHOD} OPTIONS
    RewriteRule ^(.*)$ $1 [R=200,L]
  </IfModule>

  <IfModule mod_rewrite.c>
#        RewriteEngine   On
        # Not if it's the root URL
        RewriteCond     %{REQUEST_URI} !^/$
        # Not if it is the directory for InfCloud
        RewriteCond     %{REQUEST_URI} !^/client/
        # Not if it is a .php program, script, stylesheet or image
        RewriteCond     %{REQUEST_URI} !\.(php|css|png|gif|js|jpg)
#       RewriteRule     /.well-known(.*)$ /caldav.php/.well-known$1 [NC,L]
        RewriteRule     ^(.*)$ /caldav.php$1  [NC,L]
        RewriteRule     ^/principals/users(.*)$ /caldav.php$1  [NC,L]
#       RewriteRule     .* - [E=AUTHORIZATION:%{HTTP:Authorization},L]
  </IfModule>

  <Directory /usr/share/davical/htdocs>
    SSLRequireSSL
    SSLOptions +StrictRequire
    Options FollowSymLinks
    Order Deny,Allow
    Allow from all
  </Directory>

 <Directory /usr/share/davical/htdocs/client/>
    AllowOverride FileInfo Limit
     <IfVersion >= 2.3>
         Require all granted
     </IfVersion>
     <IfVersion < 2.3>
         Order allow,deny
         Allow from all
     </IfVersion>
  </Directory>

# Add "Content-Type: text/cache-manifest" header for .manifest files
<IfModule mod_mime.c>
    AddType text/cache-manifest .manifest
</IfModule>

# Add "Cache-Control: max-age=0, must-revalidate, no-cache, no-transform, private" header for all files
#  for more information see: https://tools.ietf.org/html/rfc7234
<IfModule mod_headers.c>
    Header set Cache-Control "max-age=0, must-revalidate, no-cache, no-transform, private"
</IfModule>

<IfModule mod_deflate.c>
    SetOutputFilter DEFLATE
</IfModule>

# If you use mod_cache set the correct path for the cache.manifest here
#<IfModule mod_cache.c>
#    CacheDisable cache.manifest
#</IfModule>

</VirtualHost>
--

Thx for any hints pointing me in the right direction!

Vincent
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Davical-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/davical-general
-- 
Vincent Van Houtte
Advocaat
Brusselsestraat 108
9200 Dendermonde
T 052520605
F 052520646
W http://synergylaw.be

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Davical-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/davical-general
Reply | Threaded
Open this post in threaded view
|

Re: DAViCal carddav and iOS

Vincent Van Houtte-2
Additional information:
Using OSX 10.6.8 (and Address Book v.5.0.3), the client throws an error 403 when creating the address book, but when I ignore the error, it just fetches all the addresses:

DAViCal: LOG: :Response status 403 for PROPFIND /principals/club/abook/
DAViCal: LOG: :***************** Response Header ****************
DAViCal: LOG: headers:-->Server: 1.1
DAViCal: LOG: headers:-->DAV: 1, 2, 3, access-control, calendar-access, calendar-schedule
DAViCal: LOG: headers:-->DAV: extended-mkcol, bind, addressbook, calendar-proxy
DAViCal: LOG: headers:-->X-DAViCal-Version: DAViCal/1.1.4; DB/1.2.12
DAViCal: LOG: headers:-->Content-type: text/xml; charset="utf-8"
DAViCal: LOG: :******************** Response ********************
DAViCal: LOG: response:--><?xml version="1.0" encoding="utf-8" ?>
DAViCal: LOG: response:--><error xmlns="DAV:">
DAViCal: LOG: response:--> <need-privileges>
DAViCal: LOG: response:-->  <resource>
DAViCal: LOG: response:-->   <href>/principals/club/abook/</href>
DAViCal: LOG: response:-->   <privilege>
DAViCal: LOG: response:-->    <read/>
DAViCal: LOG: response:-->   </privilege>
DAViCal: LOG: response:-->  </resource>
DAViCal: LOG: response:--> </need-privileges>
DAViCal: LOG: response:--></error>
DAViCal: LOG: response:-->
DAViCal: LOG: :Response status 403 for PROPFIND /principals/club/abook/
DAViCal: LOG: :***************** Response Header ****************
DAViCal: LOG: headers:-->Server: 1.1
DAViCal: LOG: headers:-->DAV: 1, 2, 3, access-control, calendar-access, calendar-schedule
DAViCal: LOG: headers:-->DAV: extended-mkcol, bind, addressbook, calendar-proxy
DAViCal: LOG: headers:-->X-DAViCal-Version: DAViCal/1.1.4; DB/1.2.12
DAViCal: LOG: headers:-->Content-type: text/xml; charset="utf-8"
DAViCal: LOG: :******************** Response ********************
DAViCal: LOG: response:--><?xml version="1.0" encoding="utf-8" ?>
DAViCal: LOG: response:--><error xmlns="DAV:">
DAViCal: LOG: response:--> <need-privileges>
DAViCal: LOG: response:-->  <resource>
DAViCal: LOG: response:-->   <href>/principals/club/abook/</href>
DAViCal: LOG: response:-->   <privilege>
DAViCal: LOG: response:-->    <read/>
DAViCal: LOG: response:-->   </privilege>
DAViCal: LOG: response:-->  </resource>
DAViCal: LOG: response:--> </need-privileges>
DAViCal: LOG: response:--></error>
DAViCal: LOG: response:-->
DAViCal: LOG: :Response status 403 for PROPFIND /directory/
DAViCal: LOG: :***************** Response Header ****************
DAViCal: LOG: headers:-->Server: 1.1
DAViCal: LOG: headers:-->DAV: 1, 2, 3, access-control, calendar-access, calendar-schedule
DAViCal: LOG: headers:-->DAV: extended-mkcol, bind, addressbook, calendar-proxy
DAViCal: LOG: headers:-->X-DAViCal-Version: DAViCal/1.1.4; DB/1.2.12
DAViCal: LOG: headers:-->Content-type: text/xml; charset="utf-8"
DAViCal: LOG: :******************** Response ********************
DAViCal: LOG: response:--><?xml version="1.0" encoding="utf-8" ?>
DAViCal: LOG: response:--><error xmlns="DAV:">
DAViCal: LOG: response:--> <need-privileges>
DAViCal: LOG: response:-->  <resource>
DAViCal: LOG: response:-->   <href>/directory/</href>
DAViCal: LOG: response:-->   <privilege>
DAViCal: LOG: response:-->    <read/>
DAViCal: LOG: response:-->   </privilege>
DAViCal: LOG: response:-->  </resource>
DAViCal: LOG: response:--> </need-privileges>
DAViCal: LOG: response:--></error>
DAViCal: LOG: response:-->

Thx for any pointer in the right direction!

Kr,
Vincent

Vincent Van Houtte schreef op za 08-10-2016 om 20:03 [+0200]:
I have enabled debugging and this is the output when I use a borrowed iPhone to connect to /club/abook/:

DAViCal: LOG: :***************** Request Header ****************
DAViCal: LOG: :PROPFIND /club/abook/
DAViCal: LOG: headers:-->Host: cal.<domain>:8443
DAViCal: LOG: headers:-->User-Agent: iOS/9.3.4 (13G35) accountsd/1.0
DAViCal: LOG: headers:-->Depth: 0
DAViCal: LOG: headers:-->Content-Type: text/xml
DAViCal: LOG: headers:-->Content-Length: 181
DAViCal: LOG: headers:-->Brief: t
DAViCal: LOG: headers:-->Accept: */*
DAViCal: LOG: headers:-->Accept-Language: nl-be
DAViCal: LOG: headers:-->Accept-Encoding: gzip, deflate
DAViCal: LOG: headers:-->Connection: keep-alive
DAViCal: LOG: headers:-->Prefer: return=minimal
DAViCal: LOG: :******************** Request ********************
DAViCal: LOG: request:--><?xml version="1.0" encoding="UTF-8"?>
DAViCal: LOG: request:--><A:propfind xmlns:A="DAV:">
DAViCal: LOG: request:-->  <A:prop>
DAViCal: LOG: request:-->    <A:current-user-principal/>
DAViCal: LOG: request:-->    <A:principal-URL/>
DAViCal: LOG: request:-->    <A:resourcetype/>
DAViCal: LOG: request:-->  </A:prop>
DAViCal: LOG: request:--></A:propfind>
DAViCal: LOG: request:-->
 AH02034: Subsequent (No.2) HTTPS request received for child 1 (server srv.<domain>:443)
 AH01626: authorization result of Require all granted: granted
 AH01626: authorization result of <RequireAny>: granted
 AH01626: authorization result of Require all granted: granted
 AH01626: authorization result of <RequireAny>: granted
DAViCal: LOG: :***************** Request Header ****************
DAViCal: LOG: :PROPFIND /club/abook/
DAViCal: LOG: headers:-->Host: cal.<domain>:8443
DAViCal: LOG: headers:-->User-Agent: iOS/9.3.4 (13G35) accountsd/1.0
DAViCal: LOG: headers:-->Accept-Language: nl-be
DAViCal: LOG: headers:-->Accept-Encoding: gzip, deflate
DAViCal: LOG: headers:-->Accept: */*
DAViCal: LOG: headers:-->Content-Type: text/xml
DAViCal: LOG: headers:-->Prefer: return=minimal
DAViCal: LOG: headers:-->Depth: 0
DAViCal: LOG: headers:-->Connection: keep-alive
DAViCal: LOG: headers:-->Authorization: Delicious tasty password eaten by debugging monster!
DAViCal: LOG: headers:-->Content-Length: 181
DAViCal: LOG: headers:-->Brief: t
DAViCal: LOG: :******************** Request ********************
DAViCal: LOG: request:--><?xml version="1.0" encoding="UTF-8"?>
DAViCal: LOG: request:--><A:propfind xmlns:A="DAV:">
DAViCal: LOG: request:-->  <A:prop>
DAViCal: LOG: request:-->    <A:current-user-principal/>
DAViCal: LOG: request:-->    <A:principal-URL/>
DAViCal: LOG: request:-->    <A:resourcetype/>
DAViCal: LOG: request:-->  </A:prop>
DAViCal: LOG: request:--></A:propfind>
DAViCal: LOG: request:-->
DAViCal: LOG: :Response status 207 for PROPFIND /club/abook/
DAViCal: LOG: :***************** Response Header ****************
DAViCal: LOG: headers:-->Server: 1.1
DAViCal: LOG: headers:-->DAV: 1, 2, 3, access-control, calendar-access, calendar-schedule
DAViCal: LOG: headers:-->DAV: extended-mkcol, bind, addressbook, calendar-proxy
DAViCal: LOG: headers:-->ETag: "f99e5df4487debfbd6245c6dcc4e71b7"
DAViCal: LOG: headers:-->X-DAViCal-Version: DAViCal/1.1.4; DB/1.2.12
DAViCal: LOG: headers:-->Content-type: text/xml; charset="utf-8"
DAViCal: LOG: :******************** Response ********************
DAViCal: LOG: response:--><?xml version="1.0" encoding="utf-8" ?>
DAViCal: LOG: response:--><multistatus xmlns="DAV:" xmlns:C="urn:ietf:params:xml:ns:carddav">
DAViCal: LOG: response:--> <response>
DAViCal: LOG: response:-->  <href>/club/abook/</href>
DAViCal: LOG: response:-->  <propstat>
DAViCal: LOG: response:-->   <prop>
DAViCal: LOG: response:-->    <current-user-principal>
DAViCal: LOG: response:-->     <href>/caldav.php/vvanhoutte/</href>
DAViCal: LOG: response:-->    </current-user-principal>
DAViCal: LOG: response:-->    <principal-URL>
DAViCal: LOG: response:-->     <href>/caldav.php/club/</href>
DAViCal: LOG: response:-->    </principal-URL>
DAViCal: LOG: response:-->    <resourcetype>
DAViCal: LOG: response:-->     <collection/>
DAViCal: LOG: response:-->     <C:addressbook/>
DAViCal: LOG: response:-->    </resourcetype>
DAViCal: LOG: response:-->   </prop>
DAViCal: LOG: response:-->   <status>HTTP/1.1 200 OK</status>
DAViCal: LOG: response:-->  </propstat>
DAViCal: LOG: response:--> </response>
DAViCal: LOG: response:--></multistatus>
DAViCal: LOG: response:-->
DAViCal: DBG: statistics:Method: PROPFIND, Status: 207, Script: 0.076s, Queries: 0.036s, URL: /club/abook/, Memory: 596k, Peak: 1536k
 AH01384: Zlib: Compressed 518 to 269 : URL /club/abook/
 AH02034: Subsequent (No.3) HTTPS request received for child 1 (server srv.<domain>:443)
 AH01626: authorization result of Require all granted: granted
 AH01626: authorization result of <RequireAny>: granted
 AH01626: authorization result of Require all granted: granted
 AH01626: authorization result of <RequireAny>: granted
DAViCal: LOG: :***************** Request Header ****************
DAViCal: LOG: :OPTIONS /caldav.php/vvanhoutte/
DAViCal: LOG: headers:-->Host: cal.<domain>:8443
DAViCal: LOG: headers:-->Accept-Encoding: gzip, deflate
DAViCal: LOG: headers:-->Accept: */*
DAViCal: LOG: headers:-->Content-Length: 0
DAViCal: LOG: headers:-->Connection: keep-alive
DAViCal: LOG: headers:-->Accept-Language: nl-be
DAViCal: LOG: headers:-->User-Agent: iOS/9.3.4 (13G35) accountsd/1.0
DAViCal: LOG: :******************** Request ********************



-> This confirms what I suspected: iOS tries to PROPFIND the /club/abook/ URL and sends a second request immediately for the 'current-user-principal', after which the URL for the current principal is used instead of the url set in 'Advanced URL'...

Has anyone seen this behaviour? Is there a solution?

Thx!
Vincent
-- 
Vincent Van Houtte
Advocaat
Brusselsestraat 108
9200 Dendermonde
T 052520605
F 052520646
W http://synergylaw.be

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Davical-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/davical-general