diff options
author | Matthew Hodgson <matthew@matrix.org> | 2016-06-03 12:14:18 +0100 |
---|---|---|
committer | Matthew Hodgson <matthew@matrix.org> | 2016-06-03 12:14:18 +0100 |
commit | 8d740132f499b2c232716533ea786dfffacc1ec8 (patch) | |
tree | 5034a5aba0c6e604683080357ae6481803a4dea1 /synapse/handlers/auth.py | |
parent | brand the email from header (diff) | |
parent | Merge branch 'erikj/cache_perf' of github.com:matrix-org/synapse into develop (diff) | |
download | synapse-8d740132f499b2c232716533ea786dfffacc1ec8.tar.xz |
Merge branch 'develop' into matthew/brand-from-header
Diffstat (limited to 'synapse/handlers/auth.py')
-rw-r--r-- | synapse/handlers/auth.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/synapse/handlers/auth.py b/synapse/handlers/auth.py index 26c865e171..200793b5ed 100644 --- a/synapse/handlers/auth.py +++ b/synapse/handlers/auth.py @@ -529,6 +529,11 @@ class AuthHandler(BaseHandler): macaroon.add_first_party_caveat("time < %d" % (expiry,)) return macaroon.serialize() + def generate_delete_pusher_token(self, user_id): + macaroon = self._generate_base_macaroon(user_id) + macaroon.add_first_party_caveat("type = delete_pusher") + return macaroon.serialize() + def validate_short_term_login_token_and_get_user_id(self, login_token): try: macaroon = pymacaroons.Macaroon.deserialize(login_token) |