Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Federation API for canonicalising MXIDs #3794

Open
matrixbot opened this issue Oct 27, 2014 · 9 comments
Open

Federation API for canonicalising MXIDs #3794

matrixbot opened this issue Oct 27, 2014 · 9 comments
Labels
feature Suggestion for a significant extension which needs considerable consideration kind:feature MSC for not-core and not-maintenance stuff needs-implementation This MSC does not have a qualifying implementation for the SCT to review. The MSC cannot enter FCP. p1 proposal A matrix spec change proposal

Comments

@matrixbot
Copy link
Member

matrixbot commented Oct 27, 2014

Documentation: https://docs.google.com/document/d/1B7q_3ruJzeQTg-uJHe1UScxbVLzgm451c25OjpYcojI/edit#
Author: @ara4n

I'm seeing more and more disasters with people failing to identify users correctly due to case sensitive IDs. For instance Amandine's business cards say @​amandine:matrix.org whereas she's registered as @​Amandine:matrix.org.

Splitting this out from matrix-org/synapse#1220

(Imported from https://matrix.org/jira/browse/SPEC-289)

(Reported by @ara4n)

@matrixbot
Copy link
Member Author

Jira watchers: @NegativeMjark @ara4n @richvdh

@matrixbot
Copy link
Member Author

matrixbot commented Oct 27, 2014

Links exported from Jira:

is blocked by SPEC-62
relates to SPEC-1
relates to https://github.com/matrix-org/matrix-doc/issues/494
relates to SPEC-390
relates to matrix-org/synapse#1220
vector-web issue

@matrixbot
Copy link
Member Author

If we want any level of flexibility for this lookup we need the HS to implement mapping from printed user-id to actual matrix ID.

Unless we restrict the space of IDs to fit into ASCII then rigorously defining a case insensitive match is slightly painful.

-- @NegativeMjark

@matrixbot
Copy link
Member Author

Blocked by specifying a lookup API.

-- @NegativeMjark

@matrixbot
Copy link
Member Author

matrixbot commented Apr 14, 2015

The current plan of action on this (as discussed IRL yesterday evening is):

  • Store IDs case-sensitively in the DB
  • Compare them case-sensitively in the code & protocol
  • Canonicalise them either at the origin client or origin HS by querying a lookup API on the destination HS (as per SPEC-62). This adds a roundtrip, but it may be suppressable by combining with some other roundtrip.

Open questions are:

  • Do you do the canonicalisation lookup from the origin client (yet another random thing to expect clients to remember to do, which they will never remember to)
  • Do you do the canonicalisation lookup from the origin HS?
  • Do you use a user alias->id (assuming user aliases were separated from underlying IDs) lookup to also perform the canonicalisation?

-- @ara4n

@matrixbot
Copy link
Member Author

this looks to have been mistakenly closed; the problem is still glaringly open.

-- @ara4n

@matrixbot
Copy link
Member Author

A solution to this (at least for invites) is proposed at https://docs.google.com/document/d/1B7q_3ruJzeQTg-uJHe1UScxbVLzgm451c25OjpYcojI.

-- @richvdh

@matrixbot matrixbot added the p1 label Oct 28, 2016
@matrixbot matrixbot changed the title User id comparisons should be case insensitive User id comparisons should be case insensitive (SPEC-289) Oct 31, 2016
@matrixbot matrixbot added the spec-bug Something which is in the spec, but is wrong label Nov 7, 2016
@cavebeat
Copy link

cavebeat commented Aug 9, 2017

i also have this problem

user registered @foo and i want to rename to lower-case
deactivation of @foo and new registering @foo is not possible, as @foo is already taken.
it is suggested-and-not-suggested to do surgery on the DB... there is no other way for this.

if user registration is case insensitive, create from now on just lower case users... !

@richvdh richvdh added feature Suggestion for a significant extension which needs considerable consideration and removed spec-bug Something which is in the spec, but is wrong labels Nov 8, 2017
@benparsons benparsons changed the title User id comparisons should be case insensitive (SPEC-289) Federation API for canonicalising MXIDs May 10, 2018
@ara4n ara4n added the proposal A matrix spec change proposal label May 15, 2018
@turt2live turt2live added the kind:feature MSC for not-core and not-maintenance stuff label Apr 21, 2020
@turt2live turt2live added the needs-implementation This MSC does not have a qualifying implementation for the SCT to review. The MSC cannot enter FCP. label Jun 8, 2021
@richvdh richvdh transferred this issue from matrix-org/matrix-spec-proposals Mar 1, 2022
@ara4n ara4n transferred this issue from matrix-org/matrix-spec May 9, 2022
@richvdh
Copy link
Member

richvdh commented May 16, 2022

previously, this was MSC586.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Suggestion for a significant extension which needs considerable consideration kind:feature MSC for not-core and not-maintenance stuff needs-implementation This MSC does not have a qualifying implementation for the SCT to review. The MSC cannot enter FCP. p1 proposal A matrix spec change proposal
Projects
None yet
Development

No branches or pull requests

7 participants