Closed Bug 1422518 Opened 7 years ago Closed 7 years ago

Using meta refresh element with a target of "about:blank" no longer results in an empty address bar

Categories

(Firefox :: Tabbed Browser, defect)

58 Branch
defect
Not set
minor

Tracking

()

VERIFIED FIXED
Firefox 59
Tracking Status
firefox-esr52 --- unaffected
firefox57 --- unaffected
firefox58 + verified
firefox59 --- verified

People

(Reporter: u607479, Assigned: valentin)

References

Details

(Keywords: regression)

Attachments

(2 files)

Attached file blank-refresh.html
User Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64; rv:58.0) Gecko/20100101 Firefox/58.0
Build ID: 20171130160223

Steps to reproduce:

Open a document (such as the attached one) that uses a meta redirect element to redirect to the page about:blank. The attached document should refresh after three seconds.

mozregression bisection log: https://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=3599d43b43adf486ce3a5749329f3015d16daf4c&tochange=229546747cbf04cf71a235275d7c2eb2520a298b

Context: This is currently used in the Blank New Tab add-on ( https://addons.mozilla.org/firefox/addon/blank-new-tab/ ) to allow using about:blank as the new tab page, as opposed to including a "pseudo" blank page. Originally this was done to avoid bug 1372996 ( https://bugzilla.mozilla.org/show_bug.cgi?id=1372996 ), but I've continued to use the redirect even after that bug was fixed as it meant the identity box (with extension name) was not shown, giving a tidier look.


Actual results:

The string "about:blank" remains in the address bar after the refresh, with the address bar focused and the cursor positioned at the end of the string.


Expected results:

The address bar is empty and focused, showing only the placeholder text "Search or enter address".
Severity: normal → minor
Status: UNCONFIRMED → NEW
Has Regression Range: --- → yes
Has STR: --- → yes
Component: Untriaged → Tabbed Browser
Ever confirmed: true
Keywords: regression
Sorry, there's a small mistake in both the actual and expected results in my report - ignore the part about the address bar being focused. I originally wrote this regarding a new tab page set by an add-on, but then realised it occurred with a normal document too.
Blocks: 1414425
Flags: needinfo?(valentin.gosu)
I already had a fix for it. Will be landing shortly.
Flags: needinfo?(valentin.gosu)
Boris, I'm going to use this bug to land the LOAD_FLAGS_DISALLOW_INHERIT_PRINCIPAL change.
Assignee: nobody → valentin.gosu
Pushed by valentin.gosu@gmail.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/6f5aec4cde6f
Use LOAD_FLAGS_DISALLOW_INHERIT_PRINCIPAL for meta refresh r=bz
https://hg.mozilla.org/mozilla-central/rev/6f5aec4cde6f
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 59
Please request uplift to beta when you get a chance.
Comment on attachment 8934362 [details] [diff] [review]
Use LOAD_FLAGS_DISALLOW_INHERIT_PRINCIPAL for meta refresh

Approval Request Comment
[Feature/Bug causing the regression]: 
bug 1414425
[User impact if declined]:
Pages loaded from a meta redirect will have a different principal than expected.
[Is this code covered by automated tests?]:
Partly, but not this scenario. I will write a unit test.
[Has the fix been verified in Nightly?]:
Yes
[Needs manual test from QE? If yes, steps to reproduce]: 
Yes. Load attached test case. See comment 0
[List of other uplifts needed for the feature/fix]:
none
[Is the change risky?]:
no.
[Why is the change risky/not risky?]:
This is a small change that only makes the meta load not inherit the triggering principal (as before bug 1414425)
[String changes made/needed]:
none.
Attachment #8934362 - Flags: approval-mozilla-beta?
Comment on attachment 8934362 [details] [diff] [review]
Use LOAD_FLAGS_DISALLOW_INHERIT_PRINCIPAL for meta refresh

Fix a meta redirect regression issue. Beta58+.
Attachment #8934362 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Flags: qe-verify+
I managed to reproduce the bug using Nightly from 2017-12-02 on Windows 10 x64. The string "about:blank" remains in the address bar after the refresh.
I tested on latest Nightly 59 and beta 58.0b10 on Windows 10 x64, Mac OS X 10.11 and Ubuntu 16.04 x32, but the bug is not reproducing anymore.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: