Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 6248fa7145849f04f88e49a8a08ee6172b6bb9fe
https://github.com/WebKit/WebKit/commit/6248fa7145849f04f88e49a8a08ee6172b6bb9fe
Author: Patrick Griffis <[email protected]>
Date: 2026-08-17 (Mon, 17 Aug 2026)
Changed paths:
M LayoutTests/TestExpectations
A
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-timing-001.tentative.https-expected.txt
A
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-timing-002.tentative.https-expected.txt
A
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-imagesrcset.tentative.https-expected.txt
A
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-link-connect-src-nonce.tentative.https-expected.txt
A
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-link-connect-src.tentative.https-expected.txt
A
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-link-element-crossorigin.tentative.https-expected.txt
A
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-link-element-events.tentative.https-expected.txt
A
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-link-integrity.tentative.https-expected.txt
A
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-link-referrer-and-referrerpolicy.tentative.https-expected.txt
A
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-type-attribute.tentative.https-expected.txt
A
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/fetch-destination.tentative.https-expected.txt
M Source/WTF/Scripts/Preferences/UnifiedWebPreferences.yaml
M Source/WebCore/Modules/fetch/FetchRequestDestination.idl
M Source/WebCore/dom/Document.cpp
M Source/WebCore/dom/Document.h
M Source/WebCore/html/HTMLLinkElement.cpp
M Source/WebCore/html/LinkRelAttribute.cpp
M Source/WebCore/html/LinkRelAttribute.h
M Source/WebCore/loader/FetchOptions.h
M Source/WebCore/loader/FetchOptionsDestination.h
M Source/WebCore/loader/LinkLoader.cpp
M Source/WebCore/loader/LinkLoader.h
M Source/WebCore/loader/cache/CachedResourceLoader.cpp
M Source/WebKit/NetworkProcess/NetworkLoadChecker.cpp
M Source/WebKit/NetworkProcess/NetworkResourceLoader.cpp
M Source/WebKit/Shared/WebCoreArgumentCoders.serialization.in
Log Message:
-----------
Fetch dictionaries declared by rel=compression-dictionary and Link headers
https://bugs.webkit.org/show_bug.cgi?id=321527
Reviewed by Alex Christensen.
Add a runtime flag for Compression Dictionary Transport, handle the
"compression-dictionary" link, and fetch its resource. All described
from whatwg/html#11620
The fetch uses the new "compression-dictionary" destination from
whatwg/fetch#1854, is governed by the connect-src CSP directive,
and is always a CORS fetch. Changing crossorigin on the element re-fetches.
Dictionary fetches should not compete with the page's critical-path loads, and
the spec allows delaying them. Those declared by a <link> element are held in
Document until the load event has been dispatched; a link added after that
point is queued straight away.
Link headers on subresources do not register dictionaries at all.
Nothing is done with the fetched resource yet; storing dictionaries and
using them to decompress responses comes later.
* LayoutTests/TestExpectations:
*
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-timing-001.tentative.https-expected.txt:
Added.
*
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-timing-002.tentative.https-expected.txt:
Added.
*
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-imagesrcset.tentative.https-expected.txt:
Added.
*
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-link-connect-src-nonce.tentative.https-expected.txt:
Added.
*
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-link-connect-src.tentative.https-expected.txt:
Added.
*
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-link-element-crossorigin.tentative.https-expected.txt:
Added.
*
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-link-element-events.tentative.https-expected.txt:
Added.
*
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-link-integrity.tentative.https-expected.txt:
Added.
*
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-link-referrer-and-referrerpolicy.tentative.https-expected.txt:
Added.
*
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/dictionary-fetch-with-type-attribute.tentative.https-expected.txt:
Added.
*
LayoutTests/imported/w3c/web-platform-tests/fetch/compression-dictionary/fetch-destination.tentative.https-expected.txt:
Added.
* Source/WTF/Scripts/Preferences/UnifiedWebPreferences.yaml:
* Source/WebCore/Modules/fetch/FetchRequestDestination.idl:
* Source/WebCore/dom/Document.cpp:
(WebCore::Document::dispatchWindowLoadEvent):
(WebCore::Document::queueCompressionDictionaryLoad):
(WebCore::Document::flushPendingCompressionDictionaryLoads):
* Source/WebCore/dom/Document.h:
* Source/WebCore/html/HTMLLinkElement.cpp:
(WebCore::HTMLLinkElement::attributeChanged):
(WebCore::HTMLLinkElement::process):
* Source/WebCore/html/LinkRelAttribute.cpp:
* Source/WebCore/html/LinkRelAttribute.h:
* Source/WebCore/loader/FetchOptions.h:
* Source/WebCore/loader/FetchOptionsDestination.h:
* Source/WebCore/loader/LinkLoader.cpp:
(WebCore::LinkLoader::~LinkLoader):
(WebCore::LinkLoader::loadCompressionDictionariesFromHeader):
(WebCore::LinkLoader::resourceTypeFromAsAttribute):
(WebCore::LinkLoader::cancelLoad):
(WebCore::LinkLoader::loadCompressionDictionaryIfNeeded):
(WebCore::LinkLoader::loadCompressionDictionaryLink):
* Source/WebCore/loader/LinkLoader.h:
* Source/WebCore/loader/cache/CachedResourceLoader.cpp:
(WebCore::CachedResourceLoader::allowedByContentSecurityPolicy const):
* Source/WebCore/loader/cache/CachedResourceLoader.h:
* Source/WebKit/NetworkProcess/NetworkLoadChecker.cpp:
(WebKit::NetworkLoadChecker::isAllowedByContentSecurityPolicy):
* Source/WebKit/NetworkProcess/NetworkResourceLoader.cpp:
(WebKit::NetworkResourceLoader::resourceLoadInfo):
* Source/WebKit/Shared/WebCoreArgumentCoders.serialization.in:
Canonical link: https://commits.webkit.org/319327@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications