Commit Graph

1217 Commits

Author SHA1 Message Date
Haik Aftandilian
c0f7925547 Bug 1578907 - MacOS 10.15 Beta - Flash File Picker broken r=spohl
Allow access to extra services needed to open file pickers from the Flash process on 10.15.

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

--HG--
extra : moz-landing-system : lando
2019-10-04 15:38:07 +00:00
shravanrn@gmail.com
bb7e97ff6a Bug 1575985 part 2 - Allow RW access to /dev/null in content sandbox r=gcp
This is needed by lucet to run WASM sandboxed libraries.

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

--HG--
extra : moz-landing-system : lando
2019-09-30 21:57:34 +00:00
Andrew Halberstadt
898dfb96b4 Bug 1567642 - [lint.flake8] Fix misc flake8 under Python 3 lint issues r=gbrown
Differential Revision: https://phabricator.services.mozilla.com/D45417

--HG--
extra : moz-landing-system : lando
2019-09-24 14:44:01 +00:00
Ryan Alderete
2e2b52b880 Bug 1572846 - Update Clearkey to use NSS for decryption instead of OpenAES r=bryce,jld
Clearkey previously relied on OpenAES to do its encryption.  In order to
facilitate future changes and the need for CBC support, switch to NSS, which
should be more flexible and actively maintained.

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

--HG--
extra : moz-landing-system : lando
2019-09-05 19:19:06 +00:00
Bob Owen
17bddfd388 Bug 1575906: Allow the GMP process to duplicate Section handles to the main process. r=handyman
Differential Revision: https://phabricator.services.mozilla.com/D44237

--HG--
extra : moz-landing-system : lando
2019-08-30 21:39:57 +00:00
Gijs Kruitbosch
871832fcf9 Bug 1575564 - avoid non-mainthread use of NS_GetSpecialDirectory in linux sandboxbroker, r=jld,gcp
Differential Revision: https://phabricator.services.mozilla.com/D42951

--HG--
extra : moz-landing-system : lando
2019-08-22 16:37:18 +00:00
Mike Hommey
66d7fe943e Bug 1575420 - Replace MOZ_WIDGET_TOOLKIT value of "gtk3" with "gtk". r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D42765

--HG--
extra : moz-landing-system : lando
2019-08-21 12:25:42 +00:00
Gian-Carlo Pascutto
8b7a11d51c Bug 1573578 - Whitelist brk syscall if jemalloc is disabled. r=jld
Differential Revision: https://phabricator.services.mozilla.com/D41998

--HG--
extra : moz-landing-system : lando
2019-08-14 22:50:51 +00:00
Gabriele Svelto
14db2c37b8 Bug 1571711 - Factorize crash handling out of the various process IPC classes r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D41657

--HG--
extra : moz-landing-system : lando
2019-08-15 12:06:51 +00:00
Bogdan Tara
f326b67e0e Backed out changeset c60ee628dd0e (bug 1571711) for RemoteSandboxBroker related bustages CLOSED TREE 2019-08-15 01:50:01 +03:00
Gabriele Svelto
d888c0a6b5 Bug 1571711 - Factorize crash handling out of the various process IPC classes r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D41657

--HG--
extra : moz-landing-system : lando
2019-08-13 21:43:00 +00:00
Haik Aftandilian
ecc3193420 Bug 1564434 - MT_safe_localtime generates incorrect value in sandboxed content process r=handyman
Allow access to timezone data files from the content/flash/GMP/utility sandbox.

Remove unneeded regex providing access to ^/private/tmp/KSInstallAction\. files.

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

--HG--
extra : moz-landing-system : lando
2019-08-12 21:36:03 +00:00
Gabriele Svelto
beb62c4c31 Bug 1282776 - Finalize crash reports for child process crashes happening too early r=froydnj
This changes the way crash reports for child processes happening too early
during the child process' startup. Before bug 1547698 we wrote a partial
.extra file with those crashes that lacked the process type. The user would
not be notified of those crashes until she restarted Firefox and even when
submitted those crashes would be erroneously labeled as browser crashes.

After bug 1547698 we stopped writing .extra files entirely for those crashes
which left orphaned .dmp files among the pending crash reports.

This patch does three things to improve the situation:

* It writes a partial .extra file so that the crashes are detected at the next
  startup. So the user is still not notified directly of these crashes but she
  can report them later.
* It adds the process type to the .extra file so that the crash reporters are
  labelled correctly.
* It fixes a leak in the `pidToMinidump` hash-map. Since the crashes were
  not finalized the `ChildProcessData` strucutre associated with them would
  never be fred.

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

--HG--
extra : moz-landing-system : lando
2019-08-09 14:23:19 +00:00
Gabriele Svelto
53d4ac9807 Bug 1572565 - Make the remote sandbox broker process' telemetry string consistent r=jld
Differential Revision: https://phabricator.services.mozilla.com/D41291

--HG--
extra : moz-landing-system : lando
2019-08-09 00:03:33 +00:00
Jed Davis
660156542f Bug 1559368 - When determining sandbox capabilities, check for the specific X11 socket that would be used. r=gcp
Differential Revision: https://phabricator.services.mozilla.com/D40915

--HG--
extra : moz-landing-system : lando
2019-08-07 22:34:50 +00:00
Bob Owen
6a19f3eb75 Bug 1569139: Add a static pref to enable win32k lockdown in the Windows content process sandbox policy. r=aklotz
Differential Revision: https://phabricator.services.mozilla.com/D39870

--HG--
extra : moz-landing-system : lando
2019-08-01 10:55:54 +00:00
Tom Ritter
334edd038c Bug 1563774 - Enable Binary Signature Policy on the RDD process r=bobowen
To do this, we preload the AV libraries. They may not be needed right now,
but by doing this now we ensure that future RDD work won't mysteriously
fail during development for some poor coworker.

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

--HG--
extra : moz-landing-system : lando
2019-07-23 17:49:55 +00:00
Gian-Carlo Pascutto
c43f365472 Bug 1565996 - Handle relative paths in linker config parsing. r=jld
Differential Revision: https://phabricator.services.mozilla.com/D38634

--HG--
extra : moz-landing-system : lando
2019-07-26 14:03:53 +00:00
Bob Owen
23d09ead45 Bug 1565848: Revert latest change to MITIGATION_DLL_SEARCH_ORDER. r=aklotz
This is until any regressions can be fixed, see bug 1568850.

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

--HG--
extra : moz-landing-system : lando
2019-07-25 17:44:24 +00:00
Haik Aftandilian
a19efece81 Bug 1566540 - [10.15] Crash in [@ CrashReporter::TerminateHandler] r=spohl
To avoid crashing in macOS 10.15, allow access to the proc_info PROC_INFO_CALL_SETCONTROL syscall variant in the GMP and RDD sandboxes.

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

--HG--
extra : moz-landing-system : lando
2019-07-24 14:48:41 +00:00
Paul Adenot
6d321304a4 Bug 1565575 - Allow access to AudioComponentRegistrar when doing audio remoting on OSX to be able to use system decoders. r=haik
When audio remoting is enabled, we can remove most of the sandbox exceptions,
except one, that allows using system calls to do decoding of audio and video
using system decoders (h264 and aac). Not doing that results in most mp4 files
to be unplayable, erroring out when doing calls like this:

https://searchfox.org/mozilla-central/rev/da855d65d1fbdd714190cab2c46130f7422f3699/dom/media/platforms/apple/AppleATDecoder.cpp:336
https://searchfox.org/mozilla-central/rev/da855d65d1fbdd714190cab2c46130f7422f3699/dom/media/platforms/apple/AppleATDecoder.cpp:545

We'll be able to remove it again when we'll use the RDD for everything, but in
the meantime, this exception is needed.

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

--HG--
extra : moz-landing-system : lando
2019-07-22 08:22:40 +00:00
Jed Davis
0ba66c379f Bug 1534780 - Add free interconversion between UniqueFileHandle and ipc::FileDescriptor and use it in a few places. r=froydnj
Now that UniqueFileHandle can be used more widely, and with
ipc::FileDescriptor being essentially a copyable UniqueFileHandle, it
makes sense to add a move constructor and a "forget"-like method to
convert between them when needed.

Depends on D26737

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

--HG--
extra : moz-landing-system : lando
2019-06-28 19:46:58 +00:00
Sylvestre Ledru
e77bfc655d Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

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

--HG--
extra : moz-landing-system : lando
2019-07-16 07:33:44 +00:00
Bob Owen
95b19e37ff Bug 1564899: Make CloseHandleWrapper CHECK a DCHECK on non-Nightly builds. r=handyman
This is because we are hitting it frequently during PolicyBase::OnJobEmpty and
currently we can't work out how this can happen.

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

--HG--
extra : moz-landing-system : lando
2019-07-15 17:19:17 +00:00
Bob Owen
7b91f43ece Bug 1557282: SetLockdownDefaultDacl for content process sandbox policy for Windows 10 or later. r=jmathies
Differential Revision: https://phabricator.services.mozilla.com/D33301

--HG--
extra : moz-landing-system : lando
2019-07-10 14:57:01 +00:00
Bobby Holley
3b7fbc734f Bug 1562763 - Move some types around. r=jld
Having to namespace these into GeckoChildProcessHost is annoying. The
|using| declarations help to some extent, but it's easier to just put
them in mozilla::ipc.

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

--HG--
extra : moz-landing-system : lando
2019-07-10 22:37:35 +00:00
Haik Aftandilian
7105b782dc Bug 1556846 - [10.15] Crash in [@ mozilla::plugins::PluginUtilsOSX::SetProcessName] r=spohl
Allow limited access to the proc_pidinfo() syscall from the Mac utility process sandbox.

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

--HG--
extra : moz-landing-system : lando
2019-07-10 15:00:05 +00:00
Victor Porof
858f3b554b Bug 1561435 - Format security/, a=automatic-formatting
# ignore-this-changeset

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

--HG--
extra : source : 4e926f91b17c2b13cdaf13e017629286275dbc00
2019-07-05 10:57:28 +02:00
Haik Aftandilian
a218f608fc Bug 1558924 - [10.15] Widevine crashes on macOS Catalina Beta r=handyman
Allow limited access to the proc_pidinfo() syscall from the GMP sandbox.

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

--HG--
extra : moz-landing-system : lando
2019-07-03 18:17:55 +00:00
Narcis Beleuzu
a89b67e772 Backed out 15 changesets (bug 1479960, bug 1426526, bug 1534780, bug 1536697) for toolchain bustages on UniquePtrExtensions.h . CLOSED TREE
Backed out changeset a8518ea4b594 (bug 1479960)
Backed out changeset 7172762c4b87 (bug 1536697)
Backed out changeset 2ea5ccb8f3a1 (bug 1426526)
Backed out changeset d892a888fe9c (bug 1426526)
Backed out changeset 2c4d12bdfec3 (bug 1479960)
Backed out changeset 8a322064cf6d (bug 1479960)
Backed out changeset 47d387b6cd4a (bug 1479960)
Backed out changeset 8332565a6943 (bug 1479960)
Backed out changeset 9d7f1835f96f (bug 1479960)
Backed out changeset 0aa8af4965c5 (bug 1479960)
Backed out changeset 036809330a51 (bug 1479960)
Backed out changeset 39e18373e3d3 (bug 1479960)
Backed out changeset 6c2b995a9d30 (bug 1479960)
Backed out changeset 3c2b31744645 (bug 1534780)
Backed out changeset 26bb00a94d5d (bug 1534780)
2019-06-28 22:42:00 +03:00
Tom Ritter
01f7b56cf8 Bug 1552706 - Update MinGW version and remove MinGW sandbox hacks r=bobowen
Differential Revision: https://phabricator.services.mozilla.com/D36218

--HG--
extra : moz-landing-system : lando
2019-06-28 09:53:12 +00:00
Aaron Klotz
6d7a4fd701 Bug 1553249: Only set the Win32k disable policy for the RDD process when running on Win8+; r=bobowen
Differential Revision: https://phabricator.services.mozilla.com/D36239

--HG--
extra : moz-landing-system : lando
2019-06-28 09:44:03 +00:00
Jed Davis
d32b9ba525 Bug 1534780 - Add free interconversion between UniqueFileHandle and ipc::FileDescriptor and use it in a few places. r=froydnj
Now that UniqueFileHandle can be used more widely, and with
ipc::FileDescriptor being essentially a copyable UniqueFileHandle, it
makes sense to add a move constructor and a "forget"-like method to
convert between them when needed.

Depends on D26737

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

--HG--
extra : moz-landing-system : lando
2019-06-20 22:40:15 +00:00
Ciure Andrei
72f3f971fb Backed out 15 changesets (bug 1479960, bug 1426526, bug 1534780, bug 1536697) for causing build bustages CLOSED TREE
Backed out changeset 5645e0cc3915 (bug 1479960)
Backed out changeset a7c09894c6a0 (bug 1536697)
Backed out changeset 510f03381af9 (bug 1426526)
Backed out changeset 7cf4735a088f (bug 1426526)
Backed out changeset 41080844e645 (bug 1479960)
Backed out changeset fdba3c5f8fd0 (bug 1479960)
Backed out changeset 26a8ebcb2db4 (bug 1479960)
Backed out changeset d0d383e5bae1 (bug 1479960)
Backed out changeset c418095bb7b7 (bug 1479960)
Backed out changeset 7b78b1945532 (bug 1479960)
Backed out changeset c47d47d4073d (bug 1479960)
Backed out changeset 71253b62a633 (bug 1479960)
Backed out changeset ae525f20bdbb (bug 1479960)
Backed out changeset 7fba719355d7 (bug 1534780)
Backed out changeset 771db331860a (bug 1534780)
2019-06-20 19:54:57 +03:00
Jed Davis
f32394bec8 Bug 1534780 - Add free interconversion between UniqueFileHandle and ipc::FileDescriptor and use it in a few places. r=froydnj
Now that UniqueFileHandle can be used more widely, and with
ipc::FileDescriptor being essentially a copyable UniqueFileHandle, it
makes sense to add a move constructor and a "forget"-like method to
convert between them when needed.

Depends on D26737

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

--HG--
extra : moz-landing-system : lando
2019-06-17 02:19:37 +00:00
Haik Aftandilian
d302444d67 Bug 1498742 - Part 2 - Start the GMP sandbox earlier during process startup r=jya,cpearce
Change the Mac GMP process launch to include sandboxing params on the command line to allow the sandbox to be started earlier during GMP process launch. Content, extension, and RDD processes have already been changed to start the sandbox earlier.

Update GMPProcessParent to override GeckoChildProcessHost methods used to construct sandboxing parameters. Pass the plugin path as a sandbox parameter so that the sandbox rules can whitelist the plugin directory which is now read after the sandbox is enabled in the plugin process. On development builds, pass "testingReadPath" params so directories needed during automated tests can be whitelisted.

Update Mac sandboxing code to detect GMP sandbox params on the command line and enable the sandbox with additional arguments needed for early sandbox start.

Allow reverting to the old implementation by setting security.sandbox.gmp.mac.earlyinit to false.

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

--HG--
extra : moz-landing-system : lando
2019-06-14 22:55:27 +00:00
Dorel Luca
fb616d00a6 Backed out 2 changesets (bug 1498742) for OSX build bustages. CLOSED TREE
Backed out changeset f6da94d90350 (bug 1498742)
Backed out changeset 4f3e83d8de59 (bug 1498742)
2019-06-15 00:13:05 +03:00
Haik Aftandilian
c0874f2dba Bug 1498742 - Part 2 - Start the GMP sandbox earlier during process startup r=jya,cpearce
Change the Mac GMP process launch to include sandboxing params on the command line to allow the sandbox to be started earlier during GMP process launch. Content, extension, and RDD processes have already been changed to start the sandbox earlier.

Update GMPProcessParent to override GeckoChildProcessHost methods used to construct sandboxing parameters. Pass the plugin path as a sandbox parameter so that the sandbox rules can whitelist the plugin directory which is now read after the sandbox is enabled in the plugin process. On development builds, pass "testingReadPath" params so directories needed during automated tests can be whitelisted.

Update Mac sandboxing code to detect GMP sandbox params on the command line and enable the sandbox with additional arguments needed for early sandbox start.

Allow reverting to the old implementation by setting security.sandbox.gmp.mac.earlyinit to false.

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

--HG--
extra : moz-landing-system : lando
2019-06-14 20:12:01 +00:00
Bogdan Tara
d62176d3d7 Backed out 2 changesets (bug 1498742) for nsMacUtilsImpl.cpp related build bustage a=backout
Backed out changeset 6729dc168afd (bug 1498742)
Backed out changeset e5eed57a9111 (bug 1498742)
2019-06-14 12:50:04 +03:00
Haik Aftandilian
f87e72036e Bug 1498742 - Part 2 - Start the GMP sandbox earlier during process startup r=jya,cpearce
Change the Mac GMP process launch to include sandboxing params on the command line to allow the sandbox to be started earlier during GMP process launch. Content, extension, and RDD processes have already been changed to start the sandbox earlier.

Update GMPProcessParent to override GeckoChildProcessHost methods used to construct sandboxing parameters. Pass the plugin path as a sandbox parameter so that the sandbox rules can whitelist the plugin directory which is now read after the sandbox is enabled in the plugin process. On development builds, pass "testingReadPath" params so directories needed during automated tests can be whitelisted.

Update Mac sandboxing code to detect GMP sandbox params on the command line and enable the sandbox with additional arguments needed for early sandbox start.

Allow reverting to the old implementation by setting security.sandbox.gmp.mac.earlyinit to false.

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

--HG--
extra : moz-landing-system : lando
2019-06-13 06:32:37 +00:00
Andreea Pavel
307e3f181b Backed out 2 changesets (bug 1498742) for build bustages at GMPProcessParent.cpp on a CLOSED TREE
Backed out changeset 5f9d32e26c71 (bug 1498742)
Backed out changeset ffc8d151cf3a (bug 1498742)
2019-06-13 04:38:56 +03:00
Haik Aftandilian
0f858863b6 Bug 1498742 - Part 2 - Start the GMP sandbox earlier during process startup r=jya,cpearce
Change the Mac GMP process launch to include sandboxing params on the command line to allow the sandbox to be started earlier during GMP process launch. Content, extension, and RDD processes have already been changed to start the sandbox earlier.

Update GMPProcessParent to override GeckoChildProcessHost methods used to construct sandboxing parameters. Pass the plugin path as a sandbox parameter so that the sandbox rules can whitelist the plugin directory which is now read after the sandbox is enabled in the plugin process. On development builds, pass "testingReadPath" params so directories needed during automated tests can be whitelisted.

Update Mac sandboxing code to detect GMP sandbox params on the command line and enable the sandbox with additional arguments needed for early sandbox start.

Allow reverting to the old implementation by setting security.sandbox.gmp.mac.earlyinit to false.

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

--HG--
extra : moz-landing-system : lando
2019-06-12 23:41:53 +00:00
Haik Aftandilian
a195f66f52 Bug 1498742 - Part 1 - Move GetRepoDir(), GetObjDir(), IsDevelopmentBuild() from ContentChild to nsMacUtilsImpl r=spohl
Differential Revision: https://phabricator.services.mozilla.com/D34084

--HG--
extra : moz-landing-system : lando
2019-06-12 23:41:39 +00:00
Bob Owen
0162cd1ed7 Bug 1552160 Part 2: Roll-up patch to apply remaining mozilla changes to chromium sandbox. r=tabraldes,aklotz,jimm,bobowen
Patches re-applied from security/sandbox/chromium-shim/patches/after_update/.
See patch files for additional commit comments.
2014-11-29 17:12:18 +00:00
Bob Owen
2cad8de361 Bug 1552160 Part 1: Roll-up of chromium sandbox update and mozilla patches to get a running browser. r=jld,aklotz,tjr,bobowen
This updates security/sandbox/chromium/ files to chromium commit 84108231f6e6e0772fb9a4643679ce76aa771e67.

Existing and new patches applied from security/sandbox/chromium-shim/patches/with_update/ to give a compiling and mostly working browser.
See patch files for additional commit comments.

--HG--
rename : security/sandbox/chromium-shim/base/debug/debugging_flags.h => security/sandbox/chromium-shim/base/debug/debugging_buildflags.h
rename : security/sandbox/chromium-shim/base/win/base_features.h => security/sandbox/chromium-shim/base/win/base_win_buildflags.h
2019-06-12 11:10:48 +01:00
Gian-Carlo Pascutto
84108d4e2b Bug 1555589 - Include sys/prctl.h not linux/prctl.h. r=jld
Differential Revision: https://phabricator.services.mozilla.com/D33517

--HG--
extra : moz-landing-system : lando
2019-06-03 21:35:44 +00:00
Sylvestre Ledru
d57d4905f1 Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

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

--HG--
extra : moz-landing-system : lando
2019-05-25 17:46:15 +00:00
arthur.iakab
af8e458c5f Backed out changeset a296439a25ff (bug 1519636) for frequent Windows cppunit failures CLOSED TREE 2019-05-24 14:26:01 +03:00
Sylvestre Ledru
c82ea97226 Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

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

--HG--
extra : moz-landing-system : lando
2019-05-24 09:59:17 +00:00
David Major
6efaa8b1cd Bug 1523526 - Don't allow CFG on old releases of Windows for arm64 r=bobowen,aklotz
There's a bug in ole32.dll on arm64 versions of Windows prior to 1809, that crashes our content processes if we enable CFG. We've reported the issue, but even if it gets fixed, we can't assume users will have the update.

This patch uses process mitigation policy flags to disable CFG on arm64 before 1809. Based on testing, we only need to do this in the sandbox for child processes, and it's not strictly necessary for the launcher stub to set the flag on the main process. But I've included that anyway as a guard against some yet-undiscovered scenario that might hit the issue and make the browser unusable.

The effects of this patch won't be visible until we actually enable CFG in a subsequent landing.

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

--HG--
extra : moz-landing-system : lando
2019-05-20 17:25:30 +00:00