1
0
Commit Graph

423 Commits

Author SHA1 Message Date
Andrew Morgan
eaabbf3f7c Fix bug which caused rejected events to be stored with the wrong room state (#6320)
* commit '807ec3bd9':
  Fix bug which caused rejected events to be stored with the wrong room state  (#6320)
2020-03-16 19:26:00 +00:00
Andrew Morgan
55be059f91 Merge pull request #5727 from matrix-org/uhoreg/e2e_cross-signing2-part3
* commit '53d7680e3':
  Update synapse/storage/data_stores/main/devices.py
  rename get_devices_by_remote to get_device_updates_by_remote
  black
  apply changes as a result of PR review
  don't error if federation query doesn't have cross-signing keys
  move get_e2e_cross_signing_key to EndToEndKeyWorkerStore so it works with workers
  black
  vendor-prefix the EDU name until MSC1756 is merged into the spec
  fix unit test
  add news file
  update to work with newer code, and fix formatting
  add missing param
  make black happy
  don't crash if the user doesn't have cross-signing keys
  implement federation parts of cross-signing
2020-03-16 19:23:32 +00:00
Andrew Morgan
c14c890bf3 Merge pull request #6279 from matrix-org/erikj/federation_server_async_await
* commit 'b4465564c':
  Don't return coroutines
  Make concurrently_execute work with async/await
  Newsfile
  Port federation_server to async/await
2020-03-16 15:34:59 +00:00
Andrew Morgan
1b5ea48ed2 Merge pull request #6255 from matrix-org/erikj/stats_config
* commit '87259b3a3':
  Fix tests
  Newsfile
  Remove repeated calls to config.stats_enabled.
2020-03-16 15:31:12 +00:00
Andrew Morgan
bf1fad8462 Merge pull request #6231 from matrix-org/erikj/refactor_stores 2020-03-16 15:13:49 +00:00
Andrew Morgan
8165d3c81d Merge pull request #5726 from matrix-org/uhoreg/e2e_cross-signing2-part2
* commit '276173163':
  Add changelog entry
  fix doc strings
  make isort happy
  add some comments
  drop some logger lines to debug
  make changes based on PR feedback
  add function docs
  use something that's the right type for user_id
  run black
  split out signature processing into separate functions
  avoid modifying input parameter
  fix test
  update with newer coding style
  add test
  make isort happy
  make black happy
  allow uploading signatures of master key signed by devices
  implement device signature uploading/fetching
2020-03-16 14:59:03 +00:00
Andrew Morgan
95b332e90a Remove Auth.check method (#6217)
* commit '93eaeec75':
  Remove Auth.check method (#6217)
  add note about database upgrade
  use the right function for when we're already in runInteraction
  add user signature stream change cache to slaved device store
  black
  use stream ID generator instead of timestamp
  make isort happy
  apply PR review suggestions
  fix formatting
  add changelog
  make changes from PR review
  don't need to return the hidden column any more
  really fix queries to work with Postgres
  PostgreSQL, Y U no like?
  remove extra SQL query param
  add changelog file
  apply changes from PR review
  allow uploading keys for cross-signing
  allow devices to be marked as "hidden"
2020-03-16 14:55:37 +00:00
Andrew Morgan
3261565623 Fix presence timeouts when synchrotron restarts. (#6212) 2020-02-26 12:40:51 +00:00
Andrew Morgan
4b2d706900 Merge pull request #6189 from matrix-org/uhoreg/e2e_backup_optional_version 2020-02-26 12:37:13 +00:00
Andrew Morgan
aa4590795a Fix races in room stats (and other) updates. (#6187) 2020-02-26 12:33:19 +00:00
Andrew Morgan
f8baba9c54 Merge pull request #6147 from matrix-org/babolivier/3pid-invite-revoked 2020-02-26 12:26:11 +00:00
Andrew Morgan
4ab5cf88a2 Land improved room list based on room stats (#6019) 2020-02-26 12:12:33 +00:00
Andrew Morgan
e034f14fca Use the federation blacklist for requests to untrusted Identity Servers (#6000) 2020-02-25 17:46:09 +00:00
Andrew Morgan
b4c2acd7af Implement MSC2290 (#6043) 2020-02-25 15:42:28 +00:00
Andrew Morgan
74912d4eab Add 'failure_ts' column to 'destinations' table (#6016) 2020-02-25 14:28:24 +00:00
Andrew Morgan
136caf4221 Fix existing v2 identity server calls (MSC2140) (#6013) 2020-02-25 13:45:26 +00:00
Andrew Morgan
e75de4107d Merge pull request #6004 from matrix-org/jaywink/autojoin-create-real-users 2020-02-25 11:53:22 +00:00
Andrew Morgan
3c34ddab01 Remove extraneous unittest.DEBUG's 2020-02-25 11:36:04 +00:00
Andrew Morgan
476932cdef Increase expected state events in tests for new room by one 2020-02-25 11:14:11 +00:00
Andrew Morgan
91e030ae12 Fix and refactor room and user stats (#5971) 2020-02-25 10:16:48 +00:00
Andrew Morgan
6c058e3206 Remove unnecessary parentheses around return statements (#5931) 2020-02-24 17:54:53 +00:00
Andrew Morgan
b7424f4943 Remove non-functional 'expire_access_token' setting (#5782) 2020-02-20 15:41:21 +00:00
Andrew Morgan
f590f77a16 Replace returnValue with return (#5736) 2020-02-19 15:11:59 +00:00
Andrew Morgan
29adbe8546 Merge pull request #5589 from matrix-org/erikj/admin_exfiltrate_data 2020-02-17 17:17:59 +00:00
Andrew Morgan
2f450fa149 Implement access token expiry (#5660) 2020-02-17 17:17:02 +00:00
Andrew Morgan
84a1465332 Merge pull request #5658 from matrix-org/babolivier/is-json 2020-02-17 16:50:01 +00:00
Andrew Morgan
ee2de6734b Remove access-token support from RegistrationStore.register (#5642) 2020-02-17 16:36:11 +00:00
Andrew Morgan
5e752310be Remove access-token support from RegistrationHandler.register (#5641) 2020-02-17 13:41:58 +00:00
Andrew Morgan
0f0c74493a Move get_or_create_user to test code (#5628) 2020-02-17 13:31:16 +00:00
Andrew Morgan
622d0be1b3 Fix with isort==4.3.21 and black==19.3b0 2020-02-14 14:27:12 +00:00
Andrew Morgan
0295abdcf7 Dinsic Blacking with black==18.6b2 2020-02-11 16:18:29 +00:00
Andrew Morgan
b69732705d Capatilise letters after a - in new user displaynames (#14) 2019-12-02 15:10:23 +00:00
Richard van der Hoff
807ec3bd99 Fix bug which caused rejected events to be stored with the wrong room state (#6320)
Fixes a bug where rejected events were persisted with the wrong state group.

Also fixes an occasional internal-server-error when receiving events over
federation which are rejected and (possibly because they are
backwards-extremities) have no prev_group.

Fixes #6289.
2019-11-06 10:01:39 +00:00
Hubert Chathi
bb6cec27a5 rename get_devices_by_remote to get_device_updates_by_remote 2019-10-30 14:57:34 -04:00
Erik Johnston
3f33879be4 Port federation_server to async/await 2019-10-29 14:13:08 +00:00
Erik Johnston
7e7a1461f6 Fix tests 2019-10-25 10:57:37 +01:00
Erik Johnston
c17efdc01c Merge branch 'develop' of github.com:matrix-org/synapse into erikj/refactor_stores 2019-10-22 18:44:29 +01:00
Erik Johnston
bb6264be0b Merge branch 'develop' of github.com:matrix-org/synapse into erikj/refactor_stores 2019-10-22 10:41:18 +01:00
Erik Johnston
c66a06ac6b Move storage classes into a main "data store".
This is in preparation for having multiple data stores that offer
different functionality, e.g. splitting out state or event storage.
2019-10-21 16:05:06 +01:00
Hubert Chathi
36adfaedab Merge branch 'develop' into cross-signing_sig_upload 2019-10-18 18:34:42 +01:00
Hubert Chathi
cfc28325a6 Merge branch 'develop' into uhoreg/e2e_cross-signing_merged 2019-10-18 11:39:40 +01:00
Erik Johnston
5859a5c569 Fix presence timeouts when synchrotron restarts. (#6212)
* Fix presence timeouts when synchrotron restarts.

Handling timeouts would fail if there was an external process that had
timed out, e.g. a synchrotron restarting. This was due to a couple of
variable name typoes.

Fixes #3715.
2019-10-18 06:42:26 +01:00
Hubert Chathi
691dd67fcd Merge pull request #6189 from matrix-org/uhoreg/e2e_backup_optional_version
make version optional in body of e2e backup version update
2019-10-11 10:11:59 -04:00
Hubert Chathi
5373de6cce change test name to be unique 2019-10-10 08:54:07 -04:00
Richard van der Hoff
a139420a3c Fix races in room stats (and other) updates. (#6187)
Hopefully this will fix the occasional failures we were seeing in the room directory.

The problem was that events are not necessarily persisted (and `current_state_delta_stream` updated) in the same order as their stream_id. So for instance current_state_delta 9 might be persisted *before* current_state_delta 8. Then, when the room stats saw stream_id 9, it assumed it had done everything up to 9, and never came back to do stream_id 8.

We can solve this easily by only processing up to the stream_id where we know all events have been persisted.
2019-10-10 11:29:01 +01:00
Hubert Chathi
4535a07f4a make version optional in body of e2e backup version update
to agree with latest version of the MSC
2019-10-09 17:54:03 -04:00
Brendan Abolivier
c49ba3677c Fixup tests 2019-10-04 12:21:33 +01:00
Brendan Abolivier
d694546453 Lint (again) 2019-10-04 12:10:19 +01:00
Brendan Abolivier
06159a0ee7 Lint 2019-10-04 12:10:19 +01:00
Brendan Abolivier
a6a55039a4 Add test case 2019-10-04 12:10:19 +01:00