Make federation state request 404 when event not in the room - fixes
MODIFY
federationapi/routing/state.go
federationapi/routing/state.go
@@ -103,6 +103,10 @@ func getState(
return nil, resErr
}
+ if event.RoomID() != roomID {
+ return nil, &util.JSONResponse{Code: http.StatusNotFound, JSON: nil}
+ }
+
prevEventIDs := getIDsFromEventRef(event.PrevEvents())
authEventIDs := getIDsFromEventRef(event.AuthEvents())

Make federation state request 404 when event not in the room - fixes #625 (#716)

Signed-off-by: Alex Chen <minecnly@gmail.com>