This repository has been archived by the owner on Apr 26, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Backfill should gracefully handle the case where no one has the complete state for a given event #10764
Labels
A-Federation
A-Messages-Endpoint
/messages client API endpoint (`RoomMessageListRestServlet`) (which also triggers /backfill)
T-Enhancement
New features, changes in functionality, improvements in performance, or user-facing enhancements.
Comments
MadLittleMods
changed the title
Backfill should gracefully handle the case where no one has the complete state for a given event
Backfill should gracefully handle the case where no one has the complete state for a given event (Sep 4, 2021
fake_prev_event_id
)
This was referenced Sep 4, 2021
MadLittleMods
added
the
T-Enhancement
New features, changes in functionality, improvements in performance, or user-facing enhancements.
label
Sep 4, 2021
MadLittleMods
added a commit
that referenced
this issue
Sep 29, 2021
…rom /context See https://gitlab.com/gitterHQ/webapp/-/merge_requests/2229#note_683532091 Also seems to fix #10764
This was referenced Oct 14, 2021
Closed
I have the same issue:
Is there a workaround or should I wait for a fix? |
MadLittleMods
changed the title
Backfill should gracefully handle the case where no one has the complete state for a given event (
Backfill should gracefully handle the case where no one has the complete state for a given event
Feb 7, 2022
fake_prev_event_id
)
@TheNamelessWonderer There isn't a fix yet. We've side-stepped the issue for MSC2716 by no longer using a |
I observed the following log. Is it due to this issue right here, or should I create a new issue? Synapse version 1.57.1 from the official docker image.
|
Why is this closed by a commit on a synapse fork? |
good question. I'm assuming it wasn't deliberate, @babolivier ? |
MadLittleMods
added
the
A-Messages-Endpoint
/messages client API endpoint (`RoomMessageListRestServlet`) (which also triggers /backfill)
label
Aug 25, 2022
This was referenced Aug 25, 2022
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
A-Federation
A-Messages-Endpoint
/messages client API endpoint (`RoomMessageListRestServlet`) (which also triggers /backfill)
T-Enhancement
New features, changes in functionality, improvements in performance, or user-facing enhancements.
This issue is spawning from #10566 (comment) and summarizes the problem/conversation there. Thanks @erikjohnston and @richvdh for the insights on this!
We initially used a
fake_prev_event_id
for MSC2716 to make a chain of events float outside of the normal DAG but have since opted to use emptyprev_events=[]
. This issue still valid for the general case where no servers have the state for a given event though.The refactor in #10645 changed the way we handle fetching state for backfills. Before we'd just get the state at the last event, whereas now we try and get the state for each
prev_event
(including the fake event), which obviously fails. This means that federated homeservers no longer accept the insertion event because it can't fetch thefake_prev_event_id
state (Error attempting to resolve state at missing prev_events
,ERROR 403: We can't get valid state history.
).The goal of the code that's rejecting the fake event is protecting against an attack where a remote server could arbitrarily replace the servers view of the current state of the room. But the mitigation we use is a sledgehammer and we should replace it with something more intelligent that both mitigates the attack and gracefully handles missing events. (related to #8451)
Potential solutions
To be determined (TBD).
Reproduction case
prev_event_id
The text was updated successfully, but these errors were encountered: