summary refs log tree commit diff
path: root/synapse/handlers/account_validity.py (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Merge remote-tracking branch 'gitlab/clokep/license-license' into new_developErik Johnston2023-12-131-10/+16
|\
| * Update license headersPatrick Cloke2023-11-211-10/+16
| |
* | ModuleAPI SSO auth callbacks (#15207)Andrew Yasinishyn2023-12-011-0/+16
|/ | | Signed-off-by: Andrii Yasynyshyn yasinishyn.a.n@gmail.com
* Convert user_get_threepids response to attrs. (#16468)Patrick Cloke2023-10-111-2/+2
| | | This improves type annotations by not having a dictionary of Any values.
* `N + 3`: Read from column `full_user_id` rather than `user_id` of tables ↵Shay2023-06-021-1/+1
| | | | `profiles` and `user_filters` (#15649)
* Move Account Validity callbacks to a dedicated file (#15237)Andrew Morgan2023-03-161-85/+14
|
* Implement cancellation support/protection for module callbacks (#12568)Sean Quah2022-05-091-1/+2
| | | | | | | | | | | | There's no guarantee that module callbacks will handle cancellation appropriately. Protect module callbacks with read semantics from cancellation and avoid swallowing `CancelledError`s that arise. Other module callbacks, such as the `on_*` callbacks, are presumed to live on code paths that involve writes and aren't cancellation-friendly. These module callbacks have been left alone. Signed-off-by: Sean Quah <seanq@element.io>
* Add some type hints to datastore (#12423)Dirk Klimpel2022-04-121-2/+2
| | | | | | | | | | | | | | | | | | | * Add some type hints to datastore * newsfile * change `Collection` to `List` * refactor return type of `select_users_txn` * correct type hint in `stream.py` * Remove `Optional` in `select_users_txn` * remove not needed return type in `__init__` * Revert change in `get_stream_id_for_event_txn` * Remove import from `Literal`
* Remove `HomeServer.get_datastore()` (#12031)Richard van der Hoff2022-02-231-1/+1
| | | | | | | The presence of this method was confusing, and mostly present for backwards compatibility. Let's get rid of it. Part of #11733
* Require direct references to configuration variables. (#10985)Patrick Cloke2021-10-061-6/+2
| | | | | | This removes the magic allowing accessing configurable variables directly from the config object. It is now required that a specific configuration class is used (e.g. `config.foo` must be replaced with `config.server.foo`).
* Use direct references for some configuration variables (part 3) (#10885)Patrick Cloke2021-09-231-1/+1
| | | | | | | | This avoids the overhead of searching through the various configuration classes by directly referencing the class that the attributes are in. It also improves type hints since mypy can now resolve the types of the configuration variables.
* Require type hints in the handlers module. (#10831)Patrick Cloke2021-09-201-2/+2
| | | | | | | Adds missing type hints to methods in the synapse.handlers module and requires all methods to have type hints there. This also removes the unused construct_auth_difference method from the FederationHandler.
* Use direct references for some configuration variables (#10798)Patrick Cloke2021-09-131-2/+2
| | | | Instead of proxying through the magic getter of the RootConfig object. This should be more performant (and is more explicit).
* Add types to synapse.util. (#10601)reivilibre2021-09-101-0/+1
|
* Add a module type for account validity (#9884)Brendan Abolivier2021-07-161-2/+126
| | | | | This adds an API for third-party plugin modules to implement account validity, so they can provide this feature instead of Synapse. The module implementing the current behaviour for this feature can be found at https://github.com/matrix-org/synapse-email-account-validity. To allow for a smooth transition between the current feature and the new module, hooks have been added to the existing account validity endpoints to allow their behaviours to be overridden by a module.
* Split multiplart email sending into a dedicated handler (#9977)Brendan Abolivier2021-05-171-45/+10
| | | Co-authored-by: Andrew Morgan <1342360+anoadragon453@users.noreply.github.com>
* Port "Allow users to click account renewal links multiple times without ↵Andrew Morgan2021-04-191-24/+77
| | | | | hitting an 'Invalid Token' page #74" from synapse-dinsic (#9832) This attempts to be a direct port of https://github.com/matrix-org/synapse-dinsic/pull/74 to mainline. There was some fiddling required to deal with the changes that have been made to mainline since (mainly dealing with the split of `RegistrationWorkerStore` from `RegistrationStore`, and the changes made to `self.make_request` in test code).
* Remove redundant "coding: utf-8" lines (#9786)Jonathan de Jong2021-04-141-1/+0
| | | | | | | Part of #9744 Removes all redundant `# -*- coding: utf-8 -*-` lines from files, as python 3 automatically reads source code as utf-8 now. `Signed-off-by: Jonathan de Jong <jonathan@automatia.nl>`
* Update mypy configuration: `no_implicit_optional = True` (#9742)Jonathan de Jong2021-04-051-2/+5
|
* Import HomeServer from the proper module. (#9665)Patrick Cloke2021-03-231-1/+1
|
* Add type hints for account validity handler (#8620)Patrick Cloke2020-10-261-6/+23
| | | This also fixes a bug by fixing handling of an account which doesn't expire.
* Consistently use wrap_as_background_task in more places (#8599)Patrick Cloke2020-10-201-9/+3
|
* Move additional tasks to the background worker, part 4 (#8513)Patrick Cloke2020-10-131-1/+2
|
* Stop sub-classing object (#8249)Patrick Cloke2020-09-041-1/+1
|
* Use the default templates when a custom template file cannot be found (#8037)Andrew Morgan2020-08-171-17/+3
| | | Fixes https://github.com/matrix-org/synapse/issues/6583
* Fix buggy condition in account validity handler (#7074)Brendan Abolivier2020-03-161-1/+5
|
* Port handlers.account_validity to async/await.Erik Johnston2019-12-101-46/+40
|
* Allow Synapse to send registration emails + choose Synapse or an external ↵Andrew Morgan2019-09-061-3/+9
| | | | | | | | | | | | | | | | server to handle 3pid validation (#5987) This is a combination of a few different PRs, finally all being merged into `develop`: * #5875 * #5876 * #5868 (This one added the `/versions` flag but the flag itself was actually [backed out](https://github.com/matrix-org/synapse/commit/891afb57cbdf9867f2848341b29c75d6f35eef5a#diff-e591d42d30690ffb79f63bb726200891) in #5969. What's left is just giving /versions access to the config file, which could be useful in the future) * #5835 * #5969 * #5940 Clients should not actually use the new registration functionality until https://github.com/matrix-org/synapse/pull/5972 is merged. UPGRADE.rst, changelog entries and config file changes should all be reviewed closely before this PR is merged.
* Allow defining HTML templates to serve the user on account renewalBrendan Abolivier2019-08-011-1/+9
|
* Replace returnValue with return (#5736)Amber Brown2019-07-231-3/+3
|
* Move logging utilities out of the side drawer of util/ and into logging/ (#5606)Amber Brown2019-07-041-1/+1
|
* Fix a number of "Starting txn from sentinel context" warnings (#5605)Richard van der Hoff2019-07-031-1/+9
| | | | Fixes #5602, #5603
* Run Black. (#5482)Amber Brown2019-06-201-34/+27
|
* Don't send renewal emails to deactivated usersBrendan Abolivier2019-06-141-0/+3
|
* Add management endpoints for account validityBrendan Abolivier2019-04-171-4/+29
|
* Send out emails with links to extend an account's validity periodBrendan Abolivier2019-04-171-0/+228