summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrédéric Buclin <LpSolit@gmail.com>2014-01-27 19:13:50 +0100
committerFrédéric Buclin <LpSolit@gmail.com>2014-01-27 19:13:50 +0100
commit0bd5bfb9b40bd81c546e7ae7a0a9ab281f308709 (patch)
treef45c25a2a345ba7f462a8ce2f44e3bc5527f3f4c
parent4f5dacee63a55d07309b82bf0404469d0aa49842 (diff)
downloadbugzilla-0bd5bfb9b40bd81c546e7ae7a0a9ab281f308709.tar.gz
bugzilla-0bd5bfb9b40bd81c546e7ae7a0a9ab281f308709.tar.xz
Bug 964113: Digest::SHA 5.82 and newer always croak on wide characters, preventing saved searched from being displayed
r=dkl a=justdave
-rw-r--r--Bugzilla/Token.pm4
-rw-r--r--template/en/default/pages/release-notes.html.tmpl3
2 files changed, 7 insertions, 0 deletions
diff --git a/Bugzilla/Token.pm b/Bugzilla/Token.pm
index 9ebf9c652..74f780542 100644
--- a/Bugzilla/Token.pm
+++ b/Bugzilla/Token.pm
@@ -168,6 +168,10 @@ sub issue_hash_token {
my @args = ($time, $user_id, @$data);
my $token = join('*', @args);
+ # Wide characters cause Digest::SHA to die.
+ if (Bugzilla->params->{'utf8'}) {
+ utf8::encode($token) if utf8::is_utf8($token);
+ }
$token = hmac_sha256_base64($token, Bugzilla->localconfig->{'site_wide_secret'});
$token =~ s/\+/-/g;
$token =~ s/\//_/g;
diff --git a/template/en/default/pages/release-notes.html.tmpl b/template/en/default/pages/release-notes.html.tmpl
index ef6090c41..f214bda0a 100644
--- a/template/en/default/pages/release-notes.html.tmpl
+++ b/template/en/default/pages/release-notes.html.tmpl
@@ -61,6 +61,9 @@
<li>An error about <kbd>longdescs.comment_id</kbd> was thrown by MySQL 5.0
and 5.1 when upgrading to Bugzilla 4.4 or 4.4.1.
(<a href="https://bugzilla.mozilla.org/show_bug.cgi?id=870369">[% terms.Bug %] 870369</a>)</li>
+ <li>Saved searches containing Unicode characters in their name could not
+ be run if Digest::SHA 5.82 or newer is installed.
+ (<a href="https://bugzilla.mozilla.org/show_bug.cgi?id=964113">[% terms.Bug %] 964113</a>)</li>
<li>A regression in Bugzilla 4.4.1 caused <kbd>email_in.pl</kbd> to fail
with an "invalid token" error message.
(<a href="https://bugzilla.mozilla.org/show_bug.cgi?id=928331">[% terms.Bug %] 928331</a> and