Invite Links

Example:
https://chatsecure.org/invitation/user@domain/fingerprint
https://chatsec.org/i/#(base64 encoded: user@domain?fingerprint)

Goals

  • The app can share an invitation link that needs to both work for new (people without the app) and existing (people with the app) users.
  • We want the app to be able to easily share/post invite URLs through various social and messaging mediums to be able to easily have new friends and communities bootstrap into the app.

Technical Requirements

  • The link must be short enough to fit in various short message system limitations < 140 etc
  • On WeChat, links of only a certain length are handled to make them tap/clickable... it only links up to some 100 characters or so.
  • Some apps don't like share links with too many query parameters or other formatting

The Plan

  • Link must contain the full username (host@domain) of the sender
  • Link must contain the OTR fingerprint of the sender
  • Link must be base64 encoded and compressed to ensure it is as short as possible and doesn't included unsupported formatting
  • If app is installed, it must intercept link before it opens web browser, and extract relevant data from it for invite
  • If app is NOT installed, link must resolve to a web page that prompts the user to install the app, and then reminds them to tap on the link again once they have

Special format for QR Codes for in-app scanning

  • QR Codes with bigger blocks (i.e. less data) seem easier to scan
  • QR Codes encode smaller when all UPPER case text (base42: 0–9, A–Z (upper-case only), space, $, %, *, +, -, ., /, :)[1]
  • many QR scanner apps do not handle upper case URL schemes (e.g. HTTP://ZOM.IM))
  • this format could be used for in-app scanning only
  • here is an example of a smaller QR code from using the base42 char set: https://github.com/open-keychain/open-keychain/issues/1281#issuecomment-103611915

Also available in: PDF HTML TXT