Commit graph

587 commits

Author SHA1 Message Date
Jari Jalkanen
0182792f58 Bug 1878137 - Defer reporting declined IDB storage access to method calls. r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D207268
2024-05-08 14:29:53 +00:00
Paul Zuehlcke
8bcbe1d3a1 Bug 1848406 - Keep track of storage access in web workers. r=bvandersloot,asuth
Differential Revision: https://phabricator.services.mozilla.com/D203640
2024-04-17 20:29:05 +00:00
Norisz Fay
189fed6949 Backed out 15 changesets (bug 1843308, bug 1889444, bug 1888504, bug 1890546, bug 1888500, bug 1848406, bug 1890782) for causing bustage on BounceTrackingProtection.h CLOSED TREE
Backed out changeset 09168636f92e (bug 1890782)
Backed out changeset 45c9c902f35f (bug 1889444)
Backed out changeset 7cd441010547 (bug 1889444)
Backed out changeset 692d3fb54e2c (bug 1890546)
Backed out changeset 4c476414499a (bug 1843308)
Backed out changeset fc70ef415bfe (bug 1888504)
Backed out changeset e400fe8e13ac (bug 1888500)
Backed out changeset 336738f93085 (bug 1888500)
Backed out changeset 40fdfaf3cc32 (bug 1848406)
Backed out changeset 6a3ec1f62811 (bug 1848406)
Backed out changeset 5ea32ea95f62 (bug 1848406)
Backed out changeset df982722bc0a (bug 1848406)
Backed out changeset 6808ec37fa93 (bug 1848406)
Backed out changeset 36b8e78cc27e (bug 1848406)
Backed out changeset d63358e762de (bug 1848406)
2024-04-11 23:07:40 +03:00
Paul Zuehlcke
4d4f0f28fa Bug 1848406 - Keep track of storage access in web workers. r=bvandersloot,asuth
Differential Revision: https://phabricator.services.mozilla.com/D203640
2024-04-11 19:03:16 +00:00
Sandor Molnar
29d972749f Backed out 12 changesets (bug 1843308, bug 1848406, bug 1888500, bug 1888504, bug 1890546) for causing AddressSanitizer @ xpcom/base/nsISupportsImpl.cpp & bc failures @ toolkit/components/antitracking/bouncetrackingprotection/test/browser/<...> CLOSED TREE
Backed out changeset 4537591cca64 (bug 1890546)
Backed out changeset b29ebdf1439e (bug 1843308)
Backed out changeset 7c22cf88677f (bug 1888504)
Backed out changeset b85173dc6c16 (bug 1888500)
Backed out changeset 02d68d4511c7 (bug 1888500)
Backed out changeset 42ab5bd4b856 (bug 1848406)
Backed out changeset 6ce0fba99d02 (bug 1848406)
Backed out changeset affbf180e519 (bug 1848406)
Backed out changeset 80365ce68377 (bug 1848406)
Backed out changeset d75faab0301f (bug 1848406)
Backed out changeset 940c5fd39d25 (bug 1848406)
Backed out changeset 31016e129e99 (bug 1848406)
2024-04-10 22:10:33 +03:00
Paul Zuehlcke
42d8f5425f Bug 1848406 - Keep track of storage access in web workers. r=bvandersloot,asuth
Differential Revision: https://phabricator.services.mozilla.com/D203640
2024-04-10 14:12:39 +00:00
Emilio Cobos Álvarez
e4ddf24147 Bug 1887719 - More consistently use UTF8String/nsCString for URLs. r=necko-reviewers,webidl,anti-tracking-reviewers,places-reviewers,jari,kershaw,janv,smaug,hsivonen
Sorry for the massive patch but I found it hard to split without
introducing a bunch of copies around...

This mostly makes necko and DOM agree on which strings to use, which
should result on less copies and conversions.

Differential Revision: https://phabricator.services.mozilla.com/D205601
2024-04-04 11:49:57 +00:00
Mirko Brodesser
6384e462ba Bug 1882498: add web API stubs for Trusted Types guarded behind a new pref. r=smaug,peterv
The TODOs corresponding to the stubs will be implemented in separate
patches.

Differential Revision: https://phabricator.services.mozilla.com/D202930
2024-03-13 08:24:18 +00:00
Jan de Mooij
5656ba3a2d Bug 1848771 part 1 - Stop eagerly initializing JS standard classes for non-Window globals. r=peterv
For non-Window globals we pass `true` for `aInitStandardClasses` which results in
`CreateGlobal` calling `JS::InitRealmStandardClasses`.

This affects performance and memory usage and likely isn't necessary. It's also
nicer to not have this difference in behavior.

Differential Revision: https://phabricator.services.mozilla.com/D186216
2024-01-23 15:06:32 +00:00
Kagami Sascha Rosylight
406c01bc16 Bug 1862244 - Add GlobalTeardownHelper r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D193295
2023-11-23 17:17:39 +00:00
Tom Schuster
4d69d8826a Bug 1857431 - Use xpc::InitGlobalObjectOptions for Workers. r=dom-worker-reviewers,smaug
This introduces two slight changes of behavior:
- Workers with a system principal are now always treated as secure context, without looking at the mIsSecureContext flag.
- We now also discard sources for all types of workers with a system principal

Differential Revision: https://phabricator.services.mozilla.com/D190282
2023-10-13 08:46:32 +00:00
Emilio Cobos Álvarez
25c0d10932 Bug 1624819 - Remove TaskCategory and other quantum dom remnants. r=smaug,media-playback-reviewers,credential-management-reviewers,cookie-reviewers,places-reviewers,win-reviewers,valentin,mhowell,sgalich,alwu
Sorry this is not a particularly easy patch to review. But it should be
mostly straight-forward.

I kept Document::Dispatch mostly for convenience, but could be
cleaned-up too / changed by SchedulerGroup::Dispatch. Similarly maybe
that can just be NS_DispatchToMainThread if we add an NS_IsMainThread
check there or something (to preserve shutdown semantics).

Differential Revision: https://phabricator.services.mozilla.com/D190450
2023-10-10 08:51:12 +00:00
Nika Layzell
1fdee2314c Bug 1839920 - Rename Get{ASCII,UTF}Origin to GetWebExposedOriginSerialization, r=smaug,necko-reviewers,anti-tracking-reviewers,bvandersloot,jesup
This should make uses of the type more clearly indicating where the
origin came from, and should help avoid potential confusion between this
origin and nsIPrincipal::origin in new code.

This new name is long, but explicit. The string returned from this
function corresponds to the "serialization of an origin" from the WHATWG
html spec:
https://html.spec.whatwg.org/multipage/browsers.html#ascii-serialisation-of-an-origin

Differential Revision: https://phabricator.services.mozilla.com/D181794
2023-06-27 19:59:15 +00:00
Tom Schuster
2b402cbc3b Bug 1834744 - Go back to having WorkerPrivate::ShouldResistFingerprinting. r=tjr
Differential Revision: https://phabricator.services.mozilla.com/D179960
2023-06-07 10:52:30 +00:00
Eden Chuang
ea1bf2603a Bug 1800659 - P3 Remove WorkerPrivate::ClearMainEventQueue() r=asuth,smaug
Pending->Canceling->Killing (WorkerNeverRan)

Need to clear WorkerPrivate::mPreStartRunnables

Could we call WorkerRunnable::WorkerRun() to release resource? There could be no WorkerGlobalScope...

Pending->Running->Closing->Canceling->Killing(WorkerRan)
Pending->Running->Canceling->Killing(WorkerRan)

When entering “Closing”
1. Keeping receives normal WorkerRunnables
2. Making ParentStatus as Closing
3. Cancel all timeout
4. Don’t clear the main event queue anymore. But we still wait for all SyncLoops be completed.
5. Call WorkerGlobalScope::NoteTerminating() and nsIGlobalObject::DisconnectEventTargetObjects().
6. Switching to “Canceling” by asking parent thread to call WorkerPrivate::Cancel()

When entering “Canceling”
1. Call WorkerGlobalScope::NoteTerminating()
2. Notify StrongWorkerRefs, worker is in “Canceling”, send and complete the corresponding shutdown work right now.
3. Executing all runnables until no normal WorkerRunnables in queue and no WorkerRefs, SyncLoops and children workers
4. Stop receiving normal WorkerRunnables and DisconnectEventTargetObjects of WorkerScope.
4. Entering “Killing”

When entering “Killing”
1. We would not notify WorkerRefs anymore. Logically all WorkerRefs should be released in “Canceling”
2. Executing all remaining ControlRunnables
3. Release corresponding resources of Worker on worker thread.

Depends on D173850

Differential Revision: https://phabricator.services.mozilla.com/D177511
2023-06-06 06:36:50 +00:00
Eden Chuang
a800135b31 Bug 1800659 - P1 Adding log for Worker. r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D176915
2023-06-06 06:36:50 +00:00
Tom Schuster
7dd038775a Bug 1834737 - Make RFPTarget parameter of WorkerGlobalScopeBase::ShouldResistFingerprinting non-optional. r=tjr
Differential Revision: https://phabricator.services.mozilla.com/D179208
2023-05-31 09:46:54 +00:00
Emilio Cobos Álvarez
d27874678a Bug 1811950 - Allow WorkerGlobalScope.fonts to fail. r=aosmond,webidl,saschanaz
It can fail when canceling the worker (though I couldn't reproduce the
crash locally). Some things were already accounting for it.

Rename some things for consistency.

Differential Revision: https://phabricator.services.mozilla.com/D175126
2023-04-11 13:44:53 +00:00
Tom Ritter
4b30551afe Bug 1815307: Make all ShouldRFP functions take a RTPTarget r=timhuang
The default value for the target is Unknown, so all callsites
keep working.

We also add a Target value used for Document precomputation. This
value is enabled in RFP Lite mode, and allows us to precompute
ShouldRFP and cache it for faster computations later.  (The later
computations will still check the Target, but won't need to do the
other expensive checks.)

Differential Revision: https://phabricator.services.mozilla.com/D170891
2023-03-21 14:14:48 +00:00
Cristina Horotan
d376603a21 Backed out 7 changesets (bug 1815307) for causing mochitest failures at test_bug1729861.html CLOSED TREE
Backed out changeset 18c8ae091952 (bug 1815307)
Backed out changeset df49c162e4ad (bug 1815307)
Backed out changeset a22d49909ffa (bug 1815307)
Backed out changeset 371d1d626984 (bug 1815307)
Backed out changeset 7f4b594cf468 (bug 1815307)
Backed out changeset 83d79fcbded5 (bug 1815307)
Backed out changeset 337dfbf6a1f9 (bug 1815307)
2023-03-16 17:51:56 +02:00
Tom Ritter
73c477c80e Bug 1815307: Make all ShouldRFP functions take a RTPTarget r=timhuang
The default value for the target is Unknown, so all callsites
keep working.

We also add a Target value used for Document precomputation. This
value is enabled in RFP Lite mode, and allows us to precompute
ShouldRFP and cache it for faster computations later.  (The later
computations will still check the Target, but won't need to do the
other expensive checks.)

Differential Revision: https://phabricator.services.mozilla.com/D170891
2023-03-16 13:53:13 +00:00
Nazım Can Altınova
3c14a0bff0 Bug 1812368 - Truncate the URLs we are passing into profiler markers r=julienw
Differential Revision: https://phabricator.services.mozilla.com/D169053
2023-02-09 10:16:51 +00:00
Yulia Startsev
56c6f79308 Bug 1247687 - Implement InitModuleLoader methods for WorkerScriptLoader and WorkerGlobalScope; r=jonco
This implements a method to initialize the moduleLoader for workers. This will initialize only once, for all worker types (module and classic).

Depends on D147324

Differential Revision: https://phabricator.services.mozilla.com/D147326
2023-01-18 13:46:29 +00:00
Nika Layzell
8332c88faa Bug 1806709 - Part 2: Clean up some trivial nsIPrincipal helper methods from nsIGlobalObject, r=asuth
These methods only existed because nsIGlobalObject::PrincipalOrNull was not
available off-main-thread, so can now be removed.

Depends on D165198

Differential Revision: https://phabricator.services.mozilla.com/D165199
2022-12-21 15:53:22 +00:00
Norisz Fay
8cf029b070 Backed out 15 changesets (bug 1247687) as requested by dev CLOSED TREE
Backed out changeset 81d052cabf84 (bug 1247687)
Backed out changeset d698041e5174 (bug 1247687)
Backed out changeset 2adf67f910e8 (bug 1247687)
Backed out changeset 0bc871906e97 (bug 1247687)
Backed out changeset 1700d5b79273 (bug 1247687)
Backed out changeset 31888ffde37a (bug 1247687)
Backed out changeset 9153182c650d (bug 1247687)
Backed out changeset 45de9ffeec19 (bug 1247687)
Backed out changeset 59207e959b7c (bug 1247687)
Backed out changeset 49f18430c465 (bug 1247687)
Backed out changeset 0ae1fd421d4f (bug 1247687)
Backed out changeset 7770ec4717fd (bug 1247687)
Backed out changeset 68b476066248 (bug 1247687)
Backed out changeset c94a9dc60dff (bug 1247687)
Backed out changeset 0ab366c6eaaf (bug 1247687)
2022-12-21 10:48:15 +02:00
Yulia Startsev
e859be10b8 Bug 1247687 - Implement InitModuleLoader methods for WorkerScriptLoader and WorkerGlobalScope; r=jonco
This implements a method to initialize the moduleLoader for workers. This will initialize only once, for all worker types (module and classic).

Depends on D147324

Differential Revision: https://phabricator.services.mozilla.com/D147326
2022-12-20 20:56:12 +00:00
Csoregi Natalia
c382c6a7ca Backed out 16 changesets (bug 1247687) for frequent string bundle related crashes with PDF viewer (bug 1806064). a=backout
Backed out changeset 721f612fd09f (bug 1247687)
Backed out changeset c6c5750cf713 (bug 1247687)
Backed out changeset 5d05ab0c7cde (bug 1247687)
Backed out changeset 2429599729cb (bug 1247687)
Backed out changeset 55f13fb4ee3f (bug 1247687)
Backed out changeset 354711cf113a (bug 1247687)
Backed out changeset 40b8abaf1c0b (bug 1247687)
Backed out changeset 0c9650a1ac48 (bug 1247687)
Backed out changeset e7b103c79b1a (bug 1247687)
Backed out changeset 4dbd510fb042 (bug 1247687)
Backed out changeset 9276c7e1ddd9 (bug 1247687)
Backed out changeset 6ee318df6641 (bug 1247687)
Backed out changeset 6c129bd72b61 (bug 1247687)
Backed out changeset 4b0a4fcc6894 (bug 1247687)
Backed out changeset 34680059b9f0 (bug 1247687)
Backed out changeset 85b827971a48 (bug 1247687)
2022-12-17 11:27:32 +02:00
Yulia Startsev
a40b702d6e Bug 1247687 - Implement InitModuleLoader methods for WorkerScriptLoader and WorkerGlobalScope; r=jonco
This implements a method to initialize the moduleLoader for workers. This will initialize only once, for all worker types (module and classic).

Depends on D147324

Differential Revision: https://phabricator.services.mozilla.com/D147326
2022-12-14 14:55:35 +00:00
Nika Layzell
8351f7cc2d Bug 1804093 - Part 5: Eliminate WorkerPrincipal and WorkletPrincipals, r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D163856
2022-12-12 22:08:36 +00:00
Nika Layzell
6c15719086 Bug 1804093 - Part 2: Remove some values cached from nsIPrincipal from WorkerLoadInfo, r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D163853
2022-12-12 22:08:35 +00:00
Eden Chuang
0943e68b5e Bug 1752856 - Null CheckedUnsafePtr<WorkerPrivate> for members of WorkerGlobalScope when releaseing WorkerPrivate. r=dom-worker-reviewers,asuth,smaug
In some unusual cases, WorkerGlobalScope could live longer than WorkerPrivate since some other objects hold a reference on WorkerGlobalScope. We try to use CC/GC to release WorkerGlobalScope and force disconnect them from the WorkerPrivate before releasing WorkerPrivate. https://searchfox.org/mozilla-central/rev/83b86005c6913c2062419efb8aabdf2e683aa47f/dom/workers/RuntimeService.cpp#2068-2109

The previous implementation focused on nulling the WorkerGlobalScopeBase::mWorkerPrivate. However, it is not enough since WorkerGlobalScope's member could possibly hold a CheckedUnsafePtr<WorkerPrivate>, i.e. WorkerGlobalScope::mPerformance.

In this patch, we focus on breaking these connections.

Differential Revision: https://phabricator.services.mozilla.com/D162575
2022-11-30 14:27:51 +00:00
Jan Varga
e95f3b4eec Bug 1791867 - Add GetStorageManager to nsIGlobalObject; r=smaug,dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D157902
2022-11-30 09:51:14 +00:00
Tom Ritter
c89f44794d Bug 1778510: Update the WorkerScope Vsync method to use fine-grained RFP information r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D151309
2022-11-29 13:34:16 +00:00
Tom Ritter
39b2fec75c Bug 1778510: Add RTPCallerType to GlobalObject r=asuth
This centralizes the logic in one place.

In order to do this, we will need to check the principal
off-main thread. (Well, we need to know if it's System
Principal.)  Worker and Worklet need special ways to do
this, so create a virtual method for it and let them
override it.  This is analogous to the ShouldRFP method
on GlobalObject.

Differential Revision: https://phabricator.services.mozilla.com/D157564
2022-11-29 13:34:15 +00:00
Tom Ritter
803ad112c2 Bug 1778510: Move shouldRFP from WorkerPrivate to WorkerGlobalScopeBase r=asuth
This does not remove mShouldResistFingerprinting from
WorkerPrivate->mLoadInfo.  This is because in between
mLoadInfo getting initialized (including where shouldRFP gets
set) and when the worker's global scope is constructed, we
need to keep track of whether we shouldRFP or not.  We could
make this single bool an outparam of GetLoadInfo to later
pass to GetOrCreateGlobalScope, but that seems noisy.

Differential Revision: https://phabricator.services.mozilla.com/D157563
2022-11-29 13:34:12 +00:00
Butkovits Atila
cb853b7f77 Backed out 33 changesets (bug 1778510) for causing build bustages at nsIGlobalObject.h. CLOSED TREE
Backed out changeset f2a53c9e497c
Backed out changeset 59350ca6f3f2 (bug 1778510)
Backed out changeset abbba7e72b57 (bug 1778510)
Backed out changeset 6cf7473afae8 (bug 1778510)
Backed out changeset 74fb5fed93ea (bug 1778510)
Backed out changeset 5b5dc70cdd0a (bug 1778510)
Backed out changeset ff93191cafd2 (bug 1778510)
Backed out changeset 39cc006b610c (bug 1778510)
Backed out changeset dfaef3ad17a9 (bug 1778510)
Backed out changeset 8fbabeb8244b (bug 1778510)
Backed out changeset 45051b62e3f1 (bug 1778510)
Backed out changeset 86c0923fd81f (bug 1778510)
Backed out changeset a49c0f69d519 (bug 1778510)
Backed out changeset cfad733d4aaf (bug 1778510)
Backed out changeset df6d0fe89d5b (bug 1778510)
Backed out changeset 704db76eab17 (bug 1778510)
Backed out changeset 0651c128e369 (bug 1778510)
Backed out changeset 1e650de647c0 (bug 1778510)
Backed out changeset fa15a3572741 (bug 1778510)
Backed out changeset 4ceffd409eae (bug 1778510)
Backed out changeset 47db43142c62 (bug 1778510)
Backed out changeset ebb21153aaac (bug 1778510)
Backed out changeset a87eaaec3f9c (bug 1778510)
Backed out changeset 43ad5ee21f79 (bug 1778510)
Backed out changeset 5f20af8e1263 (bug 1778510)
Backed out changeset b78576875db0 (bug 1778510)
Backed out changeset d801fdeac90b (bug 1778510)
Backed out changeset 5af032c628c0 (bug 1778510)
Backed out changeset 86aa59de11b4 (bug 1778510)
Backed out changeset 58642357a19c (bug 1778510)
Backed out changeset c575e824e291 (bug 1778510)
Backed out changeset 32a358de4843 (bug 1778510)
Backed out changeset 40e0708c01e7 (bug 1778510)
2022-11-28 23:14:52 +02:00
Tom Ritter
c30a2c6a5f Bug 1778510: Update the WorkerScope Vsync method to use fine-grained RFP information r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D151309
2022-11-28 18:04:08 +00:00
Tom Ritter
d54e4c9877 Bug 1778510: Add RTPCallerType to GlobalObject r=asuth
This centralizes the logic in one place.

In order to do this, we will need to check the principal
off-main thread. (Well, we need to know if it's System
Principal.)  Worker and Worklet need special ways to do
this, so create a virtual method for it and let them
override it.  This is analogous to the ShouldRFP method
on GlobalObject.

Differential Revision: https://phabricator.services.mozilla.com/D157564
2022-11-28 18:04:07 +00:00
Tom Ritter
0812bb2e5b Bug 1778510: Move shouldRFP from WorkerPrivate to WorkerGlobalScopeBase r=asuth
This does not remove mShouldResistFingerprinting from
WorkerPrivate->mLoadInfo.  This is because in between
mLoadInfo getting initialized (including where shouldRFP gets
set) and when the worker's global scope is constructed, we
need to keep track of whether we shouldRFP or not.  We could
make this single bool an outparam of GetLoadInfo to later
pass to GetOrCreateGlobalScope, but that seems noisy.

Differential Revision: https://phabricator.services.mozilla.com/D157563
2022-11-28 18:04:05 +00:00
Cosmin Sabou
d245f666b9 Backed out 33 changesets (bug 1778510) for causing bp-hybrid bustages on nsIPrincipal.h. CLOSED TREE
Backed out changeset 282f589ede4a
Backed out changeset e23d03ba5a89 (bug 1778510)
Backed out changeset cbdb34cf7c8d (bug 1778510)
Backed out changeset d9a54521f3fb (bug 1778510)
Backed out changeset f5b7f8ce38b0 (bug 1778510)
Backed out changeset eb64607765a9 (bug 1778510)
Backed out changeset 18291e692834 (bug 1778510)
Backed out changeset bb71cc94a8be (bug 1778510)
Backed out changeset 507e84e1dafe (bug 1778510)
Backed out changeset 6d42e7a083ac (bug 1778510)
Backed out changeset 53799e6a46dd (bug 1778510)
Backed out changeset ff20d709839a (bug 1778510)
Backed out changeset 328d4d2df591 (bug 1778510)
Backed out changeset 9ba44fd8a440 (bug 1778510)
Backed out changeset eb1b7e30e519 (bug 1778510)
Backed out changeset c0927de6153b (bug 1778510)
Backed out changeset 02a306acd093 (bug 1778510)
Backed out changeset 2c5eecc4ad4c (bug 1778510)
Backed out changeset 38a9f45c9621 (bug 1778510)
Backed out changeset 35b7c7df62ce (bug 1778510)
Backed out changeset 187d71f42593 (bug 1778510)
Backed out changeset 450f4ccd6cd0 (bug 1778510)
Backed out changeset 915149e27da0 (bug 1778510)
Backed out changeset 9c6e85369f15 (bug 1778510)
Backed out changeset c6a9fe0ce713 (bug 1778510)
Backed out changeset a2f00462157e (bug 1778510)
Backed out changeset 5278e40b80c3 (bug 1778510)
Backed out changeset dba220581d93 (bug 1778510)
Backed out changeset 17a63044b0dc (bug 1778510)
Backed out changeset 68d607aaa121 (bug 1778510)
Backed out changeset e93004f91f6f (bug 1778510)
Backed out changeset 41d6d9f889e1 (bug 1778510)
Backed out changeset 28ac62019086 (bug 1778510)
2022-11-28 07:34:46 +02:00
Tom Ritter
8af8993421 Bug 1778510: Update the WorkerScope Vsync method to use fine-grained RFP information r=asuth
Differential Revision: https://phabricator.services.mozilla.com/D151309
2022-11-28 04:21:27 +00:00
Tom Ritter
3e82dba9f2 Bug 1778510: Add RTPCallerType to GlobalObject r=asuth
This centralizes the logic in one place.

In order to do this, we will need to check the principal
off-main thread. (Well, we need to know if it's System
Principal.)  Worker and Worklet need special ways to do
this, so create a virtual method for it and let them
override it.  This is analogous to the ShouldRFP method
on GlobalObject.

Differential Revision: https://phabricator.services.mozilla.com/D157564
2022-11-28 04:21:26 +00:00
Tom Ritter
d3041242a7 Bug 1778510: Move shouldRFP from WorkerPrivate to WorkerGlobalScopeBase r=asuth
This does not remove mShouldResistFingerprinting from
WorkerPrivate->mLoadInfo.  This is because in between
mLoadInfo getting initialized (including where shouldRFP gets
set) and when the worker's global scope is constructed, we
need to keep track of whether we shouldRFP or not.  We could
make this single bool an outparam of GetLoadInfo to later
pass to GetOrCreateGlobalScope, but that seems noisy.

Differential Revision: https://phabricator.services.mozilla.com/D157563
2022-11-28 04:21:24 +00:00
Jan Varga
b1055977ce Bug 1798773 - Always shutdown FileSystemManager; r=dom-worker-reviewers,smaug
Differential Revision: https://phabricator.services.mozilla.com/D162200
2022-11-24 13:58:38 +00:00
Jan Varga
f40ce49b02 Bug 1790207 - Forward declaration of mozilla::Result in nsIGlobalObject.h and other cleanup; r=dom-storage-reviewers,jesup
Depends on D162087

Differential Revision: https://phabricator.services.mozilla.com/D162088
2022-11-15 17:13:02 +00:00
Jan Varga
7ce6e92fa1 Bug 1790207 - Change nsIGlobalObject::GetStorageKey to return NS_ERROR_NOT_AVAILABLE by default; r=dom-storage-reviewers,jesup,asuth
nsGlobalWindowInner, WorkerGlobalScopeBase, BackstagePas and SandboxPrivate now
explicitly provide GetStorageKey implementation which explicitly block null and
expanded principals. All other globals (nsGlobalWindowOuter, SimpleGlobalObject,
ShadowRealmGlobalScope and WorkletGlobalScope) inherit the default
implementation which returns NS_ERROR_NOT_AVAILABLE.

Differential Revision: https://phabricator.services.mozilla.com/D162087
2022-11-15 17:13:01 +00:00
Randell Jesup
229303901a Bug 1790207: Provide cross-origin security checks for OPFS r=nika,asuth
Differential Revision: https://phabricator.services.mozilla.com/D157892
2022-11-15 17:13:01 +00:00
Jan Varga
bccd6f0308 Bug 1786501 - Implement WorkerNavigator::Invalidate; r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D155371
2022-08-31 09:34:50 +00:00
Kagami Sascha Rosylight
32a02a7021 Bug 1784590 - Part 1: Remove hide_in_pbmode prefs r=asuth
It turns out that websites break with different reasons when hiding things. At this point we want to stop revising the hack further and instead gather the data about how many websites are currently affected.

Differential Revision: https://phabricator.services.mozilla.com/D154578
2022-08-24 10:58:46 +00:00
Marian-Vasile Laza
e32b8c70e9 Backed out 2 changesets (bug 1784590) for causing mochitest failures on test_privateBrowsing.html. CLOSED TREE
Backed out changeset cd284ba05fbb (bug 1784590)
Backed out changeset 2f714355a8c8 (bug 1784590)
2022-08-23 01:26:37 +03:00