Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Allow users to redact their own events #262

Merged
merged 3 commits into from Sep 2, 2015
Merged

Conversation

illicitonion
Copy link
Contributor

if user_level > redact_level:
return False

if EventID.from_string(event.redacts).domain == self.hs.get_config().server_name:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this not:

EventID.from_string(event.redacts).domain == EventID.from_string(event.event_id).domain

Auth checks should not depend on the current server, as they need to come to the same answer on all servers in the room.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Federated servers still need to delegate authority to owning servers
@erikjohnston
Copy link
Member

LGTM

illicitonion added a commit that referenced this pull request Sep 2, 2015
Allow users to redact their own events
@illicitonion illicitonion merged commit 77580ad into develop Sep 2, 2015
@erikjohnston erikjohnston deleted the redactyoself branch November 19, 2015 17:15
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants