nextcloud / nextcloud/contacts

IMPP property incorrectly formatted/read in vCard 4 breaking RFC

Open
#1,396 1 comment 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

1. to develop bug
Dominant language
JavaScript
Stars
642
Forks
220
Avg merge
14h 39m
Merged PRs (30d)
51

Description

ISSUE

Nextcloud creates/syncs/exports the following (vCard 4) for IMPP instant messaging fields:

E.g. Contact with a Skype IM address of https://skype.com/sfe

GROUP3.IMPP;TYPE=x-skype:https://skype.com/sfe
GROUP3.X-ABLABEL:Skype

CAUSE

Nextcloud is applying the vCard 3 (extension) standards, and not the correct vCard 4 standard.

vCard 3 that Nextcloud is using for vCard 4 also:
https://tools.ietf.org/html/rfc4770
RFC example: IMPP;TYPE=personal,pref:im:alice@example.com

vCard 4 that Nextcloud should be using for vCard 4 versions:
https://tools.ietf.org/html/rfc6350#page-37
IMPP;PREF=1:xmpp:alice@example.com

RESULT

This does not accord with the RFC spec, and thus is incorrectly translated by other systems (such as Android via DavX) and appears wrongly: in this case: Label: https Value: //skype.com/sfe

DavX/Android correctly create the following value of the same field:
IMPP:Skype:https://skype.com/sfe

RFC ( https://tools.ietf.org/html/rfc6350#page-36 )
Specifies the following example: IMPP;PREF=1:xmpp:alice@example.com

Note that

  1. PREF is optional
  2. TYPE is not provided for this property
  3. A URI can be provided, but note that most modern systems recognise common IMPP parameters (Facebook (messenger), Instagram, Twitter, Skype) with just the username.

RESOLUTION

Read and write the correct vCard 4 specs for IM fields as above.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No file or test is named, so first locate the IMPP read/write entry point in the contacts code and compare its behavior with RFC 6350 pages 36–37, linked in the issue. Done means vCard 4 IMPP fields are read and written using the RFC 6350 parameter format rather than the vCard 3 TYPE format.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.