Validate more fields around docshell load state
Categories
(Core :: IPC, enhancement)
Tracking
()
People
(Reporter: vhilla, Assigned: vhilla)
References
Details
Attachments
(3 external files, 1 obsolete file)
To follow-up on bug 2027207 validating principals, we can also add checks to load state.
| Assignee | ||
Comment 1•5 months ago
|
||
Updated•5 months ago
|
| Assignee | ||
Updated•5 months ago
|
Comment 4•5 months ago
|
||
Backed out for causing failures at browser_open_docgroup.js.
Backout link: https://hg.mozilla.org/integration/autoland/rev/65c5f5a151c2
| Assignee | ||
Comment 5•5 months ago
•
|
||
Looking at my try history, the tests passed previously which is confusing. What's failing is the check for mPartitionedPrincipalToInherit. I remember I had the same happen locally once but wasn't able to reproduce it consistently.
0:03.55 GECKO(39037) [MozDbg] [./../../../docshell/base/nsDocShellLoadState.cpp:193] mPartitionedPrincipalToInherit = nsIPrincipal { http://example.com^partitionKey=%28http%2Cexample.com%29 } @ 0x7a379b707dc0
0:03.56 GECKO(39037) [MozDbg] [./../../../docshell/base/nsDocShellLoadState.cpp:194] GetEffectiveTriggeringRemoteType() = "webIsolated=https://example.com"
0:03.56 GECKO(39037) [MozDbg] [./../../../docshell/base/nsDocShellLoadState.cpp:195] mPrincipalToInherit = nsIPrincipal { moz-nullprincipal:{041f6b76-256e-4969-b90a-576a1c9307f7}?http://example.com } @ 0x7a379c5f6300
Note PPTI is http while remote type is https. That seems like a bug, I'll try to figure out how the principals get out of sync. It gets fixed when changing example.com to https. Reminds me of bug 2003449.
Comment 7•4 months ago
|
||
| bugherder | ||
Updated•4 months ago
|
Updated•4 months ago
|
| Assignee | ||
Comment 8•3 months ago
|
||
Original Revision: https://phabricator.services.mozilla.com/D305101
Updated•3 months ago
|
Comment 9•3 months ago
|
||
firefox-beta Uplift Approval Request
- User impact if declined/Reason for urgency: Add more principal validation in 153.
- Code covered by automated testing?: yes
- Fix verified in Nightly?: yes
- Needs manual QE testing?: no
- Steps to reproduce for manual QE testing:
- Risk associated with taking this patch: medium
- Explanation of risk level: This adds some checks around loading and more edge cases like bug 2048851 might show up. The change has been in Nightly for a month, edge cases would likely be low severity.
- String changes made/needed?: No
- Is Android affected?: yes
Updated•3 months ago
|
Updated•3 months ago
|
| Assignee | ||
Comment 10•3 months ago
|
||
Original Revision: https://phabricator.services.mozilla.com/D305101
Updated•3 months ago
|
Comment 11•3 months ago
|
||
firefox-esr153 Uplift Approval Request
- User impact if declined/Reason for urgency: Add more principal validation in 153.
- Code covered by automated testing?: yes
- Fix verified in Nightly?: yes
- Needs manual QE testing?: no
- Steps to reproduce for manual QE testing: (enhancement)
- Risk associated with taking this patch: low
- Explanation of risk level: This adds some checks around loading that could cause crashes. But the change has been in Nightly for a month.
- String changes made/needed?: no
- Is Android affected?: yes
| Assignee | ||
Comment 12•3 months ago
|
||
Original Revision: https://phabricator.services.mozilla.com/D305101
Updated•3 months ago
|
Comment 13•3 months ago
|
||
firefox-esr140 Uplift Approval Request
- User impact if declined/Reason for urgency: Add more principal validation in 140.
- Code covered by automated testing?: yes
- Fix verified in Nightly?: yes
- Needs manual QE testing?: no
- Steps to reproduce for manual QE testing: (enhancement)
- Risk associated with taking this patch: low
- Explanation of risk level: This adds some checks around loading that could cause crashes. But the change has been in Nightly for a month.
- String changes made/needed?: No
- Is Android affected?: yes
Comment 14•3 months ago
•
|
||
:vhilla do we have to uplift the regression(bug 2048851) to esr153 as well?
Updated•3 months ago
|
Updated•3 months ago
|
Comment 15•3 months ago
|
||
| uplift | ||
| Assignee | ||
Comment 16•3 months ago
|
||
No, but thanks for checking. Bug 2048851 wasn't correct and I fixed that in bug 2054487, which was uplifted to esr153.
Comment 17•3 months ago
|
||
This is being backed out of esr140 for causing reftest failures.
Updated•3 months ago
|
Comment 18•3 months ago
|
||
| backout uplift | ||
Updated•3 months ago
|
Updated•3 months ago
|
Updated•3 months ago
|
Comment 19•3 months ago
|
||
| uplift | ||
| Assignee | ||
Comment 20•3 months ago
|
||
(In reply to Dianna Smith [:diannaS] from comment #17)
This is being backed out of esr140 for causing reftest failures.
That makes sense for this test. A chrome:// reftest is loaded with system principal in a web remote type and embeds an iframe. So we get a system principal to inherit. I looked around and in 153, bug 2011307 changed it so that chrome:// documents always load in the parent.
I'll see if we can slightly tweak the check.
Updated•3 months ago
|
| Assignee | ||
Comment 22•3 months ago
|
||
Sorry, I'm unsure what's the process when an uplift got backed out. The patch got r+, do you set approval-mozilla-esr140+ or should I land?
I tried pushing to try but lando says hg error in cmd so I was only able to test locally.
Comment 23•3 months ago
|
||
if you updated the revision i can reland it.
the process is you just let me know the fix is corrected, you will see a new 140+ from me.
Updated•3 months ago
|
Updated•3 months ago
|
Comment 24•3 months ago
|
||
| uplift | ||
Comment 25•3 months ago
|
||
| backout uplift | ||
Comment 26•3 months ago
|
||
Updated•3 months ago
|
Updated•3 months ago
|
Updated•3 months ago
|
| Assignee | ||
Comment 27•3 months ago
|
||
It's again due to bug 2011307, which removed the failing test. The subtest remote -> chrome via clickLink times out.
I had to git fetch hg::https://hg.mozilla.org/releases/mozilla-esr140 to be able to resolve the hg error in cmd lando errors.
Push to try with a fix looks good: https://treeherder.mozilla.org/jobs?repo=try&landoInstance=lando-prod-2025&landoCommitID=78041
| Assignee | ||
Comment 28•3 months ago
|
||
:diannaS, can you land again? I updated the patch to address the test failure.
Comment 29•3 months ago
|
||
We already built esr140 since we are in RC week. It will get picked up to land next week for the next cycle.
Updated•2 months ago
|
Updated•2 months ago
|
Comment 30•2 months ago
|
||
| uplift | ||
Updated•2 months ago
|
Updated•2 months ago
|
Description
•