Merge lp:~jfb-tempo-consulting/unifield-server/US-4414 into lp:unifield-server

Proposed by jftempo
Status: Merged
Merged at revision: 4840
Proposed branch: lp:~jfb-tempo-consulting/unifield-server/US-4414
Merge into: lp:unifield-server
Diff against target: 28 lines (+3/-1)
2 files modified
bin/addons/base/res/res_user.py (+1/-0)
bin/service/security.py (+2/-1)
To merge this branch: bzr merge lp:~jfb-tempo-consulting/unifield-server/US-4414
Reviewer Review Type Date Requested Status
UniField Reviewer Team Pending
Review via email: mp+342267@code.launchpad.net
To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'bin/addons/base/res/res_user.py'
2--- bin/addons/base/res/res_user.py 2017-10-27 14:33:37 +0000
3+++ bin/addons/base/res/res_user.py 2018-03-28 07:26:42 +0000
4@@ -920,6 +920,7 @@
5 if new_passwd:
6 cr = pooler.get_db(db_name).cursor()
7 try:
8+ login = tools.ustr(login).lower()
9 # get user_uid
10 cr.execute("""SELECT id from res_users
11 WHERE login=%s AND active=%s""",
12
13=== modified file 'bin/service/security.py'
14--- bin/service/security.py 2017-09-08 15:57:28 +0000
15+++ bin/service/security.py 2018-03-28 07:26:42 +0000
16@@ -94,10 +94,11 @@
17 raise Exception("ServerUpdate: Server is updating modules ...")
18
19 pool = pooler.get_pool(db_name)
20+ lower_login = tools.ustr(login).lower()
21 # check if the user have to change his password
22 cr.execute("""SELECT force_password_change
23 FROM res_users
24- WHERE login=%s""", (login,))
25+ WHERE login=%s""", (lower_login,))
26 force_password = [x[0] for x in cr.fetchall()]
27 if any(force_password):
28 raise Exception("ForcePasswordChange: The admin requests your password change ...")

Subscribers

People subscribed via source and target branches