[k] KeyError by changing the a= parameter to value a (expects an int, looks like?)

VERIFIED FIXED in 2.1

Status

VERIFIED FIXED
9 years ago
9 years ago

People

(Reporter: stephend, Assigned: jgross)

Tracking

unspecified

Firefox Tracking Flags

(Not tracked)

Details

(URL)

(Reporter)

Description

9 years ago
https://support-stage-new.mozilla.com/en-US/search?w=1&a=a&tags=upgrade&language=en-US&category=1&category=3&category=7&category=8&category=11&category=14&category=15&category=17&category=18&category=19&category=20&category=23&category=24&category=25&q=*Finding+your+Firefox gives me a KeyError:

Traceback (most recent call last):

  File "/data/virtualenvs/kitsune/src/django/django/core/handlers/base.py", line 101, in get_response
    response = callback(request, *callback_args, **callback_kwargs)

  File "/data/www/support-stage-new.mozilla.com/kitsune/apps/search/views.py", line 159, in search
    if not search_form.is_valid() or a == '2':

  File "/data/virtualenvs/kitsune/src/django/django/forms/forms.py", line 120, in is_valid
    return self.is_bound and not bool(self.errors)

  File "/data/virtualenvs/kitsune/src/django/django/forms/forms.py", line 111, in _get_errors
    self.full_clean()

  File "/data/virtualenvs/kitsune/src/django/django/forms/forms.py", line 267, in full_clean
    self._clean_form()

  File "/data/virtualenvs/kitsune/src/django/django/forms/forms.py", line 294, in _clean_form
    self.cleaned_data = self.clean()

  File "/data/www/support-stage-new.mozilla.com/kitsune/apps/search/views.py", line 40, in clean
    if not cleaned_data['a'] and cleaned_data['q'] == '':

KeyError: 'a'
(Reporter)

Comment 1

9 years ago
Not a security bug, I don't think (the stack isn't displayed to the user), but thanks, Michael, for helping us hone our testing by finding bugs like this :-)
Whiteboard: [good first bug]
(Reporter)

Updated

9 years ago
Target Milestone: --- → 2.1
Assignee: nobody → jgross
(Assignee)

Comment 2

9 years ago
http://github.com/jsocol/kitsune/commit/a969959e237afca211503a956a370bf2ef89d7d6
Status: NEW → RESOLVED
Last Resolved: 9 years ago
Resolution: --- → FIXED
Whiteboard: [good first bug]
You need to log in before you can comment on or make changes to this bug.