Opened 16 months ago

Closed 15 months ago

Last modified 5 months ago

#21724 closed defect (fixed)

Distinguish between Tor Browser and Firefox when macOS opens documents

Reported by: teor Owned by: tbb-team
Priority: Medium Milestone:
Component: Applications/Tor Browser Version:
Severity: Normal Keywords: TorBrowserTeam201703R, tbb-no-uplift
Cc: brade, mcs Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description (last modified by arthuredelstein)

Please see my branch fix-macos-bundle-signature on https://github.com/teor2345/tor-browser.git , which deals with the core issue of #17670, the MOZB CFBundleSignature change.

Note: #17670 was parent

Child Tickets

Attachments (1)

0001-Bug-21724-Make-Firefox-and-Tor-Browser-distinct-macO.patch (1.7 KB) - added by mcs 15 months ago.
updated patch

Download all attachments as: .zip

Change History (9)

comment:1 Changed 16 months ago by teor

If we do use this, we should register MOZT with Apple, and ask mozilla if they want us to use a completely separate identifier instead (like TORB).

comment:2 Changed 16 months ago by gk

Cc: brade mcs added
Keywords: TorBrowserTeam201703R added
Status: newneeds_review

comment:3 Changed 15 months ago by mcs

While I do not object to this change, we should test and see if this change is needed. I have the impression (but no hard data) that the creator code is not used by OSX and that only the bundle ID is important. And I do not think Apple maintains a registry any more.

comment:4 in reply to:  3 Changed 15 months ago by teor

Replying to mcs:

While I do not object to this change, we should test and see if this change is needed. I have the impression (but no hard data) that the creator code is not used by OSX and that only the bundle ID is important.

Apple has deprecated the creator code, but still uses it in their implementation for backwards-compatibility reasons.

They are not mentioned at all in:
https://developer.apple.com/library/content/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html

But here's how I can reproduce the Tor Browser / Firefox confusion on macOS 10.12.3:

  1. Install Firefox and Tor Browser
  2. touch empty.html
  3. In Finder, Get Info on empty.html
  4. Set "Open With" to Tor Browser
  5. Make sure both Firefox and Tor Browser are not running
  6. Open empty.html with the Finder

(Either Firefox or Tor Browser will open depending on their order in the LaunchServices database, which depends on installation and maybe previous view/open order, and then if Tor Browser opens, Tor Launcher fails to handle the open request, so the default browser will open instead, see #20105)

  1. Make sure Firefox is running and Tor Browser is not running
  2. Open empty.html with the Finder

(Firefox opens, even though we said to Open in Tor Browser)

  1. Make sure Tor Browser is running and Firefox is not running
  2. Open empty.html with the Finder

(Tor Browser opens)

  1. Make sure Tor Browser and Firefox are both running
  2. Open empty.html with the Finder

(Either Firefox or Tor Browser will open depending on their order in the LaunchServices database, which depends on installation and maybe previous view/open/launch order)

What I expect to happen is that Tor Browser opens every time, and Firefox or the default browser do not open.

And I do not think Apple maintains a registry any more.

Yes, this is true. But we should try not to conflict with Mozilla's potential future uses, if any.

comment:5 Changed 15 months ago by mcs

Kathy and I modified your patch to use 'TORB' instead of 'MOZT' (it seems like a good idea to include Tor somehow). We also rebased it so it will apply against the ESR52 code. As I said in #21273, trying these changes with our upcoming ESR52-based alpha seems like a good idea.

comment:6 Changed 15 months ago by gk

Resolution: fixed
Status: needs_reviewclosed

Thanks, this is commit 2ac144743bce9a586b6292c3f9be53de8ed2ef15 on tor-browser-52.0.2esr-7.0-1 (once it is pushed).

comment:7 Changed 13 months ago by teor

I had Tor Browser selected as my default browser (links automatically open in it). When I updated to Tor Browser 7.0, it stopped being my default browser, because the creator code changed due to this patch (or possibly #21723).

This is what we expected to happen, but I thought I'd make a note here in case anyone reports this issue. Once users set 7.0 as the default browser, it will stay as the default, and it won't get confused with Firefox.

comment:8 Changed 5 months ago by arthuredelstein

Description: modified (diff)
Keywords: tbb-no-uplift added
Parent ID: #17670
Note: See TracTickets for help on using tickets.