Граф коммитов

265 Коммитов

Автор SHA1 Сообщение Дата
Florian Quèze ec1134bf2f Bug 1850647 - add an optional argument to py_action to record the target file name for most actions, r=glandium.
Differential Revision: https://phabricator.services.mozilla.com/D187306
2023-10-12 08:41:34 +00:00
Sandor Molnar a9ab9f37a0 Backed out 8 changesets (bug 1850647, bug 1325181) for causing build bustages CLOSED TREE
Backed out changeset ab9d4ca38d83 (bug 1850647)
Backed out changeset 7465055478d9 (bug 1850647)
Backed out changeset 2008dd9ac32a (bug 1325181)
Backed out changeset c95204654c91 (bug 1850647)
Backed out changeset 0128ca1c9d18 (bug 1850647)
Backed out changeset e9277971c260 (bug 1850647)
Backed out changeset 6c15af4bc2c6 (bug 1850647)
Backed out changeset ce7ac5e23c1c (bug 1850647)
2023-10-11 12:25:58 +03:00
Florian Quèze d40c2ed723 Bug 1850647 - add an optional argument to py_action to record the target file name for most actions, r=glandium.
Differential Revision: https://phabricator.services.mozilla.com/D187306
2023-10-11 05:54:13 +00:00
Haik Aftandilian 91fff12722 Bug 1827747 - Use a new executable for the macOS GMP process r=nika,glandium
Use a new executable for the GMP process named "<App Name> Media Plugin Helper" so that the content processes (using the plugin-container executable) and the GMP process can be signed with different entitlements allowing for the use of more secure entitlements.

In order for the new executable to load the Widevine plugin, a change is needed in the codesigning infrastructure repo to generate the .sig file for the new executable.

To get the security benefits of using a new executable for GMP, additional changes are needed in the codesigning infrastructure repo to enable signing plugin-container and the new executable with a reduced set of entitlements.

The executable is a copy of plugin-container renamed as "<App Name> Media Plugin Helper" so it appears with a user friendly name in Activity Monitor. For example, "Firefox Media Plugin Helper". (The GMP process runs with limited privileges preventing it from setting its own "nice" process name.)

Pref off the change until the .sig file change lands and media playback has been validated on production builds.

Differential Revision: https://phabricator.services.mozilla.com/D175796
2023-06-05 20:40:10 +00:00
Narcis Beleuzu 7e5789cdf8 Backed out 2 changesets (bug 1834172, bug 1827747) for breaking local artifacts . a=backout
Backed out changeset 0ceb457743b4 (bug 1834172)
Backed out changeset 7ad6a3ad9db7 (bug 1827747)
2023-05-22 12:42:00 +03:00
Haik Aftandilian a34208222c Bug 1827747 - Use a new executable for the macOS GMP process r=nika,glandium
Use a new executable for the GMP process named "<App Name> Media Plugin Helper" so that the content processes (using the plugin-container executable) and the GMP process can be signed with different entitlements allowing for the use of more secure entitlements.

To get the benefits of using a new executable for GMP, additional changes are needed in the codesigning infrastructure repo to enable signing plugin-container and the new executable with a reduced set of entitlements.

The executable is built as media-plugin-helper and then renamed to "<App Name> Media Plugin Helper" so it appears with a user friendly name in Activity Monitor. For example, "Firefox Media Plugin Helper". (The GMP process runs with limited privileges preventing it from setting its own "nice" process name.)

Limit the change to Nightly at this time to allow validation of using a new executable and then enabling the strong entitlements.

Differential Revision: https://phabricator.services.mozilla.com/D175796
2023-05-19 16:47:28 +00:00
Gabriele Svelto faa128ba61 Bug 1752703 - Move the pthread_thread_create() interposer under mozglue and prepare for having a single place where we place interposer functions r=glandium
Differential Revision: https://phabricator.services.mozilla.com/D164470
2023-05-10 16:33:07 +00:00
Sandor Molnar 0fa06effeb Backed out 2 changesets (bug 1752703) for causing spider-monkey failures in /mozglue/interposers/env_interposer.cpp CLOSED TREE
Backed out changeset 621d691fcf43 (bug 1752703)
Backed out changeset a53bc961d958 (bug 1752703)
2023-05-10 15:25:29 +03:00
Gabriele Svelto 0b0dd83125 Bug 1752703 - Move the pthread_thread_create() interposer under mozglue and prepare for having a single place where we place interposer functions r=glandium
Differential Revision: https://phabricator.services.mozilla.com/D164470
2023-05-10 12:02:19 +00:00
Narcis Beleuzu 82d0ebe862 Backed out 2 changesets (bug 1752703) for mochitest failures . CLOSED TREE
Backed out changeset 4ecb79ef23ae (bug 1752703)
Backed out changeset 1701c20a5da3 (bug 1752703)
2023-05-10 00:58:30 +03:00
Gabriele Svelto af9161feff Bug 1752703 - Move the pthread_thread_create() interposer under mozglue and prepare for having a single place where we place interposer functions r=glandium
Differential Revision: https://phabricator.services.mozilla.com/D164470
2023-05-09 20:29:45 +00:00
Stephen A Pohl 84829b4b98 Bug 1812567: Change the activation policy for plugin-container to NSApplicationActivationPolicyProhibited to make it clear that it cannot itself be activated and should continue to not appear in the Dock. r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D167944
2023-02-02 14:55:09 +00:00
Greg Stoll 62e5d740ae Bug 1804023 - Part 2: add ability to blocklist DLLs in just the GPU process r=gsvelto
As with the socket process, we can't automated test that the block works in the GPU process, but I manually verified this. I did add an automated test that ensures blocking something in the GPU process doesn't block it in other processes.

Differential Revision: https://phabricator.services.mozilla.com/D167399
2023-01-20 19:21:39 +00:00
Cosmin Sabou af47c3669b Backed out 3 changesets (bug 1804023) for causing DllBlocklistInit.cpp related bustages. CLOSED TREE
Backed out changeset 8ac7bb069839 (bug 1804023)
Backed out changeset 9d2766a3d506 (bug 1804023)
Backed out changeset b5b4be5f7502 (bug 1804023)
2023-01-20 20:44:28 +02:00
Greg Stoll 8cb4d0d627 Bug 1804023 - Part 2: add ability to blocklist DLLs in just the GPU process r=gsvelto
As with the socket process, we can't automated test that the block works in the GPU process, but I manually verified this. I did add an automated test that ensures blocking something in the GPU process doesn't block it in other processes.

Differential Revision: https://phabricator.services.mozilla.com/D167399
2023-01-20 18:00:45 +00:00
Ryan VanderMeulen 9274f4e6f3 Backed out changeset 8b644e916589 (bug 1752703) for causing Android startup crashes (bug 1807716) 2023-01-04 09:34:28 -05:00
Gabriele Svelto 2cb8a79c25 Bug 1752703 - Move the pthread_thread_create() interposer under mozglue and prepare for having a single place where we place interposer functions r=glandium
Differential Revision: https://phabricator.services.mozilla.com/D164470
2022-12-21 10:24:41 +00:00
Sandor Molnar 0ad99cb2f6 Backed out 3 changesets (bug 1752703) for causing spider-monkey bustages.
Backed out changeset 6b8d96806ae6 (bug 1752703)
Backed out changeset afbd8f714804 (bug 1752703)
Backed out changeset 1adb41e2eb9b (bug 1752703)
2022-12-20 10:31:04 +02:00
Gabriele Svelto 63bfefbbe7 Bug 1752703 - Move the pthread_thread_create() interposer under mozglue and prepare for having a single place where we place interposer functions r=glandium
Differential Revision: https://phabricator.services.mozilla.com/D164470
2022-12-20 08:07:37 +00:00
Greg Stoll d44f201e8f Bug 1760668 - part 1: add ability to blocklist DLLs in socket process. r=gerard-majax
Differential Revision: https://phabricator.services.mozilla.com/D160586
2022-11-04 18:12:59 +00:00
Greg Stoll 7950aa0894 Bug 1783304 - Simplify DLL blocklist init r=handyman
Now that SetGeckoProcessType() is called earlier, we can use that to determine if we are a utility process instead of parsing command-line arguments

Differential Revision: https://phabricator.services.mozilla.com/D158811
2022-10-07 19:22:45 +00:00
Bob Owen 3dd8f8e969 Bug 1782199: Unregister the WER runtime module before returning from main. r=gsvelto
Differential Revision: https://phabricator.services.mozilla.com/D153728
2022-08-08 12:05:00 +00:00
Bob Owen f29f23d58b Bug 1682520 p2: Register the WER Runtime Exception Module very early in process start up. r=gsvelto,glandium
Depends on D152198

Differential Revision: https://phabricator.services.mozilla.com/D152199
2022-08-02 10:41:14 +00:00
Bob Owen d6333678d8 Bug 1682520 p1: Move GeckoProcessType and implementation of get and set into mozglue. r=glandium
This means we can set and use the process type earlier in process startup.

Differential Revision: https://phabricator.services.mozilla.com/D152198
2022-08-02 10:41:14 +00:00
Cristian Tuns 85e845a6dc Backed out 2 changesets (bug 1682520) for causing build bustages on ProcessType.h CLOSED TREE
Backed out changeset 679e19334225 (bug 1682520)
Backed out changeset dad72c7e0d7b (bug 1682520)
2022-07-29 17:04:49 -04:00
Bob Owen edb40ba976 Bug 1682520 p2: Register the WER Runtime Exception Module very early in process start up. r=gsvelto,glandium
Depends on D152198

Differential Revision: https://phabricator.services.mozilla.com/D152199
2022-07-29 18:10:54 +00:00
Bob Owen cf59d0973b Bug 1682520 p1: Move GeckoProcessType and implementation of get and set into separate files. r=glandium
This means we can include these files in other binaries when we need earlier
access to the process type and use consistent code.

Differential Revision: https://phabricator.services.mozilla.com/D152198
2022-07-29 18:10:53 +00:00
Alexandre Lissy 9c3474ae19 Bug 1775263 - Block cyinjct.dll from being injected in Utility r=haik,handyman
Differential Revision: https://phabricator.services.mozilla.com/D150595
2022-07-22 13:47:58 +00:00
Haik Aftandilian 4591ba72b4 Bug 1770484 - Make Mac processes not depend on DYLD_LIBRARY_PATH to load libraries r=glandium,gsvelto,mac-reviewers,necko-reviewers,dragana,spohl
Change XUL and other dylibs to be built with an @rpath/<dylib> install name (LC_ID_DYLIB) instead of @executable_path/<dylib>.

Change executables to be built with an @rpath dyld search path set to @executable_path by default so that @rpath/<dylib> dylibs in the same directory can be resolved. For executables not in the same directory as @rpath dylibs, such as plugin-container, set a relative @rpath such as @executable_path/../../../.

Previously, dylib install names were set as @executable_path/<dylib> allowing them to be resolved by dyld for the loading executable if the executable resided in the same directory as the dylib. For executables not in the same directory as the dylibs, dyld resolved these dylibs using DYLD_LIBRARY_PATH set before launching the process by Firefox code. With this change, loading does not rely on DYLD environment variables. Instead, dylibs have an install name set as @rpath/<dylib> and each executable loading a dylib has its @rpath set at compile-time to refer to dylib directory.

Differential Revision: https://phabricator.services.mozilla.com/D147360
2022-06-03 21:14:01 +00:00
Gabriele Svelto ff9bbb3d27 Bug 1678152 - Catch all stack overflows on Linux r=jld
This patch adds a library that contains an interposer function for
pthread_create(). The interposer will setup an alternate signal stack to
handle crashes - thus enabling us to catch stack overflows - and then call the
real pthread_create() function. Since the interposer needs to appear in the
linker's search order before libpthread we manually link it into firefox,
plugin-container and xpcshell's executables ASAP.

Differential Revision: https://phabricator.services.mozilla.com/D132736
2022-01-28 07:29:26 +00:00
Mike Hommey 1acc37c7a6 Bug 1747756 - Move Windows system libraries from LIBS to moz.build. r=firefox-build-system-reviewers,mhentges
While mingw builds don't require user32 and advapi32 explicitly, it doesn't
hurt for them to be there (and they're required for clang-cl build).
Likewise, while clang-builds don't require uuid and userenv explicitly
because they're pulled in via #pragmas in the source code, mingw doesn't
support those #pragmas and needs them explicitly, which doesn't hurt the
clang-cl builds.

Differential Revision: https://phabricator.services.mozilla.com/D134737
2021-12-30 20:56:43 +00:00
Iulian Moraru b469802d84 Backed out changeset 7f9b4b6191ad (bug 1747756) for causing multiple failures. CLOSED TREE 2021-12-30 01:59:26 +02:00
Mike Hommey cb50a5444f Bug 1747756 - Move Windows system libraries from LIBS to moz.build. r=firefox-build-system-reviewers,mhentges
While mingw builds don't require user32 and advapi32 explicitly, it doesn't
hurt for them to be there (and they're required for clang-cl build).
Likewise, while clang-builds don't require uuid and userenv explicitly
because they're pulled in via #pragmas in the source code, mingw doesn't
support those #pragmas and needs them explicitly, which doesn't hurt the
clang-cl builds.

Differential Revision: https://phabricator.services.mozilla.com/D134737
2021-12-29 22:18:52 +00:00
Mike Hommey 004902cee7 Bug 1747228 - Don't link mozsandbox into plugin-container or firefox. r=firefox-build-system-reviewers,andi
In optimized builds, it's stripped out at link time, because it's been
unused since bug 1505445 moved the sandbox initialization into libxul.
But in non-optimized builds, it's not, and that pulls in CoreFoundation
symbols, but we're not linking plugin-container against CoreFoundation
(we do link firefox to it for other uses).

This wasn't a problem before bug 1747160 because we were linking
everything against CoreFoundation (indirectly).

Differential Revision: https://phabricator.services.mozilla.com/D134587
2021-12-23 20:31:14 +00:00
Bob Owen b2d767fbb9 Bug 1716024 p2: Flag all binaries apart from firefox, xpcshell and plugin-container as CET compatible. r=glandium
We will only run the processes in CET compatible modules only mode when not
using the JIT code. So marking xul.dll as compatible should be OK.

Differential Revision: https://phabricator.services.mozilla.com/D117551
2021-07-19 07:36:19 +00:00
Aaron Klotz 004362bf3e Bug 1690384: Propagate error information up through XPCOMGlueLoad and GetBootstrap; r=glandium
We know that some GV installations (particularly but not exlcusively Focus) are
failing to load `libxul.so` during early Gecko bootstrapping. Unfortunately
a boolean pass/fail result is not giving us sufficient information to be able to
properly troubleshoot this problem.

This patch adds `mozilla::Result`-based return values to `XPCOMGlueLoad` and
`GetBootstrap` in an effort to produce more actionable information about these
failures.

We include either a `nsresult` or, if the failure is rooted in a dynamic linker
failure, appropriate platform-specific error information:

* On Unix-based platforms, a `UniqueFreePtr<char>` containing the string from `dlerror(3)`;
* On Windows, the Win32 `DWORD` error code from `GetLastError()`.

For non-Android platforms, I updated them to handle the new return type, but
otherwise did not make any further changes.

For Android, we include the error information in the message string that we pass
into the Java `Exception` that is subsequently thrown.

Differential Revision: https://phabricator.services.mozilla.com/D104263
2021-02-23 23:25:22 +00:00
Mike Hommey 53fee2f4c4 Bug 1675437 - Use preprocessor to create Info.plist files. r=firefox-build-system-reviewers,mhentges
While we're in the vicinity, change the manual preprocessing of
Info.plist.in to uses of the preprocessor.

Differential Revision: https://phabricator.services.mozilla.com/D96014
2020-11-05 15:03:47 +00:00
Mike Hommey ead183252e Bug 1675437 - Avoid using iconv to create InfoPlist.strings. r=firefox-build-system-reviewers,mhentges
Since python creates little-endian utf-16 consistently whether
cross-compiling from Linux or compiling natively on macOS, we could
write a small script that essentially replaces iconv. On the other hand,
we're also doing some manual preprocessing on the InfoPlist.strings.in
files, and we might as well use the preprocessor for that.

So, we augment the preprocessor to allow an explicit output encoding
other than utf-8, and use the preprocessor instead of `sed | iconv`.

Differential Revision: https://phabricator.services.mozilla.com/D96013
2020-11-05 15:07:30 +00:00
Ricky Stewart 02a7b4ebdf Bug 1654103: Standardize on Black for Python code in `mozilla-central`.
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Make some ad-hoc manual updates to `testing/marionette/client/setup.py`, `testing/marionette/harness/setup.py`, and `testing/firefox-ui/harness/setup.py`, which have hard-coded regexes that break after the reformat.

5. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-26 18:34:53 +00:00
Bogdan Tara da1098d4aa Backed out 10 changesets (bug 1654103, bug 1672023, bug 1518999) for PanZoomControllerTest.touchEventForResult gv-junit failures CLOSED TREE
Backed out changeset ff3fb0b4a512 (bug 1672023)
Backed out changeset e7834b600201 (bug 1654103)
Backed out changeset 807893ca8069 (bug 1518999)
Backed out changeset 13e6b92440e9 (bug 1518999)
Backed out changeset 8b2ac5a6c98a (bug 1518999)
Backed out changeset 575748295752 (bug 1518999)
Backed out changeset 65f07ce7b39b (bug 1518999)
Backed out changeset 4bb80556158d (bug 1518999)
Backed out changeset 8ac8461d7bd7 (bug 1518999)
Backed out changeset e8ba13ee17f5 (bug 1518999)
2020-10-24 03:36:18 +03:00
Ricky Stewart c0cea3b0fa Bug 1654103: Standardize on Black for Python code in `mozilla-central`. r=remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers,devtools-backward-compat-reviewers,jgilbert,preferences-reviewers,sylvestre,maja_zf,webcompat-reviewers,denschub,ntim,whimboo,sparky
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Make some ad-hoc manual updates to `testing/marionette/client/setup.py`, `testing/marionette/harness/setup.py`, and `testing/firefox-ui/harness/setup.py`, which have hard-coded regexes that break after the reformat.

5. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-23 20:40:42 +00:00
Dorel Luca 1ff59cb7a3 Backed out changeset 7558c8821a07 (bug 1654103) for multiple failures. CLOSED TREE 2020-10-22 03:51:06 +03:00
Ricky Stewart 50762dacab Bug 1654103: Standardize on Black for Python code in `mozilla-central`. r=remote-protocol-reviewers,marionette-reviewers,webdriver-reviewers,perftest-reviewers,devtools-backward-compat-reviewers,jgilbert,preferences-reviewers,sylvestre,maja_zf,webcompat-reviewers,denschub,ntim,whimboo,sparky
Allow-list all Python code in tree for use with the black linter, and re-format all code in-tree accordingly.

To produce this patch I did all of the following:

1. Make changes to tools/lint/black.yml to remove include: stanza and update list of source extensions.

2. Run ./mach lint --linter black --fix

3. Make some ad-hoc manual updates to python/mozbuild/mozbuild/test/configure/test_configure.py -- it has some hard-coded line numbers that the reformat breaks.

4. Add a set of exclusions to black.yml. These will be deleted in a follow-up bug (1672023).

# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D94045
2020-10-21 21:27:27 +00:00
Stephen A Pohl de3ad3747b Bug 1634765: Drop support for (and prevent from running on) macOS versions below 10.12. r=haik
Differential Revision: https://phabricator.services.mozilla.com/D73516
2020-06-11 19:28:25 +00:00
Ryan VanderMeulen 96581380fe Backed out changeset 454c8a5739ac (bug 1634765) so an intent to deprecate email can be sent out first.
CLOSED TREE
2020-06-11 15:24:33 -04:00
Stephen A Pohl 35ee005dee Bug 1634765: Drop support for (and prevent from running on) macOS versions below 10.12. r=haik
Differential Revision: https://phabricator.services.mozilla.com/D73516
2020-06-11 15:41:46 +00:00
Stephen A Pohl 4be18f0f0e Bug 1578917: Force macOS Aqua appearance on for content processes, crash reporter and updater. r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D70783
2020-04-24 18:37:57 +00:00
Toshihito Kikuchi 8bb38652d4 Bug 1603974 - Part 1: Implement nt::VirtualQuery consuming only ntdll.dll. r=mhowell
This patch introduces `nt::VirtualQuery` which consumes only ntdll's functions
to reduce dependency in `MMPolicy` on kernel32.dll.  With this, `MMPolicy` still
depends on kernel32.dll, that will be solved by a coming patch.

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

--HG--
extra : moz-landing-system : lando
2020-04-08 14:27:01 +00:00
Daniel Varga 2617f15d0c Backed out 8 changesets (bug 1603974) for causing build bustage
CLOSED TREE

Backed out changeset ee3fb8271709 (bug 1603974)
Backed out changeset 28ef741f8f65 (bug 1603974)
Backed out changeset 631725404fb8 (bug 1603974)
Backed out changeset 484a45d16149 (bug 1603974)
Backed out changeset 5d4cd3237ec0 (bug 1603974)
Backed out changeset c2601b5bdd3e (bug 1603974)
Backed out changeset fe96d48d5b14 (bug 1603974)
Backed out changeset 9467dffe8d04 (bug 1603974)
2020-04-07 18:35:04 +03:00
Toshihito Kikuchi 18f97f01b8 Bug 1603974 - Part 1: Implement nt::VirtualQuery consuming only ntdll.dll. r=mhowell
This patch introduces `nt::VirtualQuery` which consumes only ntdll's functions
to reduce dependency in `MMPolicy` on kernel32.dll.  With this, `MMPolicy` still
depends on kernel32.dll, that will be solved by a coming patch.

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

--HG--
extra : moz-landing-system : lando
2020-04-07 14:40:14 +00:00