Bug 1132887: When starting a sudo session, the password is not validated

r=dkl a=glob


git-svn-id: svn://10.0.0.236/trunk@265812 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
bzrmirror%bugzilla.org 2015-02-17 20:46:42 +00:00
parent d4df00dc66
commit a4d1d44bd2
3 changed files with 5 additions and 2 deletions

View File

@ -1 +1 @@
9296 9297

View File

@ -1 +1 @@
9f76caa9e3493c2df055bed736463659770c0798 10aa3f02a861c50fc89867dfb04cab72de14922f

View File

@ -64,6 +64,9 @@ elsif ($action eq 'prepare-sudo') {
-httponly => 1, -httponly => 1,
%args); %args);
# The user ID must not be set when generating the token, because
# that information will not be available when validating it.
local Bugzilla->user->{userid} = 0;
$vars->{'login_request_token'} = issue_hash_token(['login_request', $value]); $vars->{'login_request_token'} = issue_hash_token(['login_request', $value]);
} }