Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: ee629dabaf61cdac72bad52e589b79c1de128b16
      
https://github.com/WebKit/WebKit/commit/ee629dabaf61cdac72bad52e589b79c1de128b16
  Author: Adrian Taylor <[email protected]>
  Date:   2026-09-02 (Wed, 02 Sep 2026)

  Changed paths:
    M Source/WebKit/UIProcess/FirstPartyAuthority.h

  Log Message:
  -----------
  [IPC] Do not derive a registrable domain that FirstPartyAuthority will discard
https://bugs.webkit.org/show_bug.cgi?id=323119

Reviewed by Zak Ridouh.

FirstPartyAuthority::checkUntrusted derived the registrable domain before the
guard that throws it away. Deriving one from an origin calls
PublicSuffixStore::topPrivatelyControlledDomain(), which takes a global lock,
looks the host up in a 128-entry cache with random eviction, isolatedCopy()s
the result, and on a miss consults the platform public suffix list.
checkUntrustedDomain() then returns immediately whenever site isolation is off
- every shipping configuration today - so that work was wasted on every
origin-bearing message that reaches a validated receiver.

checkUntrustedDomain() now takes the domain as a NOESCAPE function and calls it
only once it has decided the question is worth asking. The overloads that
already hold a domain hand it back by const reference, so nothing is copied for
them either.

No behaviour change: the same values reach the same checks with the same
answers.

* Source/WebKit/UIProcess/FirstPartyAuthority.h:
(WebKit::FirstPartyAuthority::checkUntrusted const):
(WebKit::FirstPartyAuthority::checkUntrustedDomain const):

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



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to