Closed
Bug 901720
Opened 12 years ago
Closed 12 years ago
Report index hit with invalid crash IDs in the URL that don't 400
Categories
(Socorro :: Webapp, task)
Socorro
Webapp
Tracking
(Not tracked)
VERIFIED
FIXED
56
People
(Reporter: peterbe, Assigned: peterbe)
Details
This for example
https://errormill.mozilla.org/webtools/socorro-crashstats-prod/group/34593/
hits us with the URL
https://crash-stats.mozilla.com/report/index/f48e9617-652a-11dd-a35a-001a4bd43ed6
which is not valid because the last 6 characters aren't reducible to a date.
Arguably we should just reject such URLs and immediately respond with a 404.
Assignee | ||
Comment 1•12 years ago
|
||
Does anybody know why we're getting URLs like this? (see above)
Are we doing the right thing to outright reject them because they don't have a date part in the last 6 characters.
Assignee: nobody → peterbe
Status: NEW → ASSIGNED
Comment 2•12 years ago
|
||
I can only imagine these are from people copying and pasting the UUIDs of unsubmitted crashes from about:crashes into the search box. It should be fine to just 404 on any Crash ID that doesn't end in \d{6}.
Assignee | ||
Comment 3•12 years ago
|
||
Comment 4•12 years ago
|
||
Commit pushed to master at https://github.com/mozilla/socorro
https://github.com/mozilla/socorro/commit/fa3d54b4aecc9329ddda765b1f57bb6cebfdd044
fixes bug 901720 - Report index with invalid crash IDs 404, r=rhelmer
Updated•12 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Comment 6•12 years ago
|
||
Reopening:
As I understand, invalid crash ids should return 404s. On dev and stage I am seeing HTTP 400.
-- dev
[11:11:14.643] GET https://crash-stats-dev.allizom.org/report/index/f48e9617-652a-11dd-a35a-001a4bd43ed6 [HTTP/1.1 400 BAD REQUEST 679ms]
-- stage
[11:13:00.557] GET https://crash-stats.allizom.org/report/index/f48e9617-652a-11dd-a35a-001a4bd43ed6 [HTTP/1.1 400 BAD REQUEST 557ms]
-- prod
[11:13:16.947] GET https://crash-stats.mozilla.com/report/index/f48e9617-652a-11dd-a35a-001a4bd43ed6 [HTTP/1.1 500 INTERNAL SERVER ERROR 1294ms]
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee | ||
Comment 7•12 years ago
|
||
My bad. The correct response should be 400. NOT 404.
A URL like /report/index/f48e9617-652a-11dd-a35a-001a4bd43ed6 matches the URL conf but once the view function kicks in it checks the validity of the crash ID and if it's bogus it returns a 400.
Comment 8•12 years ago
|
||
(In reply to Peter Bengtsson [:peterbe] from comment #7)
> My bad. The correct response should be 400. NOT 404.
No worries peterbe, thanks for the clarification. Bumping back to resolved fixed per your comment.
Status: REOPENED → RESOLVED
Closed: 12 years ago → 12 years ago
OS: Mac OS X → All
Hardware: x86 → All
Resolution: --- → FIXED
Comment 9•12 years ago
|
||
QA verified per the /new/ spec in comment 7.
Verified in comment 6:
-- dev
[11:11:14.643] GET https://crash-stats-dev.allizom.org/report/index/f48e9617-652a-11dd-a35a-001a4bd43ed6 [HTTP/1.1 400 BAD REQUEST 679ms]
-- stage
[11:13:00.557] GET https://crash-stats.allizom.org/report/index/f48e9617-652a-11dd-a35a-001a4bd43ed6 [HTTP/1.1 400 BAD REQUEST 557ms]
-- prod
[11:13:16.947] GET https://crash-stats.mozilla.com/report/index/f48e9617-652a-11dd-a35a-001a4bd43ed6 [HTTP/1.1 500 INTERNAL SERVER ERROR 1294ms]
Status: RESOLVED → VERIFIED
Summary: Report index hit with invalid crash IDs in the URL that don't 404 → Report index hit with invalid crash IDs in the URL that don't 400
You need to log in
before you can comment on or make changes to this bug.
Description
•