Bug 158192 - firefox fails to open file:// url when already running
firefox fails to open file:// url when already running
Product: Fedora
Classification: Fedora
Component: firefox (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Gecko Maintainer
Depends On:
  Show dependency treegraph
Reported: 2005-05-19 10:29 EDT by aeb
Modified: 2007-12-20 11:46 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2007-12-20 11:46:35 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
shell script running firefox (5.59 KB, text/plain)
2007-07-31 08:44 EDT, Matěj Cepl
no flags Details

  None (edit)
Description aeb 2005-05-19 10:29:08 EDT
Description of problem:

With a firefox running on machine A, and remotely logged into machine B
with display redirected to machine A, the command (on machine B)
"firefox file:///somefile" fails with the error popup
"The file /somefile cannot be found. Please check the location and try again."
The cause is that the firefox on machine B checks whether firefox is already
running, and answers that question affirmatively - that is, it finds the firefox
on machine A. Now it forwards requests to this already running firefox, but of
course, files on B are not the same as files on A.
This is a bug - conceivably a security risk.

I fixed it for myself with
--- /usr/bin/firefox-orig       2004-10-20 09:41:37.000000000 +0200
+++ /usr/bin/firefox    2005-05-19 15:11:50.143956840 +0200
@@ -204,6 +204,7 @@
       open_compose ${1+"$@"}
   -*) ;;
+  file://*) ;;
   *) USE_EXIST=1 ;;

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
Actual results:

Expected results:

Additional info:
Comment 1 Matthew Miller 2006-07-10 16:13:01 EDT
Fedora Core 3 is now maintained by the Fedora Legacy project for security
updates only. If this problem is a security issue, please reopen and
reassign to the Fedora Legacy product. If it is not a security issue and
hasn't been resolved in the current FC5 updates or in the FC6 test
release, reopen and change the version to match.

Thank you!
Comment 2 Matěj Cepl 2007-07-18 13:22:30 EDT
Distribution against which this bug was reported is no longer supported; could
you please reproduce this with the updated version of the currently supported
distribution (Fedora Core 6, or Fedora 7, or Rawhide)? If this issue turns out
to still be reproducible, please let us know in this bug report.  If after a
month's time we have not heard back from you, we will have to close this bug as

Setting status to NEEDINFO, and awaiting information from the reporter.

Thanks in advance.
Comment 3 aeb 2007-07-31 06:49:39 EDT
I do not currently use a version of FC, but if someone mails me a copy of the
shell script /usr/bin/firefox, it will be very easy to check whether it still
has the same bug in the handling of ALREADY_RUNNING and USE_EXIST.
Comment 4 Matěj Cepl 2007-07-31 08:44:48 EDT
Created attachment 160311 [details]
shell script running firefox

What do you think?
Comment 5 aeb 2007-07-31 09:04:56 EDT
Precisely the same bug as before.
The script says

# If there's a command line argument but it doesn't begin with a -
# it's probably a url.  Try to send it to a running instance.

but forgets that that running instance may be on a different machine,
namely on the machine that $DISPLAY point to.
Of course a file:// url will have a different meaning on a different machine.

So, either file:// urls have to be excepted, or the logic must first figure out
whether "already running" means running on the same host.
Comment 6 Matěj Cepl 2007-12-20 11:46:35 EST
We just updated the Firefox version in Fedora/development from 2.0 to a 3.0
pre-release version, which improves performance, memory usage, and fixes many
bugs and crashes.

Closing as CANTFIX since we aren't fixing bugs filed against 2.0 now that 3.0 is
in.  If this bug is still present in rawhide using a Firefox 3.0 version, please
re-open this bug.

Thanks and Happy Holidays

Note You need to log in before you can comment on or make changes to this bug.