Closed
Bug 1136002
Opened 11 years ago
Closed 11 years ago
[email] try/catch around cookie cache decoding for extra protection
Categories
(Firefox OS Graveyard :: Gaia::E-Mail, defect)
Tracking
(b2g-v2.2 fixed, b2g-master fixed)
RESOLVED
FIXED
2.2 S7 (6mar)
People
(Reporter: jrburke, Assigned: jrburke)
Details
Attachments
(1 external file)
Bug 1124426 improved the discarding the cookie cache if it got too big for an extreme reason. However, looking more at the code, asuth suggested a try/catch around the decodeURIComponent if by some really really extreme reason the cache fits in the expected size but is corrupt for some reason.
Comment 1•11 years ago
|
||
| Assignee | ||
Comment 2•11 years ago
|
||
Comment on attachment 8568371 [details] [review]
[gaia] jrburke:bug1136002-email-trycatch-cache > mozilla-b2g:master
Tested on device by manually adding '%r%r to the beginning of the string passed to decodeURIComponent, and app continued to launch and work, just printing an error in the log. Then removed the manual hack and confirmed the cache still works as before.
Attachment #8568371 -
Flags: review?(bugmail)
Updated•11 years ago
|
Attachment #8568371 -
Flags: review?(bugmail) → review+
| Assignee | ||
Updated•11 years ago
|
Keywords: checkin-needed
Updated•11 years ago
|
Keywords: checkin-needed
Comment 3•11 years ago
|
||
Pull request has landed in master: https://github.com/mozilla-b2g/gaia/commit/df2ab77305a796704a9a0ac45f4f6407fda6ce97
Updated•11 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
| Assignee | ||
Comment 4•11 years ago
|
||
Comment on attachment 8568371 [details] [review]
[gaia] jrburke:bug1136002-email-trycatch-cache > mozilla-b2g:master
[Approval Request Comment]
[Bug caused by] (feature/regressing bug #):
This is more of a follow-up to bug 1124426, which did most of the improvements. This adds some extra security that we will keep going if what is saved is somehow corrupt.
[User impact] if declined:
If the cookie cache fails for decoding purposes, the screen will be blank.
[Testing completed]:
On device, manually triggering cases where it activates.
[Risk to taking this patch] (and alternatives if risky):
Close to zero, it adds a try/catch so should be less risky than the previous code.
[String changes made]:
none
Attachment #8568371 -
Flags: approval-gaia-v2.2?
Updated•11 years ago
|
Attachment #8568371 -
Flags: approval-gaia-v2.2? → approval-gaia-v2.2+
Comment 5•11 years ago
|
||
You need to log in
before you can comment on or make changes to this bug.
Description
•