Changeset 287970 in webkit
- Timestamp:
- Jan 12, 2022, 7:23:40 PM (5 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 6 edited
-
LayoutTests/ChangeLog (modified) (1 diff)
-
LayoutTests/http/tests/privateClickMeasurement/triggering-event-with-attribution-source-through-fetch-keepalive-ephemeral-expected.txt (added)
-
LayoutTests/http/tests/privateClickMeasurement/triggering-event-with-attribution-source-through-fetch-keepalive-ephemeral.html (added)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/loader/PrivateClickMeasurement.cpp (modified) (1 diff)
-
Source/WebCore/loader/PrivateClickMeasurement.h (modified) (1 diff)
-
Source/WebKit/ChangeLog (modified) (1 diff)
-
Source/WebKit/NetworkProcess/NetworkSession.cpp (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r287966 r287970 1 2022-01-12 John Wilander <wilander@apple.com> 2 3 PCM: Same-site triggering events should support ephemeral measurement 4 https://bugs.webkit.org/show_bug.cgi?id=235160 5 <rdar://87423294> 6 7 Reviewed by Alex Christensen. 8 9 * http/tests/privateClickMeasurement/triggering-event-with-attribution-source-through-fetch-keepalive-ephemeral-expected.txt: Added. 10 * http/tests/privateClickMeasurement/triggering-event-with-attribution-source-through-fetch-keepalive-ephemeral.html: Added. 11 1 12 2022-01-12 Diego Pino Garcia <dpino@igalia.com> 2 13 -
trunk/Source/WebCore/ChangeLog
r287969 r287970 1 2022-01-12 John Wilander <wilander@apple.com> 2 3 PCM: Same-site triggering events should support ephemeral measurement 4 https://bugs.webkit.org/show_bug.cgi?id=235160 5 <rdar://87423294> 6 7 Reviewed by Alex Christensen. 8 9 We added ephemeral measurement for direct response advertising in https://bugs.webkit.org/show_bug.cgi?id=228984. 10 We added support for same-site triggering events in https://bugs.webkit.org/show_bug.cgi?id=233173. 11 These two features should work together. 12 13 The bug was that WebKit::NetworkSession::handlePrivateClickMeasurementConversion() 14 only checked for cross-site triggering events when handling ephemeral measurements. 15 16 Test: http/tests/privateClickMeasurement/triggering-event-with-attribution-source-through-fetch-keepalive-ephemeral.html 17 18 * loader/PrivateClickMeasurement.cpp: 19 (WebCore::PrivateClickMeasurement::isNeitherSameSiteNorCrossSiteTriggeringEvent): 20 New convenience function to enhance readability in 21 WebKit::NetworkSession::handlePrivateClickMeasurementConversion(). 22 * loader/PrivateClickMeasurement.h: 23 1 24 2022-01-12 Andres Gonzalez <andresg_22@apple.com> 2 25 -
trunk/Source/WebCore/loader/PrivateClickMeasurement.cpp
r286519 r287970 125 125 } 126 126 127 bool PrivateClickMeasurement::isNeitherSameSiteNorCrossSiteTriggeringEvent(const RegistrableDomain& redirectDomain, const URL& firstPartyURL, const AttributionTriggerData& attributionTriggerData) 128 { 129 auto isSameSiteTriggeringEvent = redirectDomain.matches(firstPartyURL) && attributionTriggerData.sourceRegistrableDomain; 130 if (isSameSiteTriggeringEvent) 131 return false; 132 auto isCrossSiteTriggeringEvent = sourceSite().registrableDomain == redirectDomain && !attributionTriggerData.sourceRegistrableDomain; 133 return !isCrossSiteTriggeringEvent; 134 } 135 127 136 Expected<PrivateClickMeasurement::AttributionTriggerData, String> PrivateClickMeasurement::parseAttributionRequestQuery(const URL& redirectURL) 128 137 { -
trunk/Source/WebCore/loader/PrivateClickMeasurement.h
r286519 r287970 379 379 380 380 WEBCORE_EXPORT static const Seconds maxAge(); 381 WEBCORE_EXPORT bool isNeitherSameSiteNorCrossSiteTriggeringEvent(const RegistrableDomain& redirectDomain, const URL& firstPartyURL, const AttributionTriggerData&); 381 382 WEBCORE_EXPORT static Expected<AttributionTriggerData, String> parseAttributionRequest(const URL& redirectURL); 382 383 WEBCORE_EXPORT AttributionSecondsUntilSendData attributeAndGetEarliestTimeToSend(AttributionTriggerData&&, IsRunningLayoutTest); -
trunk/Source/WebKit/ChangeLog
r287967 r287970 1 2022-01-12 John Wilander <wilander@apple.com> 2 3 PCM: Same-site triggering events should support ephemeral measurement 4 https://bugs.webkit.org/show_bug.cgi?id=235160 5 <rdar://87423294> 6 7 Reviewed by Alex Christensen. 8 9 We added ephemeral measurement for direct response advertising in https://bugs.webkit.org/show_bug.cgi?id=228984. 10 We added support for same-site triggering events in https://bugs.webkit.org/show_bug.cgi?id=233173. 11 These two features should work together. 12 13 * NetworkProcess/NetworkSession.cpp: 14 (WebKit::NetworkSession::handlePrivateClickMeasurementConversion): 15 This function previously only checked for cross-site triggering events when 16 handling ephemeral measurements. Now it also checks for same-site triggering 17 events. 18 1 19 2022-01-12 Fujii Hironori <Hironori.Fujii@sony.com> 2 20 -
trunk/Source/WebKit/NetworkProcess/NetworkSession.cpp
r287781 r287970 373 373 374 374 // Ephemeral measurement can only have one pending click. 375 if (ephemeralMeasurement. sourceSite().registrableDomain != redirectDomain)375 if (ephemeralMeasurement.isNeitherSameSiteNorCrossSiteTriggeringEvent(redirectDomain, firstPartyForCookies, attributionTriggerData)) 376 376 return; 377 377 if (ephemeralMeasurement.destinationSite().registrableDomain != RegistrableDomain(firstPartyForCookies))
Note:
See TracChangeset
for help on using the changeset viewer.