summary refs log tree commit diff
path: root/scripts-dev/check_auth.py (unfollow)
Commit message (Collapse)AuthorFilesLines
2017-10-10pep8David Baker2-3/+5
2017-10-10Don't KeyError if no power_levels eventDavid Baker1-1/+3
2017-10-10Use notification levels in power_levelsDavid Baker3-12/+22
Rather than making the condition directly require a specific power level. This way the level require to notify a room can be configured per room.
2017-10-10There was already a constant for thisDavid Baker1-3/+4
also update copyright
2017-10-10More optimisationDavid Baker1-6/+9
2017-10-10What year is it!? Who's the president!?David Baker1-1/+1
2017-10-09fed server: process PDUs for different rooms in parallelRichard van der Hoff1-19/+34
With luck, this will give a real-time improvement when there are many rooms and the server ends up calling out to fetch missing events.
2017-10-09Fed server: use a linearizer for ongoing transactionsRichard van der Hoff1-1/+29
We don't want to process the same transaction multiple times concurrently, so use a linearizer.
2017-10-09fed server: refactor on_incoming_transactionRichard van der Hoff1-24/+29
Move as much as possible to after the have_responded check, and reduce the number of times we iterate over the pdu list.
2017-10-09Fed server: Move origin-check code to _handle_received_pduRichard van der Hoff1-24/+24
The response-building code expects there to be an entry in the `results` list for each entry in the pdu_list, so the early `continue` was messing this up. That doesn't really matter, because all that the federation client does is log any errors, but it's pretty poor form.
2017-10-09Fix up commentErik Johnston1-1/+2
2017-10-06Fix up logcontext handling in (federation) TransactionQueueRichard van der Hoff1-16/+32
Avoid using preserve_context_over_function, which has problems with respect to logcontexts.
2017-10-06Fix logcontext handling for concurrently_executeRichard van der Hoff1-2/+2
Avoid preserve_context_over_deferred, which is broken.
2017-10-06Fix up deferred handling in federation.pyRichard van der Hoff1-24/+21
* Avoid preserve_context_over_deferred, which is broken * set consumeErrors=True on defer.gatherResults, to avoid spurious "unhandled failure" erros
2017-10-05some comments in the state res codeRichard van der Hoff1-0/+13
2017-10-05Spam checking: add the invitee to user_may_inviteDavid Baker3-8/+10
2017-10-05Make be fasterDavid Baker1-3/+3
2017-10-05Add fastpath optimisationDavid Baker1-3/+9
2017-10-05pep8David Baker1-0/+3
2017-10-05They're called roomsDavid Baker1-4/+4
2017-10-05Get rule type rightDavid Baker1-1/+1
2017-10-05Support for channel notificationsDavid Baker3-8/+59
Add condition type to check the sender's power level and add a base rule using it for @channel notifications.
2017-10-05Use better method for word boundary searchingDavid Baker1-11/+3
From https://github.com/matrix-org/matrix-js-sdk/commit/ebc95667b8a5777d13e5d3c679972bedae022fd5
2017-10-05Don't corrupt cacheErik Johnston1-0/+1
2017-10-05pep8David Baker1-0/+1
2017-10-05Fix notif kws that start/end with non-word charsDavid Baker1-2/+21
Only prepend / append word bounary characters if the search expression starts or ends with a word character, otherwise they don't work because there's no word bounary between whitespace and a non-word char.
2017-10-04spam check room publishingDavid Baker2-0/+26
2017-10-04un-double indentDavid Baker1-1/+1
2017-10-04Add room creation checks to spam checkerDavid Baker3-0/+47
Lets the spam checker deny attempts to create rooms and add aliases to them.
2017-10-03s/roomid/room_id/David Baker1-2/+2
2017-10-03pass room id tooDavid Baker3-4/+6
2017-10-03Federation was passing strings anywayDavid Baker1-1/+1
so pass string everywhere
2017-10-03this shouldn't be debugDavid Baker1-2/+2
2017-10-03better loggingDavid Baker1-4/+9
2017-10-03Actually write warpper functionDavid Baker1-0/+16
2017-10-03Skip spam check for admin usersDavid Baker1-8/+8
2017-10-03Invalidate cacheErik Johnston1-0/+3
2017-10-03Update commentsErik Johnston2-1/+8
2017-10-03Fix param name & lintDavid Baker1-2/+4
2017-10-03Allow spam checker to reject invites tooDavid Baker2-6/+18
2017-10-03Remove spurious line feedErik Johnston1-1/+0
2017-10-03Ignore incoming events for rooms that we have leftErik Johnston2-0/+55
When synapse receives an event for a room its not in over federation, it double checks with the remote server to see if it is in fact in the room. This is done so that if the server has forgotten about the room (usually as a result of the database being dropped) it can recover from it. However, in the presence of state resets in large rooms, this can cause a lot of work for servers that have legitimately left. As a hacky solution that supports both cases we drop incoming events for rooms that we have explicitly left. This means that we no longer support the case of servers having forgotten that they've rejoined a room, but that is sufficiently rare that we're not going to support it for now.
2017-10-02Bump version and changelog v0.23.1Erik Johnston2-1/+9
2017-10-02Make 'affinity' package optionalErik Johnston2-2/+17
2017-10-02Move quit_with_errorErik Johnston2-10/+11
2017-10-02Bump version and change log github/release-v0.23.0 release-v0.23.0Erik Johnston2-1/+7
2017-10-02Drop search values with nul charactersRichard van der Hoff1-4/+7
https://github.com/matrix-org/synapse/issues/2187 contains a report of a port failing due to nul characters somewhere in the search table. Let's try dropping the offending rows.
2017-09-30Unfreeze event before serializing with ujsonJeremy Cline1-1/+2
In newer versions of https://github.com/esnme/ultrajson, ujson does not serialize frozendicts (introduced in esnme/ultrajson@53f85b1). Although the PyPI version is still 1.35, Fedora ships with a build from commit esnme/ultrajson@2f1d487. This causes the serialization to fail if the distribution-provided package is used. This runs the event through the unfreeze utility before serializing it. Thanks to @ignatenkobrain for tracking down the root cause. fixes #2351 Signed-off-by: Jeremy Cline <jeremy@jcline.org>
2017-09-28Only log if we've removed mediaErik Johnston1-2/+4
2017-09-28Improve logging of failures in matrixfederationclientRichard van der Hoff1-7/+6
* don't log exception types twice * not all exceptions have a meaningful 'message'. Use the repr rather than attempting to build a string ourselves.
2017-09-28Handle SERVFAILs when doing AAAA lookups for federation (#2477)Richard van der Hoff1-5/+17
... to cope with people with broken dnssec setups, mostly
2017-09-28Up the limits on number of url cache entries to delete at one timeErik Johnston1-2/+2
2017-09-28Add old indicesErik Johnston1-0/+2
2017-09-28Clear up expired url cache every 10sErik Johnston1-1/+1
2017-09-28Actually assign result to variableErik Johnston1-1/+1
2017-09-28Only pull out local media that were for url cacheErik Johnston1-1/+1
2017-09-28Fix typo in url cache expiry timerErik Johnston1-1/+1
2017-09-28Support new and old style media id formatsErik Johnston1-31/+81
2017-09-28Fix typoErik Johnston1-3/+3
2017-09-28Change expires column to expires_tsErik Johnston3-10/+29
2017-09-28More bracketsErik Johnston1-1/+1
2017-09-28Delete expired url cache dataErik Johnston5-5/+208
2017-09-28Fix /joined_members