diff options
author | Richard van der Hoff <richard@matrix.org> | 2017-10-31 15:15:51 +0000 |
---|---|---|
committer | Richard van der Hoff <richard@matrix.org> | 2017-11-01 16:51:03 +0000 |
commit | 4c8f94ac9433753464c4d8379aae650c3129500d (patch) | |
tree | 228d1c3f47728b8f8f8fbfe4f15090f5abeb04d9 /docs | |
parent | Merge pull request #2620 from matrix-org/rav/auth_non_password (diff) | |
download | synapse-4c8f94ac9433753464c4d8379aae650c3129500d.tar.xz |
Allow password_auth_providers to return a callback
... so that they have a way to record access tokens.
Diffstat (limited to 'docs')
-rw-r--r-- | docs/password_auth_providers.rst | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/docs/password_auth_providers.rst b/docs/password_auth_providers.rst index 2dbebcd72c..4ae4aeb53f 100644 --- a/docs/password_auth_providers.rst +++ b/docs/password_auth_providers.rst @@ -70,6 +70,11 @@ Password auth provider classes may optionally provide the following methods. the canonical ``@localpart:domain`` user id if authentication is successful, and ``None`` if not. + Alternatively, the ``Deferred`` can resolve to a ``(str, func)`` tuple, in + which case the second field is a callback which will be called with the + result from the ``/login`` call (including ``access_token``, ``device_id``, + etc.) + ``someprovider.check_password``\(*user_id*, *password*) This method provides a simpler interface than ``get_supported_login_types`` |