diff options
author | Mark Haines <mjark@negativecurvature.net> | 2015-01-28 17:19:28 +0000 |
---|---|---|
committer | Mark Haines <mjark@negativecurvature.net> | 2015-01-28 17:19:28 +0000 |
commit | 26c8fff19ebfca3914305f820b29897db8ea4fca (patch) | |
tree | c346408ce8f8ced5d1cb2e8dce4ea7fb934bb37e /synapse/storage/registration.py | |
parent | Merge branch 'master' into develop (diff) | |
parent | Rename ClientID to ClientInfo since it is a pair of IDs rather than a single ... (diff) | |
download | synapse-26c8fff19ebfca3914305f820b29897db8ea4fca.tar.xz |
Merge pull request #36 from matrix-org/device_id_from_access_token
Extract the device id and token id from the access token when autheniticating users
Diffstat (limited to 'synapse/storage/registration.py')
-rw-r--r-- | synapse/storage/registration.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/synapse/storage/registration.py b/synapse/storage/registration.py index 75dffa4db2..029b07cc66 100644 --- a/synapse/storage/registration.py +++ b/synapse/storage/registration.py @@ -122,7 +122,8 @@ class RegistrationStore(SQLBaseStore): def _query_for_auth(self, txn, token): sql = ( - "SELECT users.name, users.admin, access_tokens.device_id" + "SELECT users.name, users.admin," + " access_tokens.device_id, access_tokens.id as token_id" " FROM users" " INNER JOIN access_tokens on users.id = access_tokens.user_id" " WHERE token = ?" |