Richard van der Hoff
98247c4a0e
Remove unused, undocumented "content repo" resource ( #6628 )
...
This looks like it got half-killed back in #888 .
Fixes #6567 .
2020-01-03 17:10:52 +00:00
Richard van der Hoff
d6752ce5da
Clean up startup for the pusher ( #6558 )
...
* Remove redundant python2 support code
`str.decode()` doesn't exist on python3, so presumably this code was doing
nothing
* Filter out pushers with corrupt data
When we get a row with unparsable json, drop the row, rather than returning a
row with null `data`, which will then cause an explosion later on.
* Improve logging when we can't start a pusher
Log the ID to help us understand the problem
* Make email pusher setup more robust
We know we'll have a `data` member, since that comes from the database. What we
*don't* know is if that is a dict, and if that has a `brand` member, and if
that member is a string.
2019-12-18 14:26:58 +00:00
Erik Johnston
72acca6a32
Back out change preventing setting null avatar URLs
2019-12-11 11:46:55 +00:00
Andrew Morgan
5e8abe9013
Better errors regarding changing avatar_url ( #6497 )
2019-12-09 14:54:33 +00:00
Erik Johnston
2ace775d88
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/make_database_class
2019-12-06 11:33:34 +00:00
Manuel Stahl
649b6bc088
Replace /admin/v1/users_paginate endpoint with /admin/v2/users ( #5925 )
2019-12-05 18:12:23 +00:00
Erik Johnston
9c41ba4c5f
Port rest.client.v2
2019-12-05 16:56:23 +00:00
Erik Johnston
1a0997bbd5
Port rest/v1 to async/await
2019-12-05 15:57:28 +00:00
Erik Johnston
4a33a6dd19
Move background update handling out of store
2019-12-05 11:11:26 +00:00
Brendan Abolivier
9dc84b7989
Merge branch 'develop' into babolivier/context_filters
2019-12-04 14:23:44 +00:00
Filip Štědronský
81731c6e75
Fix: Pillow error when uploading RGBA image ( #3325 ) ( #6241 )
...
Signed-Off-By: Filip Štědronský <g@regnarg.cz>
2019-12-02 12:12:55 +00:00
Andrew Morgan
23ea572125
Add User-Interactive Auth to /account/3pid/add ( #6119 )
2019-11-29 13:51:14 +00:00
Erik Johnston
69d8fb83c6
MSC2367 Allow reason field on all member events
2019-11-28 11:02:04 +00:00
Hubert Chathi
0d27aba900
add etag and count to key backup endpoints ( #5858 )
2019-11-27 16:14:44 -05:00
Richard van der Hoff
ef1a85e773
Fix startup error when http proxy is defined. ( #6421 )
...
Guess I only tested this on python 2 :/
Fixes #6419 .
2019-11-26 18:10:50 +00:00
Andrew Morgan
3916e1b97a
Clean up newline quote marks around the codebase ( #6362 )
2019-11-21 12:00:14 +00:00
Manuel Stahl
4f5ca455bf
Move admin endpoints into separate files ( #6308 )
2019-11-20 11:49:11 +00:00
Brendan Abolivier
83446a18fb
Merge pull request #6335 from matrix-org/erikj/rc_login_cleanups
...
Only do `rc_login` ratelimiting on succesful login.
2019-11-20 09:52:38 +00:00
Brendan Abolivier
271c322d08
Lint
2019-11-20 09:29:48 +00:00
Erik Johnston
c7376cdfe3
Apply suggestions from code review
...
Co-Authored-By: Andrew Morgan <1342360+anoadragon453@users.noreply.github.com>
Co-Authored-By: Brendan Abolivier <babolivier@matrix.org>
2019-11-18 17:10:16 +00:00
Erik Johnston
541f1b92d9
Only do rc_login
ratelimiting on succesful login.
...
We were doing this in a number of places which meant that some login
code paths incremented the counter multiple times.
It was also applying ratelimiting to UIA endpoints, which was probably
not intentional.
In particular, some custom auth modules were calling
`check_user_exists`, which incremented the counters, meaning that people
would fail to login sometimes.
2019-11-06 11:08:58 +00:00
Richard van der Hoff
5570d1c93f
Merge pull request #6334 from matrix-org/rav/url_preview_limit_title_2
...
Fix exception when OpenGraph tag values are ints
2019-11-05 17:28:11 +00:00
Richard van der Hoff
81d49cbb07
Fix exception when OpenGraph tag values are ints
2019-11-05 17:22:58 +00:00
Richard van der Hoff
55a7da247a
Merge branch 'develop' into rav/url_preview_limit_title
2019-11-05 17:08:07 +00:00
Richard van der Hoff
e78167c94b
Apply suggestions from code review
...
Co-Authored-By: Brendan Abolivier <babolivier@matrix.org>
Co-Authored-By: Erik Johnston <erik@matrix.org>
2019-11-05 16:46:39 +00:00
Richard van der Hoff
e9bfe719ba
Strip overlong OpenGraph data from url preview
...
... to stop people causing DoSes with malicious web pages
2019-11-05 15:51:18 +00:00
Brendan Abolivier
8822b33111
Update copyrights
2019-11-05 14:46:35 +00:00
Brendan Abolivier
f496d25877
Merge pull request #6301 from matrix-org/babolivier/msc2326
...
Implement MSC2326 (label based filtering)
2019-11-01 17:04:45 +00:00
Richard van der Hoff
1cb84c6486
Support for routing outbound HTTP requests via a proxy ( #6239 )
...
The `http_proxy` and `HTTPS_PROXY` env vars can be set to a `host[:port]` value which should point to a proxy.
The address of the proxy should be excluded from IP blacklists such as the `url_preview_ip_range_blacklist`.
The proxy will then be used for
* push
* url previews
* phone-home stats
* recaptcha validation
* CAS auth validation
It will *not* be used for:
* Application Services
* Identity servers
* Outbound federation
* In worker configurations, connections from workers to masters
Fixes #4198 .
2019-11-01 14:07:44 +00:00
Brendan Abolivier
e3689ac6f7
Add unstable feature flag
2019-11-01 10:41:23 +00:00
Amber Brown
020add5099
Update black to 19.10b0 ( #6304 )
...
* update version of black and also fix the mypy config being overridden
2019-11-01 02:43:24 +11:00
Andrew Morgan
54fef094b3
Remove usage of deprecated logger.warn method from codebase ( #6271 )
...
Replace every instance of `logger.warn` with `logger.warning` as the former is deprecated.
2019-10-31 10:23:24 +00:00
Erik Johnston
770d1ef673
Merge pull request #6280 from matrix-org/erikj/receipts_async_await
...
Port receipt and read markers to async/wait
2019-10-30 11:44:18 +01:00
Erik Johnston
2c35ffead2
Port receipt and read markers to async/wait
2019-10-29 15:08:22 +00:00
Erik Johnston
9be41bc121
Port room rest handlers to async/await
2019-10-29 13:09:29 +00:00
Michael Kaye
e4d98188da
Address codestyle concerns
2019-10-24 18:43:13 +01:00
Michael Kaye
8f4a808d9d
Delay printf until logging is required.
...
Using % will cause the string to be generated even if debugging
is off.
2019-10-24 18:31:53 +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
d98029ea89
Merge pull request #6196 from matrix-org/erikj/await
...
Move rest/admin to use async/await.
2019-10-18 11:53:02 +02:00
Erik Johnston
2e97a4c197
Port synapse/rest/client/_base.py to async/await
2019-10-11 15:29:26 +01:00
Erik Johnston
3c2d6c708c
Add maybe_awaitable and fix __init__ bugs
2019-10-11 15:26:09 +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
Valérian Rousset
be9b55e0d2
cas: support setting display name ( #6114 )
...
Now, the CAS server can return an attribute stating what's the desired displayname, instead of using the username directly.
2019-10-11 12:33:12 +01:00
Erik Johnston
dfbb62c28d
Port synaps/rest/client/users.py to async/await
2019-10-11 12:21:40 +01:00
Erik Johnston
f95325e22a
Port synaps/rest/client/server_notice_servlet.py to async/await
2019-10-11 12:21:40 +01:00
Erik Johnston
281f887090
Port synaps/rest/client/media.py to async/await
2019-10-11 12:21:40 +01:00
Erik Johnston
fca3a541e7
Port rest/admin/__init__.py to async/await
2019-10-11 12:17:52 +01:00
Erik Johnston
ca3e01e50d
Fix store_url_cache using bytes
2019-10-10 14:52:29 +01:00
krombel
2efd050c9d
send 404 as http-status when filter-id is unknown to the server ( #2380 )
...
This fixed the weirdness of 400 vs 404 as http status code in the case
the filter id is not known by the server.
As e.g. matrix-js-sdk expects 404 to catch this situation this leads
to unwanted behaviour.
2019-10-10 12:59:55 +01:00