[webkit-changes] [WebKit/WebKit] 2953e9: BlobURLHandle doesn't work as intended for opaque ...

Chris Dumez noreply at github.com
Wed Sep 7 09:29:01 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 2953e9903dd4e68d615bdcd2047d1adbcbe2c816
      https://github.com/WebKit/WebKit/commit/2953e9903dd4e68d615bdcd2047d1adbcbe2c816
  Author: Chris Dumez <cdumez at apple.com>
  Date:   2022-09-07 (Wed, 07 Sep 2022)

  Changed paths:
    M LayoutTests/imported/w3c/web-platform-tests/FileAPI/url/sandboxed-iframe-expected.txt
    M Source/WebCore/fileapi/ThreadableBlobRegistry.cpp

  Log Message:
  -----------
  BlobURLHandle doesn't work as intended for opaque origin Blob URLs
https://bugs.webkit.org/show_bug.cgi?id=244862

Reviewed by Darin Adler.

BlobURLHandle doesn't work as intended for opaque origin Blob URLs. This is
causing some of the subtests in imported/w3c/web-platform-tests/FileAPI/url/sandboxed-iframe.html
to fail in WebKit.

The issue is that the SecurityOrigin of an opaque-origin blob URL gets stored
in a OriginMap inside ThreadableBlobOrigin. When the blob URL would later get
revoked, we would remove its origin from the OriginMap, without checking if
there are any BlobURLHandles keeping the blob alive.

* LayoutTests/imported/w3c/web-platform-tests/FileAPI/url/sandboxed-iframe-expected.txt:
* Source/WebCore/fileapi/ThreadableBlobRegistry.cpp:
(WebCore::blobURLReferencesMap):
(WebCore::unregisterBlobURLOriginIfNecessary):
(WebCore::ThreadableBlobRegistry::registerBlobURL):
(WebCore::ThreadableBlobRegistry::unregisterBlobURL):
(WebCore::ThreadableBlobRegistry::registerBlobURLHandle):
(WebCore::ThreadableBlobRegistry::unregisterBlobURLHandle):

Canonical link: https://commits.webkit.org/254238@main




More information about the webkit-changes mailing list