summary refs log tree commit diff
path: root/synapse (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'develop' into rav/cleanup_metricsRichard van der Hoff2019-06-24291-9106/+8018
|\
| * Improve help and cmdline option names for --generate-config options (#5512)Richard van der Hoff2019-06-211-22/+28
| | | | | | | | | | | | | | * group the arguments together into a group * add new names "--generate-missing-config" and "--config-directory" for existing cmdline options "--generate-keys" and "--keys-dir", which better reflect their purposes.
| * Refactor Config parser and add some comments. (#5511)Richard van der Hoff2019-06-211-14/+35
| | | | | | | | Add some comments, and simplify `read_config_files`.
| * Improve logging when generating config files (#5510)Richard van der Hoff2019-06-213-1/+7
| | | | | | Make it a bit clearer what's going on.
| * Only import jinja2 when needed (#5514)Andrew Morgan2019-06-211-1/+2
| | | | | | | | | | | | | | Fixes https://github.com/matrix-org/synapse/issues/5431 `jinja2` was being imported even when it wasn't strictly necessary. This made it required to run Synapse, even if the functionality that required it wasn't enabled. This was causing new Synapse installations to crash on startup. Email modules are now required.
| * Fix "Unexpected entry in 'full_schemas'" log warning (#5509)Richard van der Hoff2019-06-211-1/+1
| | | | | | | | | | There is a README.txt which always sets off this warning, which is a bit alarming when you first start synapse. I don't think we need to warn about this.
| * Fix logging error when a tampered event is detected. (#5500)Richard van der Hoff2019-06-211-1/+0
| |
| * Fix /messages on worker when no token suppliedErik Johnston2019-06-211-0/+2
| |
| * Support pagination API in client_reader workerErik Johnston2019-06-211-0/+2
| |
| * Merge pull request #5476 from matrix-org/erikj/histogram_extremitiesErik Johnston2019-06-212-1/+36
| |\ | | | | | | Add metrics for length of new extremities persisted.
| | * BlackErik Johnston2019-06-201-2/+2
| | |
| | * Merge branch 'develop' of github.com:matrix-org/synapse into ↵Erik Johnston2019-06-20292-9079/+7986
| | |\ | | | | | | | | | | | | erikj/histogram_extremities
| | * | Add descriptions and remove redundant set(..)Erik Johnston2019-06-192-4/+7
| | | |
| | * | Only count non-cache state resolutionErik Johnston2019-06-181-3/+3
| | | |
| | * | Use consistent bucketsErik Johnston2019-06-181-1/+1
| | | |
| | * | Add metric fo number of state groups in resolutionErik Johnston2019-06-171-0/+10
| | | |
| | * | Add metrics for len of new extremities persisted.Erik Johnston2019-06-171-1/+23
| | | | | | | | | | | | | | | | | | | | Of new events being persisted add metrics for total size of forward extremities and number of unchanged, "stale" extremities.
| * | | Improve email notification logging (#5502)Neil Johnson2019-06-201-1/+1
| | |/ | |/|
| * | Run Black. (#5482)Amber Brown2019-06-20291-9076/+7753
| | |
| * | Merge pull request #5042 from matrix-org/erikj/fix_get_missing_events_errorErik Johnston2019-06-191-9/+19
| |\ \ | | | | | | | | Handle the case of `get_missing_events` failing
| | * | Fix loglineErik Johnston2019-06-181-1/+1
| | | |
| | * | Merge branch 'develop' of github.com:matrix-org/synapse into ↵Erik Johnston2019-06-18171-2326/+11195
| | |\ \ | | | | | | | | | | | | | | | erikj/fix_get_missing_events_error
| | * | | Handle the case of `get_missing_events` failingErik Johnston2019-04-101-9/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently if a call to `/get_missing_events` fails we log an exception and stop processing the top level event we received over federation. Instead let's try and handle it sensibly given it is a somewhat expected failure mode.
| * | | | Merge pull request #5480 from matrix-org/erikj/extremities_dummy_eventsErik Johnston2019-06-195-1/+124
| |\ \ \ \ | | | | | | | | | | | | Add experimental option to reduce extremities.
| | * | | | Run as background process and fix commentsErik Johnston2019-06-192-3/+6
| | | | | |
| | * | | | Add experimental option to reduce extremities.Erik Johnston2019-06-185-1/+121
| | | |_|/ | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | Adds new config option `cleanup_extremities_with_dummy_events` which periodically sends dummy events to rooms with more than 10 extremities. THIS IS REALLY EXPERIMENTAL.
| * | | | Fix typo in deactivation background jobBrendan Abolivier2019-06-191-1/+1
| | | | |
| * | | | Add some logging to 3pid invite sig verification (#5015)David Baker2019-06-181-8/+38
| | |_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I had to add quite a lot of logging to diagnose a problem with 3pid invites - we only logged the one failure which isn't all that informative. NB. I'm not convinced the logic of this loop is right: I think it should just accept a single valid signature from a trusted source rather than fail if *any* signature is invalid. Also it should probably not skip the rest of middle loop if a check fails? However, I'm deliberately not changing the logic here.
* | | | Sanity-checking for metrics updatesRichard van der Hoff2019-06-191-7/+33
| | | | | | | | | | | | | | | | Check that our clocks go forward.
* | | | Simplify PerformanceCounters.update interfaceRichard van der Hoff2019-06-191-11/+12
| | | | | | | | | | | | | | | | | | | | we already have the duration for the update, so may as well use it rather than passing extra params around and recalculating it.
* | | | Remove unused _get_event_countersRichard van der Hoff2019-06-191-7/+1
|/ / / | | | | | | | | | This has been redundant since cdb3757942fefdcdc3d33b9c6d7c9e44decefd6f.
* | | Merge pull request #5477 from matrix-org/babolivier/third_party_rules_3pidBrendan Abolivier2019-06-172-1/+42
|\ \ \ | | | | | | | | Add third party rules hook for 3PID invites
| * | | Make check_threepid_can_be_invited asyncBrendan Abolivier2019-06-171-0/+1
| | | |
| * | | Add third party rules hook for 3PID invitesBrendan Abolivier2019-06-172-1/+41
| | | |
* | | | Merge pull request #5479 from matrix-org/erikj/add_create_room_hook_developErik Johnston2019-06-172-4/+48
|\| | | | | | | | | | | Add third party rules hook into create room
| * | | Add third party rules hook into create roomErik Johnston2019-06-172-4/+48
| |/ /
* / / Remove Postgres 9.4 support (#5448)Amber Brown2019-06-182-24/+6
|/ /
* | Merge pull request #5385 from matrix-org/erikj/reduce_http_exceptionsErik Johnston2019-06-174-19/+28
|\ \ | | | | | | Handle HttpResponseException when using federation client.
| * | Handle failing to talk to master over replicationErik Johnston2019-06-071-1/+9
| | |
| * | Handle HttpResponseException when using federation client.Erik Johnston2019-06-073-18/+19
| | | | | | | | | | | | Otherwise we just log exceptions everywhere.
* | | Merge pull request #5388 from matrix-org/erikj/fix_email_pushErik Johnston2019-06-173-7/+53
|\ \ \ | | | | | | | | Fix email notifications for unnamed rooms with multiple people
| * | | Add testErik Johnston2019-06-072-7/+42
| | | |
| * | | Fix email notifications for large unnamed rooms.Erik Johnston2019-06-071-0/+11
| |/ / | | | | | | | | | | | | | | | When we try and calculate a description for a room for with no name but multiple other users we threw an exception (due to trying to subscript result of `dict.values()`).
* | | Merge pull request #5389 from matrix-org/erikj/renew_attestations_on_masterErik Johnston2019-06-171-3/+4
|\ \ \ | | | | | | | | Only start background group attestation renewals on master
| * | | Only start background group attestation renewals on masterErik Johnston2019-06-071-3/+4
| | | |
* | | | Merge pull request #5464 from matrix-org/erikj/3pid_remote_invite_stateErik Johnston2019-06-171-6/+0
|\ \ \ \ | | | | | | | | | | Fix 3PID invite room state over federation.
| * | | | Fix 3PID invite room state over federation.Erik Johnston2019-06-141-6/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes that when a user exchanges a 3PID invite for a proper invite over federation it does not include the `invite_room_state` key. This was due to synapse incorrectly sending out two invite requests.
* | | | | Merge pull request #5440 from matrix-org/babolivier/third_party_event_rulesBrendan Abolivier2019-06-146-4/+191
|\ \ \ \ \ | | | | | | | | | | | | Allow server admins to define implementations of extra rules for allowing or denying incoming events
| * | | | | Add plugin APIs for implementations of custom event rules.Brendan Abolivier2019-06-146-4/+191
| | | | | |
* | | | | | Merge pull request #5461 from matrix-org/erikj/histograms_are_cumalitiveErik Johnston2019-06-142-2/+2
|\ \ \ \ \ \ | | | | | | | | | | | | | | Prometheus histograms are cumalative
| * | | | | | Prometheus histograms are cumalativeErik Johnston2019-06-142-2/+2
| | | | | | |
* | | | | | | Merge pull request #5465 from matrix-org/babolivier/fix_deactivation_bg_jobBrendan Abolivier2019-06-141-2/+4
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | Fix background job for deactivated flag
| * | | | | | | Fix background job for deactivated flagBrendan Abolivier2019-06-141-2/+4
| | | | | | | |
* | | | | | | | Merge pull request #5462 from ↵Brendan Abolivier2019-06-144-2/+25
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | matrix-org/babolivier/account_validity_deactivated_accounts_2 Don't send renewal emails to deactivated users (second attempt)
| * | | | | | | Don't send renewal emails to deactivated usersBrendan Abolivier2019-06-144-2/+25
| |/ / / / / /
* | | | | | | Merge pull request #5390 from matrix-org/erikj/dont_log_on_fail_to_get_fileErik Johnston2019-06-142-6/+13
|\ \ \ \ \ \ \ | |/ / / / / / |/| | | | | | Don't log exception when failing to fetch remote content.
| * | | | | | Don't log exception when failing to fetch remote content.Erik Johnston2019-06-072-6/+13
| | |_|/ / / | |/| | | | | | | | | | | | | | | | | | | | | | In particular, let's not log stack traces when we stop processing becuase the response body was too large.
* | | | | | Track deactivated accounts in the database (#5378)Brendan Abolivier2019-06-143-0/+137
| | | | | |
* | | | | | fix prometheus rendering errorAmber H. Brown2019-06-141-1/+1
| | | | | |
* | | | | | Clean up code for sending federation EDUs. (#5381)Richard van der Hoff2019-06-131-14/+26
| | | | | | | | | | | | | | | | | | | | | | | | This code confused the hell out of me today. Split _get_new_device_messages into its two (unrelated) parts.
* | | | | | Expose statistics on extrems to prometheus (#5384)Amber Brown2019-06-132-33/+123
| | | | | |
* | | | | | Remove Python 2.7 support. (#5425)Amber Brown2019-06-122-2/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * remove 2.7 from CI and publishing * fill out classifiers and also make it not be installed on 3.5 * some minor bumps so that the old deps work on python 3.5
* | | | | | Merge branch 'master' of github.com:matrix-org/synapse into developErik Johnston2019-06-116-9/+9
|\ \ \ \ \ \ | | |_|/ / / | |/| | | |
| * | | | | 1.0.0 v1.0.0Erik Johnston2019-06-111-1/+1
| | | | | |
| * | | | | Bump bleach version so that tests can run on old deps.Erik Johnston2019-06-111-1/+1
| | | | | |
| * | | | | Change password reset links to /_matrix.Erik Johnston2019-06-114-7/+7
| | |/ / / | |/| | |
* | | | | Merge branch 'release-v1.0.0' of github.com:matrix-org/synapse into developErik Johnston2019-06-114-2/+7
|\| | | |
| * | | | 1.0.0rc3 v1.0.0rc3Erik Johnston2019-06-111-1/+1
| | | | |
| * | | | Fix defaults on checking threepidsErik Johnston2019-06-102-1/+2
| | | | |
| * | | | Merge pull request #5418 from matrix-org/erikj/fix_send_fed_with_limit_zeroErik Johnston2019-06-101-0/+4
| |\ \ \ \ | | | | | | | | | | | | Fix bug sending federation transactions with lots of EDUs
| | * | | | Fix bug sending federation transactions with lots of EDUsErik Johnston2019-06-101-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If we try and send a transaction with lots of EDUs and we run out of space, we call get_new_device_msgs_for_remote with a limit of 0, which then failed.
* | | | | | Don't warn user about password reset disabling through config code (#5387)Andrew Morgan2019-06-112-10/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Moves the warning about password resets being disabled to the point where a user actually tries to reset their password. Is this an appropriate place for it to happen? Also removed the disabling of msisdn password resets when you don't have an email config, as that just doesn't make sense. Also change the error a user receives upon disabled passwords to specify that only email-based password reset is disabled.
* | | | | | add monthly active users to phonehome stats (#5252)Neil Johnson2019-06-102-15/+30
| | | | | | | | | | | | | | | | | | | | | | | | * add monthly active users to phonehome stats
* | | | | | Merge branch 'release-v1.0.0' of github.com:matrix-org/synapse into developErik Johnston2019-06-105-87/+134
|\| | | | |
| * | | | | 1.0.0rc2 v1.0.0rc2Erik Johnston2019-06-101-1/+1
| | | | | |
| * | | | | Merge pull request #5417 from matrix-org/rav/shared_ssl_contextErik Johnston2019-06-102-75/+110
| |\ \ \ \ \ | | |/ / / / | |/| | | | Share an SSL context object between SSL connections
| | * | | | rename gutwrenched attrRichard van der Hoff2019-06-101-5/+9
| | | | | |
| | * | | | Fix federation connections to literal IP addressesRichard van der Hoff2019-06-102-6/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | turns out we need a shiny version of service_identity to enforce this correctly.
| | * | | | clean up impl, and import idna directlyRichard van der Hoff2019-06-102-15/+12
| | | | | |
| | * | | | Share an SSL context object between SSL connectionsRichard van der Hoff2019-06-091-60/+89
| | |/ / / | | | | | | | | | | | | | | | This involves changing how the info callbacks work.
| * | | | Merge branch 'erikj/fix_null_valid_until_ms' of ↵Erik Johnston2019-06-101-0/+8
| |\ \ \ \ | | | | | | | | | | | | | | | | | | github.com:matrix-org/synapse into release-v1.0.0
| * | | | | Improve startup checks for insecure notary configs (#5392)Richard van der Hoff2019-06-102-11/+23
| | |/ / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's not really a problem to trust notary responses signed by the old key so long as we are also doing TLS validation. This commit adds a check to the config parsing code at startup to check that we do not have the insecure matrix.org key without tls validation, and refuses to start without it. This allows us to remove the rather alarming-looking warning which happens at runtime.
* | | | | Merge pull request #5415 from matrix-org/erikj/fix_null_valid_until_msErik Johnston2019-06-101-0/+8
|\ \ \ \ \ | | |/ / / | |/| | | Fix key verification when key stored with null valid_until_ms
| * | | | Fix key verification when key stored with null valid_until_msErik Johnston2019-06-101-0/+8
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some keys are stored in the synapse database with a null valid_until_ms which caused an exception to be thrown when using that key. We fix this by treating nulls as zeroes, i.e. they keys will match verification requests with a minimum_valid_until_ms of zero (i.e. don't validate ts) but will not match requests with a non-zero minimum_valid_until_ms. Fixes #5391.
* | | | Merge pull request #5363 from ↵Brendan Abolivier2019-06-102-3/+14
|\ \ \ \ | |/ / / |/| | | | | | | | | | | matrix-org/babolivier/account_validity_send_mail_auth Don't check whether the user's account is expired on /send_mail requests
| * | | Better wordingBrendan Abolivier2019-06-101-1/+1
| | | |
| * | | DocBrendan Abolivier2019-06-101-0/+5
| | | |
| * | | Don't check whether the user's account is expired on /send_mail requestsBrendan Abolivier2019-06-052-3/+9
| | | |
* | | | 1.0.0rc1 v1.0.0rc1Neil Johnson2019-06-071-1/+1
| |/ / |/| |
* | | Prevent multiple device list updates from breaking a batch send (#5156)Andrew Morgan2019-06-062-31/+126
| | | | | | | | | fixes #5153
* | | Set default room version to v4. (#5379)Neil Johnson2019-06-061-1/+1
| | | | | | | | | | | | Set default room version to v4.
* | | Merge pull request #5320 from matrix-org/hawkowl/full-schema-v1Erik Johnston2019-06-065-2/+2352
|\ \ \ | | | | | | | | Make a full SQL schema
| * | | fix maybeAmber H. Brown2019-06-071-20/+2
| | | |
| * | | just user dir?Amber H. Brown2019-06-071-1/+19
| | | |
| * | | remove background updates that arent neededAmber H. Brown2019-06-071-33/+1
| | | |
| * | | add more commentsAmber Brown2019-06-061-0/+5
| | | |
| * | | Merge remote-tracking branch 'origin/develop' into hawkowl/full-schema-v1Amber Brown2019-06-0439-323/+294
| |\ \ \
| * | | | add stuff in bg updatesAmber Brown2019-06-041-10/+62
| | | | |
| * | | | WHY IS THIS CALLED A SLIGHTLY DIFFERENT THINGAmber Brown2019-06-031-0/+1
| | | | |
| * | | | more fixAmber Brown2019-06-031-0/+38
| | | | |
| * | | | fix schemasAmber Brown2019-06-034-61/+20
| | | | |
| * | | | full schemaAmber Brown2019-06-033-0/+2315
| | | | |
| * | | | prepareAmber Brown2019-06-031-2/+14
| | | | |
* | | | | Add ability to perform password reset via email without trusting the ↵Andrew Morgan2019-06-0617-60/+871
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | identity server (#5377) Sends password reset emails from the homeserver instead of proxying to the identity server. This is now the default behaviour for security reasons. If you wish to continue proxying password reset requests to the identity server you must now enable the email.trust_identity_server_for_password_resets option. This PR is a culmination of 3 smaller PRs which have each been separately reviewed: * #5308 * #5345 * #5368
* | | | | Stop hardcoding trust of old matrix.org key (#5374)Richard van der Hoff2019-06-062-74/+226
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There are a few changes going on here: * We make checking the signature on a key server response optional: if no verify_keys are specified, we trust to TLS to validate the connection. * We change the default config so that it does not require responses to be signed by the old key. * We replace the old 'perspectives' config with 'trusted_key_servers', which is also formatted slightly differently. * We emit a warning to the logs every time we trust a key server response signed by the old key.
* | | | | Fix missing logcontext for PresenceHandler.on_shutdown. (#5369)Richard van der Hoff2019-06-061-1/+7
| | | | | | | | | | | | | | | | | | | | Fixes some warnings, and a scary-looking stacktrace when sytest kills the process.
* | | | | Merge pull request #5221 from matrix-org/erikj/fix_worker_sytestErik Johnston2019-06-061-1/+11
|\ \ \ \ \ | | | | | | | | | | | | Fix get_max_topological_token to never return None
| * | | | | Better wordsErik Johnston2019-06-061-1/+1
| | | | | |
| * | | | | Fix get_max_topological_token to never return NoneErik Johnston2019-05-211-1/+11
| | | | | |
* | | | | | Merge pull request #5089 from dnaf/m-heroes-empty-room-nameBrendan Abolivier2019-06-061-5/+4
|\ \ \ \ \ \ | | | | | | | | | | | | | | Make /sync return heroes if room name or canonical alias are empty
| * | | | | | Simplify conditionBrendan Abolivier2019-06-061-2/+2
| | | | | | |
| * | | | | | Simplify conditionBrendan Abolivier2019-06-051-3/+2
| | | | | | |
| * | | | | | Merge branch 'develop' into m-heroes-empty-room-nameBrendan Abolivier2019-06-05136-1945/+5896
| |\ \ \ \ \ \
| * | | | | | | LintKatie Wolfe2019-04-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I probably should've just run autopep8 in the first place... Signed-off-by: Katie Wolfe <katie@dnaf.moe>
| * | | | | | | Clean up codeKatie Wolfe2019-04-241-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Katie Wolfe <katie@dnaf.moe>
| * | | | | | | Show heroes if room name or canonical alias are emptyKatie Wolfe2019-04-241-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes #4194 Signed-off-by: Katie Wolfe <katie@dnaf.moe>
| * | | | | | | Show heroes if room name or canonical alias are emptyKatie Wolfe2019-04-241-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes #4194 Signed-off-by: Katie Wolfe <katie@dnaf.moe>
* | | | | | | | Merge pull request #5359 from matrix-org/rav/enable_tls_verificationRichard van der Hoff2019-06-061-5/+5
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | Validate federation server TLS certificates by default.
| * \ \ \ \ \ \ \ Merge branch 'rav/fix_custom_ca' into rav/enable_tls_verificationRichard van der Hoff2019-06-057-22/+121
| |\ \ \ \ \ \ \ \
| * | | | | | | | | Validate federation server TLS certificates by default.Richard van der Hoff2019-06-051-5/+5
| | | | | | | | | |
* | | | | | | | | | Merge pull request #5355 from matrix-org/babolivier/heroes_left_membersBrendan Abolivier2019-06-061-15/+19
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | Include left members in room summaries' heroes
| * | | | | | | | | | Do user_id != me checks before deciding whether we should pick heroes from ↵Brendan Abolivier2019-06-051-15/+19
| | |_|_|/ / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | the joined members or the parted ones
* | | | | | | | | | Merge pull request #5354 from matrix-org/rav/server_keys/99-room-v5Richard van der Hoff2019-06-061-5/+5
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | Implement room v5 which enforces signing key validity
| * | | | | | | | | | Implement room v5 which enforces signing key validityRichard van der Hoff2019-06-051-5/+5
| | |/ / / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Implements [MSC2077](https://github.com/matrix-org/matrix-doc/pull/2077) and fixes #5247 and #4364.
* | | | | | | | | | Merge pull request #5353 from matrix-org/rav/verify_key_loggingRichard van der Hoff2019-06-064-46/+76
|\ \ \ \ \ \ \ \ \ \ | |_|_|/ / / / / / / |/| | | | | | | | | Associate a request_name with each verify request, for logging
| * | | | | | | | | Associate a request_name with each verify request, for loggingRichard van der Hoff2019-06-054-46/+76
| |/ / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also: * rename VerifyKeyRequest->VerifyJsonRequest * calculate key_ids on VerifyJsonRequest construction * refactor things to pass around VerifyJsonRequests instead of 4-tuples
* | | | | | | | | Fix `federation_custom_ca_list` configuration option.Richard van der Hoff2019-06-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, setting this option would cause an exception at startup.
* | | | | | | | | Neilj/add r0.5 to versions (#5360)Neil Johnson2019-06-051-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | * Update _matrix/client/versions to reference support for r0.5.0
* | | | | | | | | Fix background updates to handle redactions/rejections (#5352)Erik Johnston2019-06-063-9/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Fix background updates to handle redactions/rejections In background updates based on current state delta stream we need to handle that we may not have all the events (or at least that `get_events` may raise an exception).
* | | | | | | | | Merge pull request #5317 from matrix-org/erikj/make_do_auth_non_essentialErik Johnston2019-06-051-12/+46
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | Fix handling of failures when calling /event_auth.
| * | | | | | | | | Add logging when request fails and clarify we ignore errors.Erik Johnston2019-06-051-4/+12
| | | | | | | | | |
| * | | | | | | | | Fix handling of failures when calling /event_auth.Erik Johnston2019-06-031-12/+38
| | |_|_|_|/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When processing an incoming event over federation, we may try and resolve any unexpected differences in auth events. This is a non-essential process and so should not stop the processing of the event if it fails (e.g. due to the remote disappearing or not implementing the necessary endpoints). Fixes #3330
* | | | | | | | | Neilj/mau tracking config explainer (#5284)Neil Johnson2019-06-051-0/+16
| |/ / / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | Improve documentation of monthly active user blocking and mau_trial_days
* | | | | | | | Add a test room version where we enforce key validity (#5348)Richard van der Hoff2019-06-052-22/+37
| |/ / / / / / |/| | | | | |
* | | | | | | Clean up debug logging (#5347)Richard van der Hoff2019-06-053-8/+18
| | | | | | | | | | | | | | | | | | | | | Remove some spurious stuff, clarify some other stuff
* | | | | | | Rename VerifyKeyRequest.deferred field (#5343)Richard van der Hoff2019-06-051-12/+12
| | | | | | | | | | | | | | | | | | | | | it's a bit confusing
* | | | | | | Call RetryLimiter correctly (#5340)Richard van der Hoff2019-06-041-1/+6
| | | | | | | | | | | | | | | | | | | | | Fixes a regression introduced in #5335.
* | | | | | | Fix failure to fetch batches of PDUs (#5342)Richard van der Hoff2019-06-041-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | FederationClient.get_pdu is called in a loop to fetch a batch of PDUs. A failure to fetch one should not result in a failure of the whole batch. Add the missing `continue`.
* | | | | | | Rename get_events->get_events_from_store_or_dest (#5344)Richard van der Hoff2019-06-041-20/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We have too many things called get_event, and it's hard to figure out what we mean. Also remove some unused params from the signature, and add some logging.
* | | | | | | Merge pull request #5341 from matrix-org/babolivier/email_configBrendan Abolivier2019-06-041-42/+57
|\ \ \ \ \ \ \ | | |_|_|_|/ / | |/| | | | | Make account validity renewal emails work when email notifs are disabled
| * | | | | | Only parse from email if providedBrendan Abolivier2019-06-041-4/+5
| | | | | | |
| * | | | | | LintBrendan Abolivier2019-06-041-1/+0
| | | | | | |
| * | | | | | Make account validity renewal emails work when email notifs are disabledBrendan Abolivier2019-06-041-42/+57
| | | | | | |
* | | | | | | Merge pull request #5324 from matrix-org/erikj/ignore_nullErik Johnston2019-06-041-0/+16
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | Ignore room state with null bytes in for room stats
| * | | | | | | FixErik Johnston2019-06-031-1/+2
| | | | | | | |
| * | | | | | | Ignore room state with null bytes in for room statsErik Johnston2019-06-031-0/+15
| | |_|_|_|/ / | |/| | | | |
* | | | | | | Avoid rapidly backing-off a server if we ignore the retry interval (#5335)Richard van der Hoff2019-06-041-23/+37
|\ \ \ \ \ \ \
| * | | | | | | Avoid rapidly backing-off a server if we ignore the retry intervalRichard van der Hoff2019-06-031-23/+37
| | | | | | | |
* | | | | | | | Don't do long retries when calling the key notary server. (#5334)Richard van der Hoff2019-06-041-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It takes at least 20 minutes to work through the long_retries schedule (11 attempts, each with a 60 second timeout, and 60 seconds between each request), so if the notary server isn't returning within the timeout, we'll just end up blocking whatever request is happening for 20 minutes. Ain't nobody got time for that.
* | | | | | | | Merge pull request #5333 from ↵Richard van der Hoff2019-06-042-33/+60
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | matrix-org/rav/server_keys/09_improve_notary_server Fixes for the key-notary server
| * | | | | | | | Notary server: make requests to origins in parallelRichard van der Hoff2019-06-042-11/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ... else we're guaranteed to time out.
| * | | | | | | | Don't bomb out on direct key fetches as soon as one failsRichard van der Hoff2019-06-041-22/+36
| | | | | | | | |
| * | | | | | | | Reduce timeout for outbound /key/v2/server requests.Richard van der Hoff2019-06-031-0/+13
| |/ / / / / / /
* | | | | | | | Improve docstrings on MatrixFederationClient. (#5332)Richard van der Hoff2019-06-041-16/+55
| | | | | | | |
* | | | | | | | Hawkowl/fix missing auth (#5328)Amber Brown2019-06-041-0/+1
|/ / / / / / /
* / / / / / / Enforce validity period on server_keys for fed requests. (#5321)Richard van der Hoff2019-06-034-61/+119
|/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When handling incoming federation requests, make sure that we have an up-to-date copy of the signing key. We do not yet enforce the validity period for event signatures.
* | | | | | Merge pull request #5307 from ↵Richard van der Hoff2019-06-031-12/+2
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | matrix-org/rav/server_keys/07-fix-notary-cache-poison Stop overwriting server keys with other keys
| * | | | | | Stop overwriting server keys with other keysRichard van der Hoff2019-05-311-12/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix a bug where we would discard a key result which the origin server is no longer returning. Fixes #5305.
* | | | | | | Unify v1 and v2 REST client APIs (#5226)Amber Brown2019-06-0338-311/+292
| |_|/ / / / |/| | | | |
* | | | | | Merge pull request #5309 from matrix-org/rav/limit_displayname_lengthRichard van der Hoff2019-06-012-0/+15
|\ \ \ \ \ \ | | | | | | | | | | | | | | Limit displaynames and avatar URLs
| * | | | | | Limit displaynames and avatar URLsRichard van der Hoff2019-06-012-0/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These end up in join events everywhere, so let's limit them. Fixes #5079
* | | | | | | Merge pull request #5299 from matrix-org/rav/server_keys/05-rewrite-gsvk-againRichard van der Hoff2019-05-311-48/+53
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | Rewrite get_server_verify_keys, again.
| * \ \ \ \ \ \ Merge remote-tracking branch 'origin/develop' into ↵Richard van der Hoff2019-05-316-128/+141
| |\ \ \ \ \ \ \ | | | |/ / / / / | | |/| | | | | | | | | | | | | rav/server_keys/05-rewrite-gsvk-again
| * | | | | | | Rewrite get_server_verify_keys, again.Richard van der Hoff2019-05-301-48/+53
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Attempt to simplify the logic in get_server_verify_keys by splitting it into two methods.
* | | | | | | | Merge pull request #5276 from matrix-org/babolivier/account_validity_job_deltaErik Johnston2019-05-312-3/+25
|\ \ \ \ \ \ \ \ | |_|/ / / / / / |/| | | | | | | Allow configuring a range for the account validity startup job
| * | | | | | | Move delta from +10% to -10%Brendan Abolivier2019-05-312-3/+3
| | | | | | | |
| * | | | | | | Gah pythonBrendan Abolivier2019-05-311-1/+1
| | | | | | | |
| * | | | | | | Make max_delta equal to period * 10%Brendan Abolivier2019-05-312-15/+7
| | | | | | | |
| * | | | | | | Allow configuring a range for the account validity startup jobBrendan Abolivier2019-05-282-2/+32
| | |_|/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | When enabling the account validity feature, Synapse will look at startup for registered account without an expiration date, and will set one equals to 'now + validity_period' for them. On large servers, it can mean that a large number of users will have the same expiration date, which means that they will all be sent a renewal email at the same time, which isn't ideal. In order to mitigate this, this PR allows server admins to define a 'max_delta' so that the expiration date is a random value in the [now + validity_period ; now + validity_period + max_delta] range. This allows renewal emails to be progressively sent over a configured period instead of being sent all in one big batch.
* | | | | | | Merge pull request #5300 from ↵Richard van der Hoff2019-05-311-25/+8
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | matrix-org/rav/server_keys/06-fix-serverkeys-handling Remove some pointless exception handling
| * | | | | | | Remove some pointless exception handlingRichard van der Hoff2019-05-301-25/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The verify_request deferred already returns a suitable SynapseError, so I don't really know what we expect to achieve by doing more wrapping, other than log spam. Fixes #4278.
* | | | | | | | Merge pull request #5296 from ↵Richard van der Hoff2019-05-311-17/+21
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | matrix-org/rav/server_keys/04-use-attrs-for_verify-request use attr.s for VerifyKeyRequest
| * | | | | | | use attr.s for VerifyKeyRequestRichard van der Hoff2019-05-301-17/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | because namedtuple is awful
* | | | | | | | Merge pull request #5293 from Kagamihime/messages-federation-formatErik Johnston2019-05-311-0/+2
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | Fix ignored filter field in `/messages` endpoint
| * | | | | | | | Fix ignored filter field in `/messages` endpointEisha Chen-yen-su2019-05-301-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes a bug which were causing the "event_format" field to be ignored in the filter of requests to the `/messages` endpoint of the CS API. Signed-off-by: Eisha Chen-yen-su <chenyensu0@gmail.com>
* | | | | | | | | Merge pull request #5294 from matrix-org/erikj/speed_up_room_statsErik Johnston2019-05-314-87/+111
|\ \ \ \ \ \ \ \ \ | |_|_|_|/ / / / / |/| | | | | | | | Speed up room stats background update
| * | | | | | | | Add indices. Remove room_ids accidentally addedErik Johnston2019-05-312-13/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We have to do this by re-inserting a background update and recreating tables, as the tables only get created during a background update and will later be deleted. We also make sure that we remove any entries that should have been removed but weren't due to a race that has been fixed in a previous commit.
| * | | | | | | | Join against events to use its room_id indexErik Johnston2019-05-301-1/+6
| | | | | | | | |
| * | | | | | | | Move deletion from table inside txnErik Johnston2019-05-301-2/+5
| | | | | | | | |
| * | | | | | | | Fetch membership counts all at onceErik Johnston2019-05-302-38/+18
| | | | | | | | |
| * | | | | | | | Get events all at onceErik Johnston2019-05-301-33/+26
| | | | | | | | |
* | | | | | | | | Merge branch 'master' into developErik Johnston2019-05-301-1/+1
|\ \ \ \ \ \ \ \ \ | |_|/ / / / / / / |/| | | | | | | |
| * | | | | | | | 0.99.5.2 v0.99.5.2 github/release-v0.99.5 release-v0.99.5Erik Johnston2019-05-301-1/+1
| | | | | | | | |
| * | | | | | | | Add index to temp tableErik Johnston2019-05-301-0/+1
| | | | | | | | |
| * | | | | | | | Update synapse/storage/events_bg_updates.pyErik Johnston2019-05-301-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Co-Authored-By: Richard van der Hoff <1389908+richvdh@users.noreply.github.com>
| * | | | | | | | Rename constantErik Johnston2019-05-301-3/+3
| | | | | | | | |
| * | | | | | | | Move event background updates to a separate fileErik Johnston2019-05-303-369/+405
| | | | | | | | |
| * | | | | | | | Fixup comments and loggingErik Johnston2019-05-302-9/+15
| | | | | | | | |
| * | | | | | | | Log actual number of entries deletedErik Johnston2019-05-302-5/+13
| | | | | | | | |
| * | | | | | | | Add DB bg update to cleanup extremities.Erik Johnston2019-05-302-0/+205
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Due to #5269 we may have extremities in our DB that we shouldn't have, so lets add a cleanup task such to remove those.
| * | | | | | | | Correctly filter out extremities with soft failed prevs (#5274)Erik Johnston2019-05-301-3/+79
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When we receive a soft failed event we, correctly, *do not* update the forward extremity table with the event. However, if we later receive an event that references the soft failed event we then need to remove the soft failed events prev events from the forward extremities table, otherwise we just build up forward extremities. Fixes #5269
* | | | | | | | | Add index to temp tableErik Johnston2019-05-301-0/+1
| |/ / / / / / / |/| | | | | | |
* | | | | | | | Merge pull request #5278 from matrix-org/erikj/cleanup_bad_extremitiesErik Johnston2019-05-305-181/+436
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | Add DB bg update to cleanup extremities.
| * | | | | | | | Update synapse/storage/events_bg_updates.pyErik Johnston2019-05-301-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Co-Authored-By: Richard van der Hoff <1389908+richvdh@users.noreply.github.com>
| * | | | | | | | Rename constantErik Johnston2019-05-301-3/+3
| | | | | | | | |
| * | | | | | | | Move event background updates to a separate fileErik Johnston2019-05-303-369/+405
| | | | | | | | |
| * | | | | | | | Fixup comments and loggingErik Johnston2019-05-302-9/+15
| | | | | | | | |
| * | | | | | | | Log actual number of entries deletedErik Johnston2019-05-292-5/+13
| | | | | | | | |
| * | | | | | | | Add DB bg update to cleanup extremities.Erik Johnston2019-05-292-0/+205
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Due to #5269 we may have extremities in our DB that we shouldn't have, so lets add a cleanup task such to remove those.
* | | | | | | | | Merge pull request #5256 from aaronraimist/logout-correct-errorErik Johnston2019-05-301-18/+9
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | Show correct error when logging out and access token is missing
| * | | | | | | | | LintAaron Raimist2019-05-291-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Aaron Raimist <aaron@raim.ist>
| * | | | | | | | | Get rid of try exceptAaron Raimist2019-05-271-16/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Aaron Raimist <aaron@raim.ist>
| * | | | | | | | | Show correct error when logging out and access token is missingAaron Raimist2019-05-241-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Aaron Raimist <aaron@raim.ist>
* | | | | | | | | | Remove spurious debug from MatrixFederationHttpClient.get_json (#5287) v0.99.5.1.dev0Richard van der Hoff2019-05-291-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is just unhelpful spam
* | | | | | | | | | Improve logging for logcontext leaks. (#5288)Richard van der Hoff2019-05-291-9/+13
| | | | | | | | | |
* | | | | | | | | | Implement the SHHS complexity API (#5216)Amber Brown2019-05-304-5/+89
| | | | | | | | | |
* | | | | | | | | | Serve CAS login over r0 (#5286)Amber Brown2019-05-301-2/+2
| | | | | | | | | |
* | | | | | | | | | Fix error when downloading thumbnail with width/height param missing (#5258)Aaron Raimist2019-05-291-2/+2
| |/ / / / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix error when downloading thumbnail with width/height param missing Fixes #2748 Signed-off-by: Aaron Raimist <aaron@raim.ist>
* | | | | | | | | Correctly filter out extremities with soft failed prevs (#5274)Erik Johnston2019-05-291-3/+79
| |_|/ / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When we receive a soft failed event we, correctly, *do not* update the forward extremity table with the event. However, if we later receive an event that references the soft failed event we then need to remove the soft failed events prev events from the forward extremities table, otherwise we just build up forward extremities. Fixes #5269
* | | | | | | | Fix dropped logcontexts during high outbound traffic. (#5277)Richard van der Hoff2019-05-291-7/+13
| | | | | | | | | | | | | | | | | | | | | | | | Fixes #5271.
* | | | | | | | Fix docs on resetting the user directory (#5036)Aaron Raimist2019-05-281-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Aaron Raimist <aaron@raim.ist>
* | | | | | | | Merge pull request #5251 from matrix-org/rav/server_keys/01-check_sigRichard van der Hoff2019-05-281-41/+92
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | Ensure that server_keys fetched via a notary server are correctly signed.
| * | | | | | | | Improve error handling/logging for perspectives-key fetching.Richard van der Hoff2019-05-241-28/+77
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In particular, don't give up on the first failure.
| * | | | | | | | Require sig from origin server on perspectives responsesRichard van der Hoff2019-05-231-13/+15
| | | | | | | | |
* | | | | | | | | Fix "db txn 'update_presence' from sentinel context" log messages (#5275)Richard van der Hoff2019-05-281-52/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes #4414.
* | | | | | | | | Merge pull request #5268 from matrix-org/babolivier/account_validity_fix_schemaBrendan Abolivier2019-05-281-0/+3
|\ \ \ \ \ \ \ \ \ | | |_|_|/ / / / / | |/| | | | | | | Fix schema update for account validity
| * | | | | | | | Fix schema update for account validityBrendan Abolivier2019-05-281-0/+3
| | | | | | | | |
* | | | | | | | | Merge pull request #5260 from matrix-org/travis/fix-room-bg-taskErik Johnston2019-05-251-1/+1
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | Fix logging for room stats background update
| * | | | | | | | | Fix logging for room stats background updateTravis Ralston2019-05-251-1/+1
| | | | | | | | | |
* | | | | | | | | | Merge pull request #5257 from aaronraimist/fix-error-code-publicroomsErik Johnston2019-05-251-1/+1
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | Fix error code for invalid parameter
| * | | | | | | | | | Fix error code for invalid parameterAaron Raimist2019-05-241-1/+1
| | |_|_|/ / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Aaron Raimist <aaron@raim.ist>
* / | | | | | | | | Simplification to Keyring.wait_for_previous_lookups. (#5250)Richard van der Hoff2019-05-241-7/+4
|/ / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The list of server names was redundant, since it was equivalent to the keys on the server_to_deferred map. This reduces the number of large lists being passed around, and has the benefit of deduplicating the entries in `wait_on`.
* | | | | | | | | Fix appservice timestamp massaging (#5233)Tulir Asokan2019-05-241-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Tulir Asokan <tulir@maunium.net>
* | | | | | | | | Add missing blank line in config (#5249)Richard van der Hoff2019-05-241-0/+1
| | | | | | | | |
* | | | | | | | | Merge pull request #5220 from matrix-org/erikj/dont_bundle_live_eventsErik Johnston2019-05-244-2/+12
|\ \ \ \ \ \ \ \ \ | |/ / / / / / / / |/| | | | | | | | Don't bundle aggregations with events in /sync or /events or state queries
| * | | | | | | | Don't bundle aggs for /state and /members etc APIsErik Johnston2019-05-241-0/+3
| | | | | | | | |
| * | | | | | | | Don't bundle events in /sync or /eventsErik Johnston2019-05-213-2/+9
| | |_|_|_|_|/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As we'll send down the annotations too anyway, so this just ends up confusing clients.
* | | | | | | | Merge pull request #5244 from matrix-org/rav/server_keys/00-factor-out-fetchersErik Johnston2019-05-232-143/+178
|\ \ \ \ \ \ \ \ | | |_|/ / / / / | |/| | | | | | Factor out KeyFetchers from KeyRing
| * | | | | | | Fix remote_key_resourceRichard van der Hoff2019-05-231-3/+3
| | | | | | | |
| * | | | | | | Factor out KeyFetchers from KeyRingRichard van der Hoff2019-05-231-140/+175
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rather than have three methods which have to have the same interface, factor out a separate interface which is provided by three implementations. I find it easier to grok the code this way.
* | | | | | | | Add config option for setting homeserver's default room version (#5223)Andrew Morgan2019-05-234-8/+42
|/ / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | Replaces DEFAULT_ROOM_VERSION constant with a method that first checks the config, then returns a hardcoded value if the option is not present. That hardcoded value is now located in the server.py config file.
* | | | | | | Store key validity time in the storage layerRichard van der Hoff2019-05-233-24/+77
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a first step to checking that the key is valid at the required moment. The idea here is that, rather than passing VerifyKey objects in and out of the storage layer, we instead pass FetchKeyResult objects, which simply wrap the VerifyKey and add a valid_until_ts field.
* | | | | | | Simplify process_v2_response (#5236)Richard van der Hoff2019-05-231-21/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Pass time_added_ms into process_v2_response * Simplify process_v2_response We can merge old_verify_keys into verify_keys, and reduce the number of dicts flying around.
* | | | | | | Remove unused VerifyKey.expired and .time_added fields (#5235)Richard van der Hoff2019-05-231-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These were never used, and poking arbitary data into objects from other packages seems confusing at best.
* | | | | | | Rewrite store_server_verify_key to store several keys at once (#5234)Richard van der Hoff2019-05-232-71/+53
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Storing server keys hammered the database a bit. This replaces the implementation which stored a single key, with one which can do many updates at once.
* | | | | | | Simplifications and comments in do_auth (#5227)Richard van der Hoff2019-05-232-121/+182
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I was staring at this function trying to figure out wtf it was actually doing. This is (hopefully) a non-functional refactor which makes it a bit clearer.
* | | | | | | Run black on synapse.crypto.keyring (#5232)Richard van der Hoff2019-05-221-149/+137
| | | | | | |
* | | | | | | Merge branch 'master' into developNeil Johnson2019-05-221-1/+1
|\ \ \ \ \ \ \ | | |_|/ / / / | |/| | | | |
| * | | | | | 0.99.5.1 v0.99.5.1Neil Johnson2019-05-221-1/+1
| | | | | | |
| * | | | | | Revert "0.99.5"Neil Johnson2019-05-221-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit c31e375ade1b59a7fe38628337e9e1aa3de91feb.
| * | | | | | 0.99.5Neil Johnson2019-05-221-1/+1
| | | | | | |
* | | | | | | remove urllib3 pin (#5230)Marcus Hoffmann2019-05-221-8/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | requests 2.22.0 as been released supporting urllib3 1.25.2 Signed-off-by: Marcus Hoffmann <bubu@bubu1.eu>
* | | | | | | Merge branch 'master' into developNeil Johnson2019-05-221-1/+1
|\| | | | | |
| * | | | | | 0.99.5 v0.99.5Neil Johnson2019-05-221-1/+1
| | |_|/ / / | |/| | | |
* | | | | | Neilj/ensure get profileinfo available in client reader slaved store (#5213)Neil Johnson2019-05-221-0/+2
| | | | | | | | | | | | | | | | | | * expose SlavedProfileStore to ClientReaderSlavedStore
* | | | | | Merge branch 'master' into developRichard van der Hoff2019-05-221-1/+1
|\| | | | |
| * | | | | Merge commit 'f4c80d70f' into release-v0.99.5Richard van der Hoff2019-05-212-5/+61
| |\ \ \ \ \
| * | | | | | 0.99.5rc1Richard van der Hoff2019-05-211-1/+1
| | | | | | |
* | | | | | | Room Statistics (#4338)Amber Brown2019-05-2111-13/+1021
| |/ / / / / |/| | | | |
* | | | | | Merge pull request #5203 from matrix-org/erikj/aggregate_by_senderErik Johnston2019-05-211-1/+1
|\ \ \ \ \ \ | | | | | | | | | | | | | | Only count aggregations from distinct senders