nextcloud / nextcloud/server

Distributed email based federated cloud id discovery

Open
#365 22 comments 12 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

1. to develop enhancement feature: federation hotspot: account name handling
Dominant language
PHP
Stars
36.9k
Forks
5.2k
Avg merge
2d 3h
Merged PRs (30d)
713

Description

Please use the 👍 reaction to show that you are also in favor of this feature - we are using this information to decide which features to include in upcoming Nextcloud versions. Please don't comment if you have no relevant information to add!


Federated cloud ids are often far from ideal (foo@bar@example.com, foo@example.com/cloud foo@cloud.example.com instead of just foo@example.com) because it needs to contain all information needed to contact the remote server.

It would be a lot nicer for users if they can just enter an email in the share field and have automatically resolve that to a remote (or local) user.

One option to resolve emails would be to have one (or more) centralized servers which contain a mapping but centralized components is something which should be avoided where possible.

For instances where people use their own domain for emails (which would cover most larger instances) we could use the control the admin has over the mail domain to setup a distributed resolver.
Some ways this could be done would be

  • have a TXT dns entry which points to the resolver endpoint
  • have something like example.com/.well-known/cloud-resolver point to the resolver endpoint

Where the resolver would be a simple api that matches federated cloud ids to emails for all users in the instance.

(note that we can't have the resolver itself in .well-known since it needs to be possible to have the resolver on a different server than the one that server the main site.)

The full process when sharing would be something like

  1. Check if the provided email belongs to a local user
  2. See if the domain provides a resolver
  3. Check if the email belongs to a cloud id
  4. setup the share with the discovered cloud id

Nothing of it should be hard to implement we just need to make sure we decide on some standard way an admin can setup a resolver.

Personally I would prefer the dns route but either of the discovery methods should work (or we could just support both)

cc @LukasReschke @karlitschek @schiessle @rullzer @jancborchardt

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

The issue names no files, tests, or entry points. Start by reviewing the existing federated sharing and user lookup flows, then establish the resolver discovery standard, API behavior, and security requirements; done means an email can be resolved to a local or remote cloud ID during sharing.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
cloud, distributed-systems, networking
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.