Instant Search doesn't work when not logged in

RESOLVED FIXED

Status

()

defect
RESOLVED FIXED
a year ago
a year ago

People

(Reporter: mozilla, Assigned: mozilla)

Tracking

Production

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

PR
45 bytes, text/x-github-pull-request
dylan
: review+
Details | Review
(Assignee)

Description

a year ago
https://bugzilla.mozilla.org/query.cgi?format=instant always shows "No matching bugs found." when doing a search while not logged in.

The response text actually masks a JSON-RPC error (auth_invalid_token).

This seems to occur because JSON-RPC expects that all requests are authenticated, so, either JSON-RPC needs to learn to handle some requests unauthenticated, or the instant search page should invite users to log in before searching.
(Assignee)

Comment 1

a year ago
> This seems to occur because JSON-RPC expects that all requests are authenticated

Well, this is wrong, because Bugzilla.time works from curl, so for some reason unauthenticated Bugzilla.time works but unauthenticated instant search doesn't. (Maybe because the latter is via POST?)
(Assignee)

Comment 2

a year ago
The problem is that the instant search JavaScript passes a blank Bugzilla_api_token to jsonrpc.cgi. This token seems to override other forms of authentication, and because it is invalid, fail the entire request.
Assignee: nobody → mozilla
Posted file PR
very good catch, thanks a lot!
Attachment #8964652 - Flags: review+
Status: UNCONFIRMED → RESOLVED
Last Resolved: a year ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.