[browser] Blank page when access to local URL (file://…) is denied

Bug #1503332 reported by Olivier Tilloy
16
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Oxide
Confirmed
Undecided
Unassigned
Ubuntu UX
Fix Committed
High
James Mulholland
webbrowser-app (Ubuntu)
Confirmed
High
Unassigned

Bug Description

Since version 0.23+15.10.20151005-0ubuntu1, webbrowser-app is running under apparmor confinement.
This means that access to the local filesystem is denied (file://… URLs). There is no user feedback when that happens other than a blank page, which is not really great UX. A user-friendly error message to inform that browsing the local filesystem is restricted would be better.

UX Comment:
As discussed and agreed during our regular sync-up:
"...Use the standard error page for this case, which should come for free once oxide reports a failed load."

Revision history for this message
Olivier Tilloy (osomon) wrote :

I had a quick look at how we can detect that access was denied, and it seems that the only difference with a normal load sequence (load started, load committed, load succeeded) is that the HTTP status code is always 0 for all events in the sequence.

A "load succeeded" event with an HTTP status code of 0 might be enough to indicate that access was denied, need to double check.

Revision history for this message
Chris Coulson (chrisccoulson) wrote :

It doesn't look like net::URLRequestFileJob does an access check or handles that condition. However, net::FileProtocolHandler delegates an access check to net::NetworkDelegate (via OnCanAccessFile), and it looks like that can be used to fail the load.

I'll give it a try

Revision history for this message
Chris Coulson (chrisccoulson) wrote :

Ignore that - this should result in a failed load already. I'll investigate what's going wrong

Revision history for this message
Olivier Tilloy (osomon) wrote :

Discussed the design side of things with James, and his guidance is to use the standard error page for this case, which should come for free once oxide reports a failed load.

summary: - Blank page when access to local URL (file://…) is denied
+ [browser] Blank page when access to local URL (file://…) is denied
Changed in ubuntu-ux:
status: New → Triaged
importance: Undecided → High
assignee: nobody → James Mulholland (jamesjosephmulholland)
description: updated
Changed in ubuntu-ux:
status: Triaged → Fix Committed
Bill Filler (bfiller)
Changed in webbrowser-app (Ubuntu):
status: New → Confirmed
Changed in oxide:
status: New → Confirmed
Changed in webbrowser-app (Ubuntu):
importance: Undecided → High
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.