Ticket #359 (new defect)

Opened 2 years ago

Last modified 9 months ago

Don't tolerated malformed vcards (was: Malformed(?) VCARD causes hang)

Reported by: flash666@yahoo.com Assigned to: dgollub
Priority: normal Milestone:
Component: Plugin: vformat Version: 0.20
Severity: normal Keywords: version vcard hang hung
Cc:

Description

In the SetupGuide part of the test process involved the manual creation of a VCARD without a VERSION tag. I have changed it now, because doing so and attempting a kdepim-file sync results in msynctool hanging. I had a couple of test contacts in KDE, and an empty directory. I successfully synched the two. Then I added a vcard to the directory that looked like this:

BEGIN:VCARD
N:test user
END:VCARD

msynctool then hung on the next run while attempting to send this to the kde member. After changing the VCARD to look like this:

BEGIN:VCARD
VERSION:2.1
N:test user
END:VCARD

the synch was fine. Log files all at http://www.bus-times.org.uk/dump

According to the VCARD 2.1 spec (http://www.imc.org/pdi/vcard-21.txt):

Version
This property specifies the identifier corresponding to the highest version number of the vCard Specification supported by the implementation that created the vCard object. The value of this property must be 2.1 to correspond to this specification.. 
This property is identified by the property name VERSION. The following is an example of this property:
VERSION:2.1
Support for this property is mandatory for implementations conforming to this specification. This property must appear within the vCard data stream.

So I suppose cards of this type should be considered malformed, logged and ignored.

Change History

11/08/06 01:16:16 changed by cstender

  • milestone set to 0.21.

02/08/07 16:25:15 changed by pmarat

  • status changed from new to closed.
  • resolution set to fixed.

this should be fixed with r1696

02/10/07 12:06:49 changed by pmarat

  • status changed from closed to reopened.
  • resolution deleted.

r1709 reopens this ticket

02/11/07 16:38:22 changed by dgollub

  • owner changed from ehabkost to dgollub.
  • status changed from reopened to new.
  • version changed from 0.19 to 0.20.
  • component changed from Plugin: kdepim to OpenSync.

I will try to workaround this for 0.21 .. maybe osync_filter can help.

02/20/07 13:50:06 changed by cstender

  • milestone deleted.

10/15/07 22:43:32 changed by dgollub

  • component changed from OpenSync to Plugin: vformat.
  • summary changed from Malformed(?) VCARD causes hang to Don't tolerated malformed vcards (was: Malformed(?) VCARD causes hang).

In OpenSync? 0.33 it doesn't cause anymore a hang. The vformat tolerates malformed entries and adds required VEERSION information... the vcard* -> xmlforamt-contact should do a sanity check if the vcard is malformed (missing version header) and throw an error ... instead of tolerating.

dani@K51:~/Sync/file> cat 1/contact/malformat.vcf 
BEGIN:VCARD
N:test user
END:VCARD
dani@K51:~/Sync/file> cat 2/contact/malformat.vcf 
BEGIN:VCARD
VERSION:2.1
N:test user
dani@K51:~/Sync/file> 


This entry got synced with OpenSync? 0.33 from member 1 to member 2. Note: tail is missing of synced entry (directory 2).