summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Bugzilla/User.pm8
1 files changed, 8 insertions, 0 deletions
diff --git a/Bugzilla/User.pm b/Bugzilla/User.pm
index 87255b20a..9fa7458e7 100644
--- a/Bugzilla/User.pm
+++ b/Bugzilla/User.pm
@@ -883,6 +883,14 @@ sub visible_bugs {
if (@check_ids) {
my $dbh = Bugzilla->dbh;
my $user_id = $self->id;
+
+ foreach my $id (@check_ids) {
+ my $orig_id = $id;
+ detaint_natural($id)
+ || ThrowCodeError('param_must_be_numeric', { param => $orig_id,
+ function => 'Bugzilla::User->visible_bugs'});
+ }
+
my $sth;
# Speed up the can_see_bug case.
if (scalar(@check_ids) == 1) {