New issue
Advanced search Search tips

Issue 740547 link

Starred by 2 users

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows , Mac
Pri: 3
Type: Bug
Team-Security-UX



Sign in to add a comment

PageInfo doesn't open on some about:blank tabs

Project Member Reported by elawrence@chromium.org, Jul 10 2017

Issue description

Chrome Version: 60.3112, 61.3153
OS: Mac and Windows at least

What steps will reproduce the problem?
(1) Visit https://bayden.com/test/data.htm#
(2) Click Try It link at the bottom of the page
(3) Click the Security Icon

What is the expected result? PageInfo opens

What happens instead? Page info icon shows activation but no page info bubble appears
 
NoPageInfoBubble.png
17.8 KB View Download
This repros at least as far back as Version 50.0.2628.0, so it's not a recent regression.

Summary: PageInfo doesn't open on some about:blank tabs (was: PageInfo doesn't open on some about:blank URLs)
This is pretty funny.

 // Works.
 var a= window.open("about:blank");
 // Fails.
 var a= window.open("");

This fails inside browser_commands.cc's ShowPageInfo function:

bool ShowPageInfo(Browser* browser, content::WebContents* web_contents) {
  content::NavigationEntry* entry =
      web_contents->GetController().GetVisibleEntry();
  if (!entry) {
    return false;
  }

That, in turn, fails because GetVisibleEntry() returns null because GetLastCommittedEntry() returns null in the case where the window.open went to an empty string rather than about:blank.

Comment 3 by creis@chromium.org, Jul 10 2017

Cc: creis@chromium.org
Components: UI>Browser>Navigation
Interesting.  It's probably worth updating ShowPageInfo to handle this case, but I'll also mention that I have some long term plans to make sure there's a NavigationEntry for the initial empty page in issue 524208.  (I tried a while ago, and I ran into too many odd tests and dependencies at the time.  I'll probably give it a try again in the future.)
Cc: mea...@chromium.org
Labels: -Pri-2 Pri-3
Status: Available (was: Untriaged)
I'll mark this as low-priority for now.

Happy to reprioritize if there are security inplications.

Comment 5 by mea...@chromium.org, Jul 10 2017

This is  issue 547982 .
Re #5: It's certainly related, in that it's another example of a downstream consequence of Issue 524208. To me, the surprising part of this is that window.open("") and window.open("about:blank") aren't being handled in exactly the same way.

Comment 7 by est...@chromium.org, Nov 10 2017

Labels: Hotlist-EnamelAndFriendsFixIt

Comment 8 by est...@chromium.org, Feb 18 2018

Labels: -Hotlist-EnamelAndFriendsFixIt

Sign in to add a comment