Issue #2542 - Part 2: Base implementation of Sec-Fetch-* header code.

Currently following Mozilla putting stuff in /dom for additional porting,
but it's actually the wrong location since it belongs in /netwerk with
the other code that deals with http headers.
This commit is contained in:
Moonchild 2024-07-03 11:00:53 +02:00 committed by roytam1
commit 8076de8965
5 changed files with 341 additions and 0 deletions

View file

@ -99,6 +99,7 @@
#include "CacheControlParser.h"
#include "nsMixedContentBlocker.h"
#include "CacheStorageService.h"
#include "mozilla/dom/SecFetch.h"
namespace mozilla { namespace net {
@ -380,6 +381,8 @@ nsHttpChannel::Connect()
NS_LITERAL_CSTRING("1"), false);
NS_ENSURE_SUCCESS(rv, rv);
}
mozilla::dom::SecFetch::AddSecFetchHeader(this);
bool isHttps = false;
rv = mURI->SchemeIs("https", &isHttps);