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
=== modified file 'bin/addons/base/res/res_user.py'
--- bin/addons/base/res/res_user.py 2017-10-27 14:33:37 +0000
+++ bin/addons/base/res/res_user.py 2018-03-28 07:26:42 +0000
@@ -920,6 +920,7 @@
920 if new_passwd:920 if new_passwd:
921 cr = pooler.get_db(db_name).cursor()921 cr = pooler.get_db(db_name).cursor()
922 try:922 try:
923 login = tools.ustr(login).lower()
923 # get user_uid924 # get user_uid
924 cr.execute("""SELECT id from res_users925 cr.execute("""SELECT id from res_users
925 WHERE login=%s AND active=%s""",926 WHERE login=%s AND active=%s""",
926927
=== modified file 'bin/service/security.py'
--- bin/service/security.py 2017-09-08 15:57:28 +0000
+++ bin/service/security.py 2018-03-28 07:26:42 +0000
@@ -94,10 +94,11 @@
94 raise Exception("ServerUpdate: Server is updating modules ...")94 raise Exception("ServerUpdate: Server is updating modules ...")
9595
96 pool = pooler.get_pool(db_name)96 pool = pooler.get_pool(db_name)
97 lower_login = tools.ustr(login).lower()
97 # check if the user have to change his password98 # check if the user have to change his password
98 cr.execute("""SELECT force_password_change99 cr.execute("""SELECT force_password_change
99 FROM res_users100 FROM res_users
100 WHERE login=%s""", (login,))101 WHERE login=%s""", (lower_login,))
101 force_password = [x[0] for x in cr.fetchall()]102 force_password = [x[0] for x in cr.fetchall()]
102 if any(force_password):103 if any(force_password):
103 raise Exception("ForcePasswordChange: The admin requests your password change ...")104 raise Exception("ForcePasswordChange: The admin requests your password change ...")

Subscribers

People subscribed via source and target branches