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

Sydent doesn't delete 3PIDs from DB on unbind #192

Open
babolivier opened this issue Aug 15, 2019 · 2 comments · Fixed by #213

Comments

@babolivier
Copy link
Member

commented Aug 15, 2019

According to https://github.com/matrix-org/sydent/blob/master/sydent/db/threepid_associations.py#L84-L87, when receiving an /unbind request, Sydent only sets the MXID and a couple of timestamps to NULL, but doesn't actually remove the 3PID from its database, and I can't seem to find any place where we delete anything from the local_threepid_associations table. I don't believe this is something we want.

@anoadragon453 anoadragon453 self-assigned this Sep 11, 2019
@richvdh richvdh closed this in #213 Sep 23, 2019
richvdh added a commit that referenced this issue Sep 23, 2019
…213)

Fixes #192

On unbinding a threepid, Sydent would only set the Matrix ID (and some metadata) to NULL in the database, but keep the threepid address (email or phone number) around.

This PR changes it so that rows are deletes instead of partially redacted, as well as adds a migration step to delete any rows with NULL Matrix ID fields from the local_threepid_associations table.

Global associations were already deleted fully, so there is no reason to modify that database.
@richvdh

This comment has been minimized.

Copy link
Member

commented Sep 25, 2019

Unfortunately we had to revert #213 due to #218

@richvdh richvdh reopened this Sep 25, 2019
@richvdh

This comment has been minimized.

Copy link
Member

commented Sep 25, 2019

so, I think we need to rethink how the database replication works, to allow for deletion in a way that doesn't involve keeping a copy of the deleted data forever. Presumably a queue of things awaiting pushing, for each peer?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.