Open
Bug 1281183
Opened 10 years ago
Updated 3 years ago
Remove Notification PB Flags
Categories
(Core :: DOM: Core & HTML, defect, P3)
Core
DOM: Core & HTML
Tracking
()
NEW
People
(Reporter: jandreou25, Unassigned)
References
(Blocks 2 open bugs)
Details
(Whiteboard: btpp-active)
Attachments
(1 file)
|
32.51 KB,
patch
|
jdm
:
feedback+
|
Details | Diff | Splinter Review |
Removing the old private browsing flags being passed around the alert notification system and use the value from Origin Attributes.
Updated•10 years ago
|
Whiteboard: btpp-active
| Reporter | ||
Comment 1•10 years ago
|
||
Attachment #8764018 -
Flags: review?(josh)
Comment 2•10 years ago
|
||
Comment on attachment 8764018 [details] [diff] [review]
Bug1281183.patch
Review of attachment 8764018 [details] [diff] [review]:
-----------------------------------------------------------------
These changes generally make sense. I'm concerned about modifying public interfaces and compatibility with old download databases, however.
::: toolkit/components/alerts/nsIAlertsService.idl
@@ +26,4 @@
> [optional] in AString dir,
> [optional] in AString lang,
> [optional] in AString data,
> + [optional] in nsIPrincipal principal);
Note to self: we need to check whether these interfaces are used by addons before landing this change. That requires bug 1280948 to be fixed.
::: toolkit/components/downloads/nsDownloadManager.cpp
@@ +1267,5 @@
> }
>
> + nsCString originSuffix;
> + stmt->GetUTF8String(i++, originSuffix);
> + dl->mPrincipal = mozilla::BasePrincipal::CreateCodebasePrincipal(originSuffix);
What happens when opening up a DB from a version of Gecko before this change?
@@ +1631,5 @@
> (void)aMIMEInfo->GetPreferredAction(&action);
> }
>
> + nsAutoCString originSuffix;
> + rv = aPrincipal->GetOrigin(originSuffix);
The naming here doesn't match what we're actually getting - we're grabbing a full origin + suffix from the principal, but the names imply that we're only storing the suffix.
::: uriloader/base/nsITransfer.idl
@@ +60,5 @@
> in PRTime startTime,
> in nsIFile aTempFile,
> in nsICancelable aCancelable,
> + in boolean aIsPrivate,
> + in nsIPrincipal aPrincipal);
Note to self: check whether this interface is used by addons.
::: widget/cocoa/OSXNotificationCenter.mm
@@ +400,1 @@
> : imgLoader::NormalLoader();
nit: align this with the ?
Attachment #8764018 -
Flags: review?(josh) → feedback+
| Reporter | ||
Updated•10 years ago
|
Assignee: jandreou25 → nobody
Comment 3•9 years ago
|
||
Michael, can you please help drive this to the finish line? Thanks!
Flags: needinfo?(michael)
Comment 4•9 years ago
|
||
I just completed a security inspection of the proposed patch and it looks correct. I even audited the custom serialization protocol for the AlertNotificationType. The switch from private browsing flag to origin attributes looks clean to me.
Comment 5•9 years ago
|
||
One more note: the parent side code used to always grab the private browsing flag from the parent-side doc rather than trust the value from the child. that code was replaced with code that grabbed the principal from the parent-side doc instead of trusting the value from the child.
Comment 6•9 years ago
|
||
Tanvi, I went through this code looking for places to add assertions but it has been completely converted to origin attributes and as I stated in comment 4 and comment 5, the parent-side origin attributes are taking from the window doc instead of the IPC messages so the enforcement appears to be correct for me. I couldn't see any obvious places to put assertions that would ensure that booleans and the origin attributes are matching since the conversion to origin attributes is complete in this part of the code.
Flags: needinfo?(tanvi)
Comment 7•9 years ago
|
||
Okay, so sounds like this bug doesn't need an assertion because both the previous boolean and the new way of getting private browsing are both coming from the loadcontext OAs.
Flags: needinfo?(tanvi)
Comment 8•9 years ago
|
||
Tanvi, to be clear, we agree, no assertions need to be added. This patch is fine by me.
Updated•9 years ago
|
Priority: -- → P1
Comment 9•9 years ago
|
||
I don't think I will be able to get around to this anytime soon.
Flags: needinfo?(michael)
Comment 10•9 years ago
|
||
Maybe baku wants to take this at some point (I'll ask him). I'm going to mark this as P2 since it's not a super-immediate-going-to-happen-this-cycle piece of work.
Updated•8 years ago
|
Priority: P1 → P2
Comment 11•7 years ago
|
||
Moving to p3 because no activity for at least 1 year(s).
See https://github.com/mozilla/bug-handling/blob/master/policy/triage-bugzilla.md#how-do-you-triage for more information
Priority: P2 → P3
| Assignee | ||
Updated•7 years ago
|
Component: DOM → DOM: Core & HTML
Updated•3 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•