summaryrefslogtreecommitdiff
path: root/addons/auth_crypt
diff options
context:
space:
mode:
authorToufik Benjaa <tbe@odoo.com>2018-03-20 16:36:26 +0100
committerToufik Benjaa <tbe@odoo.com>2018-06-27 16:39:45 +0200
commit29c00a56daa377e40f4d28e86a10f105617fd243 (patch)
tree6c89ee53a4e1729a754b4df96bb6d60fd89cb5e8 /addons/auth_crypt
parentc1b6cfaab8d42885533e23985058cfc78b48d7c7 (diff)
[IMP] http: Sessions implicit deactivation
- Store a token inside sessions to allow implicit session deactivation when needed. backport of @da1f153d61d747d9357694382fe04f96c0ca886a @c8243e71c6da37547a19f61c58f25d5d03e13d38
Diffstat (limited to 'addons/auth_crypt')
-rw-r--r--addons/auth_crypt/auth_crypt.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/addons/auth_crypt/auth_crypt.py b/addons/auth_crypt/auth_crypt.py
index 7c9d0c5fa2c..c8ac4876a55 100644
--- a/addons/auth_crypt/auth_crypt.py
+++ b/addons/auth_crypt/auth_crypt.py
@@ -3,6 +3,7 @@ import logging
from passlib.context import CryptContext
import openerp
+from openerp import api
from openerp.osv import fields, osv
from openerp.addons.base.res import res_users
@@ -95,3 +96,7 @@ class res_users(osv.osv):
internally
"""
return default_crypt_context
+
+ @api.model
+ def _get_session_token_fields(self):
+ return super(res_users, self)._get_session_token_fields() | {'password_crypt'}