PRODID line folding causing problems with Mac Contacts



    1. Steps to reproduce:
      1.1. Create a contact in owncloud
      1.2. Open Mac OS's Contacts App, add something
      1.3. download vcard from owncloud
    BEGIN:VCARD
    VERSION:3.0
    PRODID:-//Apple Inc.//Mac OS X 10.9.5//EN
    N:Doe;John;;;
    FN:John Doe
    EMAIL;TYPE=INTERNET;TYPE=WORK;TYPE=pref:john.doe@example.com
    EMAIL;TYPE=INTERNET;TYPE=HOME:from-mac@example.com
    TEL;TYPE=HOME;TYPE=VOICE;TYPE=pref:+1555123456789
    REV:2016-08-14T13:15:38+00:00
    UID:0ea1c5a9-2c93-443d-8672-0e871710203b@owncloud-service-host
    END:VCARD
    

    1.4. open contacts on phone, add an email address (or change a name, or edit a number, ...)
    1.5. download updated vcard from owncloud

    BEGIN:VCARD
    VERSION:3.0
    PRODID:+//IDN bitfire.at//DAVdroid/1.2.3-gplay vcard4android ez-vcard/0.9.1
     0
    UID:0ea1c5a9-2c93-443d-8672-0e871710203b@owncloud-service-host
    FN:John Doe
    N:Doe;John;;;
    TEL;TYPE=home;TYPE=pref:+1555123456789
    EMAIL;TYPE=work;TYPE=pref:john.doe@example.com
    EMAIL;TYPE=home:from-mac@example.com
    EMAIL:from-davdroid@example.com
    REV:2016-08-14T13:18:42+00:00
    END:VCARD
    

    1.6. open downloaded vcards in text editor of choice, find a sequence of "\CR\LF 0\CR\LF" scrambling all the vcard

    1. Environment, setup worked smooth for some time now, did not change it, except for automatic app updates for davdroid:
      2.1. Two Mobile Devices (Sony Experia Z5 Compact, LG G4) both running the latest release of DAVdroid
      2.2. Owncloud Server (7.x)
      2.3. Mac OS 10.9.5 with Contacts 8.0 (1371.2)

    Editing from the Mac still works flawlessly. VCards i edited on the mobile devices running davdroid show up in the mac "Console"'s "All Messages" log as being ignored with a message like this:

    [CardDAVPlugin-ERROR] CardInfoFromVCardData(): Ignored vCard at /remote.php/carddav/addressbooks/principalname/contacts/0ea1c5a9-2c93-443d-8672-0e871710203b%2540owncloud-service-host.vcf because there is no UID property: "BEGIN:VCARD
    VERSION:3.0
    PRODID:+//IDN bitfire.at//DAVdroid/1.2.3-gplay vcard4android ez-vcard/0.9.1
    0
    UID:0ea1c5a9-2c93-443d-8672-0e871710203b@owncloud-service-host
    FN:John Doe
    N:Doe;John;;;
    TEL;TYPE=home;TYPE=pref:+1555123456789
    EMAIL;TYPE=work;TYPE=pref:john.doe@example.com
    EMAIL;TYPE=home:from-mac@example.com
    EMAIL:from-davdroid@example.com
    REV:2016-08-14T13:18:42+00:00
    END:VCARD
    "
    
    1. Debug info (removed hostnames and account names, direct message me, if you want a debugging account on my server):
    SOFTWARE INFORMATION
    DAVdroid version: 1.2.3-gplay (112) Sat Aug 06 00:15:12 GMT+02:00 2016
    Installed from: com.android.vending
    JB Workaround installed: no
    
    CONFIGURATION
    System-wide synchronization: automatically
    Account: principalname
    Address book sync. interval: 1440 min
    Calendar sync. interval: 1440 min
    OpenTasks sync. interval: —
    WiFi only: false
    [CardDAV] Contact group method: CATEGORIES
    RFC 6868 encoding: true
    [CalDAV] Time range (past days): 90
    Manage calendar colors: true
    
    SQLITE DUMP
    android_metadata
    | locale |
    | en_US |
    ----------
    settings
    | setting | value |
    ----------
    services
    | _id | accountName | service | principal |
    | 1 | principalname | carddav | <null> |
    | 2 | principalname | caldav | <null> |
    ----------
    sqlite_sequence
    | name | seq |
    | services | 2 |
    | collections | 6 |
    | homesets | 4 |
    ----------
    homesets
    | _id | serviceID | url |
    | 3 | 1 | https://owncloud-service-host/remote.php/carddav/addressbooks/principalname/ |
    | 4 | 2 | https://owncloud-service-host/remote.php/caldav/calendars/principalname/ |
    ----------
    collections
    | _id | serviceID | url | readOnly | displayName | description | color | timezone | supportsVEVENT | supportsVTODO | sync |
    | 3 | 1 | https://owncloud-service-host/remote.php/carddav/addressbooks/principalname/contacts/ | 0 | Contacts | Default Address Book | <null> | <null> | <null> | <null> | 1 |
    | 4 | 2 | https://owncloud-service-host/remote.php/caldav/calendars/principalname/contact_birthdays/ | 1 | Contact birthdays | <null> | -3355444 | <null> | 1 | 0 | 1 |
    | 5 | 2 | https://owncloud-service-host/remote.php/caldav/calendars/principalname/calendarone/ | 0 | calendarone | <null> | -65536 | <null> | 1 | 1 | 0 |
    | 6 | 2 | https://owncloud-service-host/remote.php/caldav/calendars/principalname/calendartwo/ | 0 | calendartwo | <null> | -6306073 | <null> | 1 | 1 | 0 |
    ----------
    
    SYSTEM INFORMATION
    Android version: 6.0.1 (32.2.A.0.253)
    Device: Sony E5823 (E5823)
    

  • developer

    Hello,

    Thanks for your report.

    1.6. open downloaded vcards in text editor of choice, find a sequence of "\CR\LF 0\CR\LF" scrambling all the vcard

    That's a normal PRODID property, but it's a long line and has thus been folded by ez-vcard:

    PRODID:+//IDN bitfire.at//DAVdroid/1.2.3-gplay vcard4android ez-vcard/0.9.1
     0
    

    means that PRODID has the value +//IDN bitfire.at//DAVdroid/1.2.3-gplay vcard4android ez-vcard/0.9.10 (not 0.9.1).

    VCards i edited on the mobile devices running davdroid show up in the mac "Console"'s "All Messages" log as being ignored with a message like this:

    Seems really to be a Mac OS Contacts problem, because apparently it doesn't unfold lines as required. Do you use the newest version of the software?


  • developer

    We have just verified that the OS X 10.11.6 Contacts app (in combination with OS X Server 5.1.5) is not able to parse correctly folded PRODID lines.

    We have reported this OS X Server bug to Apple (bugs #28172308 and #28173106).


Log in to reply
 

Looks like your connection to Bitfire App Forums was lost, please wait while we try to reconnect.