Commit graph

2109 commits

Author SHA1 Message Date
Cosmin Sabou
86c3cf58d6 Backed out changeset 9866ca157a60 (bug 1894995) for causing several xpcshell failures. 2024-05-23 00:35:42 +03:00
Iulian Moraru
3d5936348b Backed out changeset 9a295c851c2e (bug 1895232) for causing multiple failures. CLOSED TREE 2024-05-22 21:03:20 +03:00
Sean
3cbf13bd8f Bug 1895232 - Convert do_GetService to using components::*::service in netwerk/ r=valentin,cookie-reviewers,places-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D209747
2024-05-22 17:13:29 +00:00
Sean
2e06dec110 Bug 1897209 - Migrate HTTP_ONSTART_SUSPEND_TOTAL_TIME probe to glean r=valentin,necko-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D210707
2024-05-22 15:16:02 +00:00
Sean
eb86e72321 Bug 1894995 - Remove deprecated nslCacheEntry methods and their implementations r=valentin,necko-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D209460
2024-05-22 15:12:48 +00:00
Kershaw Chang
76f79470e9 Bug 968273 - Only persist permanent redirects for HTTPS, r=necko-reviewers,jesup
Differential Revision: https://phabricator.services.mozilla.com/D210483
2024-05-21 09:28:49 +00:00
sunil mayya
7a167bac96 Bug 1883496 - add X-Search-Subdivision assignment for android. r=necko-reviewers,android-reviewers,geckoview-reviewers,valentin,gl,owlish,Roger
Differential Revision: https://phabricator.services.mozilla.com/D208349
2024-05-21 08:01:36 +00:00
Sean
a7cc2c512a Bug 1890554 - Use ProxyInfo::TRANSPARENT_PROXY_RESOLVES_HOST flag in nsHttpChannel::GetProxyDNSStrategy r=manuel,necko-reviewers,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D209875
2024-05-17 14:07:19 +00:00
Natalia Csoregi
173d5cf3e7 Backed out changeset 8abbf422db5c (bug 1894995) for causing bustage on nsHttpChannel.cpp CLOSED TREE 2024-05-17 12:52:02 +03:00
Sean
f0b9488bb5 Bug 1894995 - Remove deprecated nslCacheEntry methods and their implementations r=valentin,necko-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D209460
2024-05-17 09:21:38 +00:00
Aron Cseh
fdfa4bc02c Backed out changeset ddd4b7cfd119 (bug 968273) for causing high frequency mochitest failures on browser_bug968273.js CLOSED TREE 2024-05-17 02:52:49 +03:00
Kershaw Chang
4bd1a86fd4 Bug 968273 - Only persist permanent redirects for HTTPS, r=necko-reviewers,jesup
Differential Revision: https://phabricator.services.mozilla.com/D210483
2024-05-16 20:43:27 +00:00
Valentin Gosu
784c29f1fe Bug 1895226 - Skip HTTPS record when connectivity checker indicates it is blocked r=necko-reviewers,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D209532
2024-05-08 07:49:32 +00:00
Thomas Wisniewski
2f1da72bdd Bug 1893257 - don't overwrite pragma or cache-control request headers per spec, and otherwise always set cache-control:max-age=0 for no-cache cache mode; r=valentin,necko-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D208634
2024-04-26 16:21:41 +00:00
Valentin Gosu
622e7e0067 Bug 1888815 - Do not set the NS_HTTP_REFRESH_DNS flag unless force-reloading the page r=necko-reviewers,jesup
This flag was previously being set for every page reload.
Only setting it for force-reload makes it so that we don't needlessly refresh
DNS cache entries and improves page load performance.

Differential Revision: https://phabricator.services.mozilla.com/D208141
2024-04-24 21:32:22 +00:00
Valentin Gosu
0e97d24398 Bug 1849686 - Refactor nsHttpChannel to add all headers before dispatching transaction r=necko-reviewers,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D207430
2024-04-17 09:02:58 +00:00
Randell Jesup
22df14537c Bug 1871963: Implement zstd content-encoding support r=necko-reviewers,valentin,devtools-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D205109
2024-04-09 15:26:46 +00:00
Tamas Szentpeteri
1f27a4022f Backed out 3 changesets (bug 1871963) for causing dt failures on browser_net_copy_as_powershell.js. CLOSED TREE
Backed out changeset 94e286542c9d (bug 1871963)
Backed out changeset dc2ad0369b86 (bug 1871963)
Backed out changeset 9fb8ccb2f305 (bug 1871963)
2024-04-09 17:24:37 +03:00
Randell Jesup
b1ad40b8ee Bug 1871963: Implement zstd content-encoding support r=necko-reviewers,valentin
Differential Revision: https://phabricator.services.mozilla.com/D205109
2024-04-09 12:31:56 +00:00
dylan
b3b70f1193 Bug 1865394 - added urgency and incremental to request header in netmonitor. r=necko-reviewers,extension-reviewers,devtools-reviewers,valentin,robwu,bomsy,webdriver-reviewers,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D201265
2024-03-21 14:29:26 +00:00
Randell Jesup
066055e41e Bug 1356686 - Do decompression off main thread in content r=necko-reviewers,valentin,extension-reviewers,robwu
Content processes will now always retarget delivery of OnDataAvailable for Http
channels off the main thread. Consumers that were previously redirecting
off-main thread are not affected and their retargeting will stick, but any
Httpchannel that was not retargeted off the main thread will be retargeted to
the nsIStreamTransportService.

If the listener for nsHTTPCompressConv cannot be called off the main thread (ie
the call to nsIRetargetableRequest::CheckListenerChain would fail),
nsHTTPCompressConv will be called off main thread but dispatch its decoded data
back to the main thread.

Differential Revision: https://phabricator.services.mozilla.com/D191377
2024-03-19 17:27:22 +00:00
Sandor Molnar
a764c03b7c Backed out 4 changesets (bug 1356686) for causing build bustages @ netwerk/protocol/http/HttpChannelChild.cpp CLOSED TREE
Backed out changeset 63dc52c69902 (bug 1356686)
Backed out changeset 6e9726c26d07 (bug 1356686)
Backed out changeset 3b150d676b31 (bug 1356686)
Backed out changeset 54754a50d992 (bug 1356686)
2024-03-19 08:29:08 +02:00
Randell Jesup
ff7576cfea Bug 1356686 - Do decompression off main thread in content r=necko-reviewers,valentin,extension-reviewers,robwu
Content processes will now always retarget delivery of OnDataAvailable for Http
channels off the main thread. Consumers that were previously redirecting
off-main thread are not affected and their retargeting will stick, but any
Httpchannel that was not retargeted off the main thread will be retargeted to
the nsIStreamTransportService.

If the listener for nsHTTPCompressConv cannot be called off the main thread (ie
the call to nsIRetargetableRequest::CheckListenerChain would fail),
nsHTTPCompressConv will be called off main thread but dispatch its decoded data
back to the main thread.

Differential Revision: https://phabricator.services.mozilla.com/D191377
2024-03-18 20:04:01 +00:00
Mark Banner
3d5bb40f49 Bug 1884623 - Update more jsm references in production code and docs in misc code. r=mossop,necko-reviewers,profiler-reviewers,julienw,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D204185
2024-03-14 17:42:28 +00:00
Sandor Molnar
09d9822ba8 Backed out 3 changesets (bug 1884623) for causing multiple failures CLOSED TREE
Backed out changeset 3a264233ce8e (bug 1884623)
Backed out changeset acdf8a83a49c (bug 1884623)
Backed out changeset de64ce832b8a (bug 1884623)
2024-03-14 17:03:37 +02:00
Mark Banner
fcaf27c6e1 Bug 1884623 - Update more jsm references in production code and docs in misc code. r=mossop,necko-reviewers,profiler-reviewers,julienw,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D204185
2024-03-14 12:18:01 +00:00
Butkovits Atila
640d8aa060 Backed out changeset d1d9d57a9895 (bug 1865394) for causing failures at browser_net_har_copy_all_as_har.js. CLOSED TREE 2024-03-13 21:04:58 +02:00
dylan
f01e37b32b Bug 1865394 - added urgency and incremental to request header in netmonitor. r=necko-reviewers,extension-reviewers,devtools-reviewers,valentin,robwu,bomsy
Differential Revision: https://phabricator.services.mozilla.com/D201265
2024-03-13 17:03:22 +00:00
Valentin Gosu
589e6de8c6 Bug 1884645 - Add NS_HTTP_ON_BEFORE_STOP_REQUEST_TOPIC r=necko-reviewers,kershaw
This notification would be sent by HttpChannelChild before
calling onStopRequest for a channel.

This patch also updates some comments regarding the on stop topic
which referenced the non-existent http-on-stop-connect

Differential Revision: https://phabricator.services.mozilla.com/D204482
2024-03-13 11:50:06 +00:00
Cristina Horotan
3de7656ede Backed out changeset 74b319e23e72 (bug 1849686) for causing wpt failures at cross-origin-subresource-redirect-with-fp-delegation.https.html CLOSED TREE 2024-03-08 00:03:57 +02:00
Valentin Gosu
88d0f48eeb Bug 1849686 - Add http-on-dispatching-transaction event r=necko-reviewers,kershaw
While the http-on-before-connect event is dispatched before
the DNS resolution had completed, it was apparent that the channel also
set multiple headers and flags during nsHttpChannel::SetupTransaction
when the transaction was actually dispatched. This meant that
any JS consumers that were looking to suspend or cancel the channel
based on various headers would not have the full set of headers available
when receiving the http-on-before-connect notification.

This patch adds a new http-on-dispatching-transaction notification that
is emitted just before the transaction is dispatched to the socket thread.

Differential Revision: https://phabricator.services.mozilla.com/D199333
2024-03-07 16:03:32 +00:00
Emilio Cobos Álvarez
d39e78a02e Bug 1883435 - Don't include GleanMetrics.h from Document.h. r=chutten,necko-reviewers,valentin
In bug 1883435 comment 2 chutten mentions that including
nsGlobalWindowInner.h from GleanMetrics.h causes a stylo build failure.

This is because nsGlobalWindowInner.h itself brings a bunch of DOM
bindings template soup that bindgen isn't great at dealing with.

That can be fixed in various ways. However, there is a simpler fix,
which is not including GleanMetrics at all.

It's trivial to do, and given it's a massive autogenerated file, and
Document.h is a very common header, it's worth doing this if only for
build times.

Fix a bunch of unused includes while at it.

Differential Revision: https://phabricator.services.mozilla.com/D203625
2024-03-05 17:54:14 +00:00
Marten Richter
ca85c42741 Bug 1873263 - WebTransport: Fix serverCertificateHashes Implementation r=kershaw,necko-reviewers,keeler
The current serverCertificateHashes implementation does not follow the
WebTransport specification, that introduced serverCertificateHashes
as a tool to replace certificate chain verification.
Instead it introduced the hashes as an additional check.
This patch moves the check to the Http3Session object and modifies
the connection manager' hashes to prevent crossSite certificate
poisoning. It is - as the WebTransport Implementation in Firefox -
currently limited to http3 only.
However, since the hashes live on the ConnectionEntries,
it should be possible to extend this in the future.

Differential Revision: https://phabricator.services.mozilla.com/D197857
2024-03-05 10:39:29 +00:00
Sandor Molnar
72866aa04b Backed out changeset b2dd957f853b (bug 1873263) for causing xpc failures @ netwerk/test/unit/test_webtransport_simple.js CLOSED TREE 2024-03-04 14:35:05 +02:00
Marten Richter
5ef566ca7f Bug 1873263 - WebTransport: Fix serverCertificateHashes Implementation r=kershaw,necko-reviewers,keeler
The current serverCertificateHashes implementation does not follow the
WebTransport specification, that introduced serverCertificateHashes
as a tool to replace certificate chain verification.
Instead it introduced the hashes as an additional check.
This patch moves the check to the Http3Session object and modifies
the connection manager' hashes to prevent crossSite certificate
poisoning. It is - as the WebTransport Implementation in Firefox -
currently limited to http3 only.
However, since the hashes live on the ConnectionEntries,
it should be possible to extend this in the future.

Differential Revision: https://phabricator.services.mozilla.com/D197857
2024-03-04 10:54:09 +00:00
jackyzy823
df347be4ec Bug 1881883 - Remove debug print in OnProxyAvailable. r=necko-reviewers,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D202694
2024-02-26 12:21:20 +00:00
Randell Jesup
6d1644c5a8 Bug 1879936: don't ASSERT if the user overrides a cert error r=necko-reviewers,valentin
Differential Revision: https://phabricator.services.mozilla.com/D202267
2024-02-21 15:12:26 +00:00
Manuel Bucher
789fbdb7a4 Bug 1879848 - Record telemetry for which Proxy types are used r=necko-reviewers,jesup
Differential Revision: https://phabricator.services.mozilla.com/D201384
2024-02-21 11:00:50 +00:00
Thomas Wisniewski
60d61a23d9 Bug 1854695 - do not redirect on HTTP 300 status code; r=valentin,necko-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D201746
2024-02-19 22:40:04 +00:00
pstanciu
5da2feef04 Backed out changeset 32a53e4ded84 (bug 1849686) as requested by Aryx for possibly causing Bug 1879917. a=backout 2024-02-14 17:49:24 +02:00
Valentin Gosu
2b77b5392d Bug 1854621 - Remove unused necko probes r=necko-reviewers,kershaw
- Remove CACHE_SERVICE_LOCK_WAIT_* as they are no longer referenced
- Remove HTTP_OFFLINE_CACHE_DOCUMENT_LOAD as it's no longer useful - appcache got removed

Differential Revision: https://phabricator.services.mozilla.com/D201067
2024-02-12 13:49:33 +00:00
Valentin Gosu
4cc9a70b51 Bug 1849686 - Add http-on-dispatching-transaction event r=necko-reviewers,kershaw
While the http-on-before-connect event is dispatched before
the DNS resolution had completed, it was apparent that the channel also
set multiple headers and flags during nsHttpChannel::SetupTransaction
when the transaction was actually dispatched. This meant that
any JS consumers that were looking to suspend or cancel the channel
based on various headers would not have the full set of headers available
when receiving the http-on-before-connect notification.

This patch adds a new http-on-dispatching-transaction notification that
is emitted just before the transaction is dispatched to the socket thread.

Differential Revision: https://phabricator.services.mozilla.com/D199333
2024-02-12 12:21:44 +00:00
Andrew Creskey
f7508e6207 Bug 1876776 - Create a glean probe for http response version r=necko-reviewers,kershaw
Create a new glean probe for http response version so that we can collect on android, and also we'll collect on release.

Differential Revision: https://phabricator.services.mozilla.com/D199764
2024-02-08 17:47:18 +00:00
sunil mayya
940f43938d Bug 1871533 - clear nsHttpChannel::mTransactionSticky after connect. r=necko-reviewers,valentin
While debugging 1871533 we found out that the new transactions were not dispatched as the pending queue had 6 active connections.
The connections (although were marked as DONT reuse) were not cleared from the pending queue because sticky transactions were still holding their references.

Differential Revision: https://phabricator.services.mozilla.com/D199863
2024-02-07 22:52:19 +00:00
Tim Huang
949f77d58f Bug 1877405 - Adding a eVarietyRequestEnforceDefault to nsHttpHeaderArray::HeaderVariety r=necko-reviewers,devtools-reviewers,bomsy,kershaw
Adding a new HeaderVariety called eVarietyRequestEnforceDefault. It
allows setting request header value as default even even if the header
exists.

We need this to setting default header value without changing the order
of the header.

Differential Revision: https://phabricator.services.mozilla.com/D199991
2024-01-31 22:09:11 +00:00
Kershaw Chang
c9e6b63ceb Bug 1873898 - Migrate HTTPS RR probes to glean, r=necko-reviewers,valentin
Differential Revision: https://phabricator.services.mozilla.com/D198147
2024-01-23 13:10:52 +00:00
Tim Huang
925645c429 Bug 1849864 - Don't recalculate the userAgent header if it has been modified. r=tjr,jesup,necko-reviewers,devtools-reviewers
The userAgent header can be modified in several ways, such as using the
header field to set a custom userAgent header for a fetch request. We
want to preserve the custom header, so we shouldn't recalculate the
userAgent header if it's been overridden after the channel was created.
Otherwise, the custom header won't work.

Differential Revision: https://phabricator.services.mozilla.com/D197655
2024-01-17 13:18:21 +00:00
Tim Huang
a2deaaa213 Bug 1849864 - Update the userAgent header once the AntiTracking Info is updated. r=tjr,necko-reviewers,jesup
The userAgent was decided when the channel was created, but the channel
hasn't known about whether it should exempt fingerprinting protection at
the moment. To properly set the userAgent, we need to update the
userAgent header once we know the AntiTracking info.

Differential Revision: https://phabricator.services.mozilla.com/D196953
2024-01-17 13:18:20 +00:00
Iulian Moraru
8ecc4d2b75 Backed out 2 changesets (bug 1849864) for causing multiple failures. CLOSED TREE
Backed out changeset c57d859580d0 (bug 1849864)
Backed out changeset 8a5a6b997e2a (bug 1849864)
2024-01-16 19:39:56 +02:00
Tim Huang
18a9840783 Bug 1849864 - Don't recalculate the userAgent header if it has been modified. r=tjr,jesup,necko-reviewers,devtools-reviewers
The userAgent header can be modified in several ways, such as using the
header field to set a custom userAgent header for a fetch request. We
want to preserve the custom header, so we shouldn't recalculate the
userAgent header if it's been overridden after the channel was created.
Otherwise, the custom header won't work.

Differential Revision: https://phabricator.services.mozilla.com/D197655
2024-01-16 16:06:34 +00:00