Commit Graph

2837 Commits

Author SHA1 Message Date
Dave Townsend
51d7275289 Bug 1518639: Remote unused mProfileName member. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D19416

--HG--
extra : rebase_source : 99c0ca7de68eaebe5ca07952262ded4ff5be78b7
2019-02-08 11:22:23 -08:00
Dave Townsend
2e36a5b92d Bug 1518639: Move remote client call to after we have a profile. r=jimm
Makes it so we always know which profile we want to remote the command line to.

Differential Revision: https://phabricator.services.mozilla.com/D19073

--HG--
extra : rebase_source : 352d2e315fdd12b8da71358f364ce2789f7c8b99
extra : intermediate-source : 8e3c52953f837769e632d8b7d2d7fbc195df375e
extra : source : f1f569797e33b390ba588351e826fa979b018f01
2019-01-31 17:06:00 -08:00
Dave Townsend
d62ca34ba8 Bug 1518639: Move command line handing to nsRemoteService. r=jimm
Makes nsRemoteService handle the command line parsing, though this will end up
being removed in a later patch.

Differential Revision: https://phabricator.services.mozilla.com/D19071

--HG--
extra : rebase_source : c83f6795ce58019390feaf918045c24527da543e
extra : intermediate-source : 48c797da72052953b4a81648219750914846e162
extra : source : 5c648e7641a72770d89a5408ac01de3b5de15c6b
2019-01-31 12:13:34 -08:00
Dave Townsend
efa98f92fe Bug 1518639: Move startup locking to the remote service. r=jimm
Makes nsRemoteService responsible for the shared lock for the time between
attempting to contact a remote server and starting up our own server.

Differential Revision: https://phabricator.services.mozilla.com/D19070

--HG--
extra : rebase_source : d2191966989c1b6db0dfb0db91f1b27d85046835
extra : intermediate-source : 405ea32162ba129b0c3e9ed75c9de13259d2d759
extra : source : 4da03e7a957c180d5997e3d8f6903b22f9a800c4
2019-01-31 12:13:34 -08:00
Dave Townsend
35a7ffebca Bug 1518639: Move the calls to the remote clients into nsRemoteService. r=jimm
Makes nsRemoteService responsible for managing the clients too, simplifying
nsAppRunner.

Differential Revision: https://phabricator.services.mozilla.com/D19069

--HG--
extra : rebase_source : a5a8dc33b8b871a0b01e802bb406383275ddd4ec
extra : intermediate-source : c8bd4a7bc4e04b3648395252d4a377feb237e58e
extra : source : 1ca2a56746a32219cc65015632c19a5856023e45
2019-01-31 12:13:34 -08:00
Dave Townsend
c34dd583d0 Bug 1518639: Move widget/xremote code to toolkit/components/remote. r=jimm
It makes more sense for the remote client to live alongside the server.

Differential Revision: https://phabricator.services.mozilla.com/D19068

--HG--
rename : widget/xremoteclient/RemoteUtils.cpp => toolkit/components/remote/RemoteUtils.cpp
rename : widget/xremoteclient/RemoteUtils.h => toolkit/components/remote/RemoteUtils.h
rename : widget/xremoteclient/DBusRemoteClient.cpp => toolkit/components/remote/nsDBusRemoteClient.cpp
rename : widget/xremoteclient/DBusRemoteClient.h => toolkit/components/remote/nsDBusRemoteClient.h
rename : widget/xremoteclient/nsRemoteClient.h => toolkit/components/remote/nsRemoteClient.h
rename : widget/xremoteclient/XRemoteClient.cpp => toolkit/components/remote/nsXRemoteClient.cpp
rename : widget/xremoteclient/XRemoteClient.h => toolkit/components/remote/nsXRemoteClient.h
extra : rebase_source : 3e34402d41031f598f23a1e82e797797a52538dd
extra : source : c3c13b550b675b488bdde389035a13c85eee947d
2019-01-31 12:13:34 -08:00
Dave Townsend
5e41c25e13 Bug 1518639: Break out the remote server pieces from nsRemoteService and deCOMtaminate. r=jimm
This code is only ever used from c++ so does not need to be an XPCOM component.
Broken out a single nsRemoteService that is responsible for choosing the server
implementation to use.

Differential Revision: https://phabricator.services.mozilla.com/D19067

--HG--
rename : toolkit/components/remote/nsDBusRemoteService.cpp => toolkit/components/remote/nsDBusRemoteServer.cpp
rename : toolkit/components/remote/nsDBusRemoteService.h => toolkit/components/remote/nsDBusRemoteServer.h
rename : toolkit/components/remote/nsGTKRemoteService.cpp => toolkit/components/remote/nsGTKRemoteServer.cpp
rename : toolkit/components/remote/nsGTKRemoteService.h => toolkit/components/remote/nsGTKRemoteServer.h
rename : toolkit/components/remote/nsXRemoteService.cpp => toolkit/components/remote/nsXRemoteServer.cpp
rename : toolkit/components/remote/nsXRemoteService.h => toolkit/components/remote/nsXRemoteServer.h
extra : rebase_source : 631ee45923c64acde92e23c155cbbbbc7a1d9c4d
2019-02-27 15:45:51 -08:00
Dave Townsend
bbb9bd1286 Bug 1518639: Remove the ability to remote to a different user or application. r=jimm
Remoting to a different user isn't supported everywhere and being able to
remote to a different application entirely is kind of odd. I don't think it
makes sense to continue to support these operations.

Differential Revision: https://phabricator.services.mozilla.com/D19066

--HG--
extra : rebase_source : df03e6d2233c4235308f2f8c8ec860e8827254e5
extra : source : b4210f85c7e9c86ef0f173b5d2250c2862fec992
2019-01-31 11:12:32 -08:00
Felipe Gomes
11a6e872ed Bug 827976 - Create the hidden window lazily on non-Mac platforms. r=aklotz
Differential Revision: https://phabricator.services.mozilla.com/D21071

--HG--
extra : moz-landing-system : lando
2019-03-05 20:18:25 +00:00
Brindusan Cristian
f200449d81 Backed out changeset b6e605718832 (bug 1531902) for bui;ld bustages at firefox.js. CLOSED TREE 2019-03-06 01:14:26 +02:00
Aaron Klotz
d09253afce Bug 1531902: Enable launcher process pref on beta; r=mhowell
Differential Revision: https://phabricator.services.mozilla.com/D21789

--HG--
extra : moz-landing-system : lando
2019-03-05 20:19:43 +00:00
Cosmin Sabou
a706bb3916 Backed out 16 changesets (bug 827976) for causing bug 1532054. a=backout
Backed out changeset 54c0b12443ed (bug 827976)
Backed out changeset 92b45080d080 (bug 827976)
Backed out changeset 443087a359f9 (bug 827976)
Backed out changeset f976c2d4cebb (bug 827976)
Backed out changeset 66cffb171024 (bug 827976)
Backed out changeset 845e1d0b2402 (bug 827976)
Backed out changeset fd94066a1d76 (bug 827976)
Backed out changeset e253b264e7bd (bug 827976)
Backed out changeset 07ef335770a8 (bug 827976)
Backed out changeset 9d3805d77b99 (bug 827976)
Backed out changeset eed600ceb606 (bug 827976)
Backed out changeset 3b64368cff52 (bug 827976)
Backed out changeset 69d0378e0c09 (bug 827976)
Backed out changeset 9203871a5c6f (bug 827976)
Backed out changeset 96a507c818e2 (bug 827976)
Backed out changeset e254496ff95b (bug 827976)
2019-03-02 20:40:01 +02:00
Felipe Gomes
970e70533a Bug 827976 - Create the hidden window lazily on non-Mac platforms. r=aklotz
Differential Revision: https://phabricator.services.mozilla.com/D21071

--HG--
extra : moz-landing-system : lando
2019-03-01 21:04:48 +00:00
Gurzau Raul
6b94d177d1 Merge mozilla-central to inbound. a=merge CLOSED TREE 2019-03-01 09:28:28 +02:00
Ryan VanderMeulen
4cd0c30960 Bug 1528353 - Re-enable browser_checkdllblockliststate.js on Win10 now that we're using version 1803 in CI. r=jmathies
Differential Revision: https://phabricator.services.mozilla.com/D19977

--HG--
extra : moz-landing-system : lando
2019-02-28 22:33:12 +00:00
Robert Strong
f9ecc88a7e Bug 1530103 - Check for osint argument when checking for greomni and appomni arguments. r=aklotz
Differential Revision: https://phabricator.services.mozilla.com/D21326

--HG--
extra : moz-landing-system : lando
2019-02-27 19:18:38 +00:00
Jed Davis
5cc3212784 Bug 1506291 - Move the AV1 decoders to a sandbox-friendly CPU counting wrapper. r=gcp,mjf
Counting CPUs accesses the filesystem (sysfs or procfs), which we'd like
to disallow when sandboxed if possible, and fails silently if access
is denied.  Because the CPU count rarely changes, this patch handles
that problem for the RDD process by caching a copy before starting
sandboxing.

Tested with a local patch to have the sandbox file broker client crash
if accessing the sysfs node for the CPU count, to verify that it's not
accessed.

Depends on D14524

Differential Revision: https://phabricator.services.mozilla.com/D20895

--HG--
extra : moz-landing-system : lando
2019-02-25 16:20:50 +00:00
Aaron Klotz
9deb5d11f5 Bug 1530788: Ensure that the launcher process pref remains functional on Nightly; r=mhowell
Differential Revision: https://phabricator.services.mozilla.com/D21254

--HG--
extra : moz-landing-system : lando
2019-02-26 21:38:08 +00:00
Ryan Hunt
6d8bc2e134 Bug 1523969 part 23 - Move method definition inline comments to new line in 'toolkit/'. r=ehsan
Differential Revision: https://phabricator.services.mozilla.com/D21124

--HG--
extra : rebase_source : f44a8f1cd9e2e73b6bb2a994d9aeb42779d2d36f
extra : histedit_source : f39b1350e24c58104047e65f14883ee3f710a295
2019-02-25 16:12:51 -06:00
Noemi Erli
7e23372938 Merge mozilla-central to autoland. a=merge CLOSED TREE
--HG--
extra : rebase_source : de8796d5d7d7079af1b895a2f537371885f8cc6c
2019-02-26 00:09:40 +02:00
Stephen A Pohl
4287947c1a Bug 1523613: Fix memory leaks during updates. r=rstrong 2019-02-25 10:16:15 -05:00
Aaron Klotz
8919792ffe Bug 1460433: Part 2 - Log launcher process failures to a telemetry ping; r=mhowell
This patch does a few things:

* Fleshes out the launcher process failure ping;
* Sends that ping via pingsender;
* If there is any failure in doing so, we fall back to the Windows event log;
* Any launcher process failures will result in us falling back to the normal
  startup code path, ensuring that users will still see a browser.

A sample ping will be attached to the bug.

Differential Revision: https://phabricator.services.mozilla.com/D19697

--HG--
extra : moz-landing-system : lando
2019-02-25 21:14:07 +00:00
Cosmin Sabou
65609ed7bd Backed out changeset 7733f36c6e38 (bug 1460433) for windows MinGW butages on ErrorHandler. CLOSED TREE
--HG--
extra : histedit_source : 8defc62b37bbaed971c6899d529e05db299a9d20
2019-02-25 20:32:35 +02:00
Aaron Klotz
61c0cff76e Bug 1460433: Part 2 - Log launcher process failures to a telemetry ping; r=mhowell
This patch does a few things:

* Fleshes out the launcher process failure ping;
* Sends that ping via pingsender;
* If there is any failure in doing so, we fall back to the Windows event log;
* Any launcher process failures will result in us falling back to the normal
  startup code path, ensuring that users will still see a browser.

A sample ping will be attached to the bug.

***
Format cleanup

Differential Revision: https://phabricator.services.mozilla.com/D19697

--HG--
extra : moz-landing-system : lando
2019-02-22 18:43:18 +00:00
Aaron Klotz
28466cb97e Bug 1460433: Part 1 - Change BasicDllServices to not do any dll notification callbacks; r=mhowell
BasicDllServices is used to gain access to the authenticode APIs in non-Gecko
contexts. One feature that WinDllServices provides is the ability to register
a callback interface to be notified when a DLL has been loaded.

This is not particularly useful in the BasicDllServices use case, and in the
"handle a launcher process failure on a background thread" use case, would
actually be harmful.

This patch modifies the DLLServices backend to offer a "basic" option that
omits the callback stuff.

Differential Revision: https://phabricator.services.mozilla.com/D19696

--HG--
extra : moz-landing-system : lando
2019-02-20 06:18:45 +00:00
Aaron Klotz
df205ceebd Bug 1529429: Part 2 - SHIELD opt-out for launcher process in Nightly; r=mhowell
We use the SHIELD pref instead of the usual launcher process pref for Nightly.
This effectively treats the launcher process as a SHIELD study with 100%
deployment.

We add some Nightly-specific code that uses the SHIELD pref to determine
whether or not to use the launcher. During startup, we query that pref and
reflect it into the registry, which then falls through to the usual launcher
process code.

We will be changing this past 67, but for now this is an effective way to
provide Nightly users with an opt-out to the launcher process and its telemetry.

Differential Revision: https://phabricator.services.mozilla.com/D20621

--HG--
extra : moz-landing-system : lando
2019-02-21 19:11:24 +00:00
Robert Strong
b71ad23d06 Bug 1434033 - Use ORIGIN to search for NSS on Linux. r=mhowell,glandium
Set the updater LDFLAGS to -Wl,-rpath=$ORIGIN so NSS can be found in the binary's directory
Stop changing the LD_LIBRARY_PATH in nsUpdaterDriver.cpp
Load the updater support files before the update begins in progressui_gtk.cpp
Launch the updater from the install directory instead of copying it to the update directory
Remove the skip-if = (os == linux && verify) for the staging tests since this also fixes the ETXTBSY error when calling execv on the copied updater

Differential Revision: https://phabricator.services.mozilla.com/D20098

--HG--
extra : moz-landing-system : lando
2019-02-21 00:31:11 +00:00
Masatoshi Kimura
e25fbce870 Bug 1528651 - Re-enable warnings-as-errors on Windows in some directories. r=dmajor
--HG--
extra : source : ba86ea25070b37f4725834e1c2d9ec4c0783e119
2019-02-17 15:03:02 +09:00
Olli Pettay
020b13e585 Bug 1528502 - Add an environment variable to control allow-downgrade, r=Mossop 2019-02-16 22:50:12 +02:00
Sylvestre Ledru
e0c61dafa5 Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
Summary: # ignore-this-changeset

Reviewers: Ehsan

Reviewed By: Ehsan

Subscribers: emilio, jandem, bbouvier, jya

Bug #: 1519636

Differential Revision: https://phabricator.services.mozilla.com/D20062
2019-02-16 20:20:37 +01:00
Cosmin Sabou
a4b19fcd61 Merge mozilla-inbound to mozilla-central. a=merge
--HG--
rename : browser/components/nsBrowserContentHandler.js => browser/components/BrowserContentHandler.jsm
2019-02-15 20:39:45 +02:00
Sylvestre Ledru
41d1d79094 Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D19663

--HG--
extra : moz-landing-system : lando
2019-02-15 08:15:57 +00:00
Daniel Varga
1e9aa9e1fc Merge mozilla-central to mozilla-inbound. a=merge on a CLOSED TREE
--HG--
rename : browser/components/nsBrowserContentHandler.js => browser/components/BrowserContentHandler.jsm
2019-02-15 03:51:05 +02:00
Mike Hommey
2980c6fe0b Bug 1512504 - Remove now unused CFG test. r=tjr
Depends on D19615

Differential Revision: https://phabricator.services.mozilla.com/D19616

--HG--
extra : moz-landing-system : lando
2019-02-14 18:56:29 +00:00
Aaron Klotz
84c01f8930 Bug 1400344: Rename mscom::MainThreadRuntime to mscom::ProcessRuntime and make it aware of Win32k lockdown and of multiple instantiations; r=Jamie
This patch takes care of a bunch of issues and does some cleanup:

* We rename mscom::MainThreadRuntime to mscom::ProcessRuntime, as the latter
  is a more accurate name going forward.
* We make ProcessRuntime aware of the Win32k Lockdown process mitigation
  policy. When Win32k is disabled, we perform process-wide COM initialization
  in the multi-threaded apartment (since we cannot create an STA window).
* We refactor the mscom apartment region stuff to enable the Win32k lockdown
  pieces in ProcessRuntime.
* We move some Gecko-specific stuff into MOZILLA_INTERNAL_API guards so that
  ProcessRuntime is usable outside of xul.dll (I will be needing it for the
  launcher process).
* Another thing that might happen with the launcher process is that, under
  error conditions in the launcher, we create a ProcessRuntime object on a
  background thread for the purposes of telemetry logging, but we also allow
  the main thread to proceed to start as the browser. This could result in a
  scenario where the main thread, as the browser process, is attempting to
  instantiate its ProcessRuntime and ends up racing with the launcher process's
  telemetry thread which has its own ProcessRuntime. To account for this
  situation, we add mutual exclusion to the process-wide initialization code.
  We host this part inside mozglue since that state is shared between both
  firefox.exe and xul.dll.
* We clean up ProcessRuntime::InitializeSecurity by using Vector to set up
  the EXPLICIT_ACCESS entries.
* We remove mscom::MainThreadClientInfo and replace it with a direct call to
  CoGetCallerTID
* We revise all references to this class to use the new name.

Differential Revision: https://phabricator.services.mozilla.com/D19551

--HG--
rename : ipc/mscom/COMApartmentRegion.h => ipc/mscom/ApartmentRegion.h
rename : ipc/mscom/MainThreadRuntime.cpp => ipc/mscom/ProcessRuntime.cpp
rename : ipc/mscom/MainThreadRuntime.h => ipc/mscom/ProcessRuntime.h
extra : moz-landing-system : lando
2019-02-14 18:56:20 +00:00
Dorel Luca
67115dd61b Backed out changeset 2d4b8d90cbd7 (bug 1400344) for Spider monkey failrues. CLOSED TREE
--HG--
rename : ipc/mscom/ApartmentRegion.h => ipc/mscom/COMApartmentRegion.h
rename : ipc/mscom/ProcessRuntime.cpp => ipc/mscom/MainThreadRuntime.cpp
rename : ipc/mscom/ProcessRuntime.h => ipc/mscom/MainThreadRuntime.h
2019-02-14 20:45:26 +02:00
Aaron Klotz
0cb12a123a Bug 1400344: Rename mscom::MainThreadRuntime to mscom::ProcessRuntime and make it aware of Win32k lockdown and of multiple instantiations; r=Jamie
This patch takes care of a bunch of issues and does some cleanup:

* We rename mscom::MainThreadRuntime to mscom::ProcessRuntime, as the latter
  is a more accurate name going forward.
* We make ProcessRuntime aware of the Win32k Lockdown process mitigation
  policy. When Win32k is disabled, we perform process-wide COM initialization
  in the multi-threaded apartment (since we cannot create an STA window).
* We refactor the mscom apartment region stuff to enable the Win32k lockdown
  pieces in ProcessRuntime.
* We move some Gecko-specific stuff into MOZILLA_INTERNAL_API guards so that
  ProcessRuntime is usable outside of xul.dll (I will be needing it for the
  launcher process).
* Another thing that might happen with the launcher process is that, under
  error conditions in the launcher, we create a ProcessRuntime object on a
  background thread for the purposes of telemetry logging, but we also allow
  the main thread to proceed to start as the browser. This could result in a
  scenario where the main thread, as the browser process, is attempting to
  instantiate its ProcessRuntime and ends up racing with the launcher process's
  telemetry thread which has its own ProcessRuntime. To account for this
  situation, we add mutual exclusion to the process-wide initialization code.
  We host this part inside mozglue since that state is shared between both
  firefox.exe and xul.dll.
* We clean up ProcessRuntime::InitializeSecurity by using Vector to set up
  the EXPLICIT_ACCESS entries.
* We remove mscom::MainThreadClientInfo and replace it with a direct call to
  CoGetCallerTID
* We revise all references to this class to use the new name.

Differential Revision: https://phabricator.services.mozilla.com/D19551

--HG--
rename : ipc/mscom/COMApartmentRegion.h => ipc/mscom/ApartmentRegion.h
rename : ipc/mscom/MainThreadRuntime.cpp => ipc/mscom/ProcessRuntime.cpp
rename : ipc/mscom/MainThreadRuntime.h => ipc/mscom/ProcessRuntime.h
extra : moz-landing-system : lando
2019-02-14 16:40:58 +00:00
Dave Townsend
6d2f06a63f Bug 1527374: Always remove --allow-downgrade from the command line. r=bzbarsky
Currently we only check and remove the --allow-downgrade command line argument
if the run is actually a downgrade. When we don't the --allow-downgrade argument
makes it to Firefox's default command line handler which doesn't know how to
handle it and so ignores it and the next argument on the command line.

Flipping the ordering of the check makes sure we always remove the argument.

Differential Revision: https://phabricator.services.mozilla.com/D19569

--HG--
extra : moz-landing-system : lando
2019-02-13 16:36:02 +00:00
Christian Holler
40d009a2a5 Bug 1526328 - Disable Telemetry recording in FUZZING builds. r=janerik
Differential Revision: https://phabricator.services.mozilla.com/D19359

--HG--
extra : moz-landing-system : lando
2019-02-13 16:16:32 +00:00
Sylvestre Ledru
816560fce5 Bug 1488679 - Use MOZ_APP_VERSION_DISPLAY for --version to show the full version r=glandium
Differential Revision: https://phabricator.services.mozilla.com/D19026

--HG--
extra : moz-landing-system : lando
2019-02-13 13:50:01 +00:00
Razvan Maries
dcc3ecb682 Merge mozilla-central to autoland. a=merge on a CLOSED TREE 2019-02-13 07:23:59 +02:00
Razvan Maries
221d6eaca3 Backed out changeset 91bfef9d7343 (bug 1527374) for causing merge conflict. a=backout 2019-02-13 07:21:11 +02:00
Ciure Andrei
54eeeb0a66 Backed out changeset 1f7d1d6bf61d (bug 1488679) for causing build bustages on xre/nsAppRunner.cpp CLOSED TREE 2019-02-13 01:36:43 +02:00
Sylvestre Ledru
bcb8079207 Bug 1488679 - Use MOZ_APP_VERSION_DISPLAY for --version to show the full version r=glandium
--HG--
extra : histedit_source : bc851cb0240c61b275b83a78342d4f00fef37ef8
2019-02-13 00:19:58 +01:00
Sylvestre Ledru
963728a54b Bug 1488679 - nsAppRunner.cpp: Ride along - Move to the correct style r=glandium
--HG--
extra : histedit_source : 14c997f60eaf04ed876c0daf5326c7d53ba586bc
2019-02-13 00:18:45 +01:00
Dave Townsend
68c6578b56 Bug 1527374: Always remove --allow-downgrade from the command line. r=bzbarsky
Currently we only check and remove the --allow-downgrade command line argument
if the run is actually a downgrade. When we don't the --allow-downgrade argument
makes it to Firefox's default command line handler which doesn't know how to
handle it and so ignores it and the next argument on the command line.

Flipping the ordering of the check makes sure we always remove the argument.

Differential Revision: https://phabricator.services.mozilla.com/D19569

--HG--
extra : rebase_source : 9d92c78a500bccdcb05d002bb129e779d2391468
2019-02-12 13:15:42 -08:00
Dave Townsend
c92f258326 Bug 1518639: Move profile locking outside of SelectProfile. r=froydnj
So the remoting clients can know what the selected profile is before an attempt
to lock it is made we move the locking code to after the call to SelectProfile.

Differential Revision: https://phabricator.services.mozilla.com/D19420

--HG--
extra : moz-landing-system : lando
2019-02-12 20:14:54 +00:00
Dave Townsend
85249bde88 Bug 1518639: Always use the same locking code when locking the profile. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D19419

--HG--
extra : moz-landing-system : lando
2019-02-12 20:14:52 +00:00
Dave Townsend
bd1192ad4d Bug 1518639: Split out the profile locking attempt into its own function. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D19418

--HG--
extra : moz-landing-system : lando
2019-02-12 20:14:45 +00:00
Dave Townsend
f381b7e980 Bug 1518639: Move offline command line argument handling alongside the other command line argument handling. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D19417

--HG--
extra : moz-landing-system : lando
2019-02-12 20:14:43 +00:00