Changeset 295642 in webkit


Ignore:
Timestamp:
Jun 17, 2022, 12:06:35 PM (3 years ago)
Author:
achristensen@apple.com
Message:

New test: [macOS/iOS arm64] TestWebKitAPI.WKContentRuleListStoreTest.CrossOriginCookieBlocking is crashing
https://bugs.webkit.org/show_bug.cgi?id=241653

Reviewed by Yusuke Suzuki.

  • Tools/TestWebKitAPI/Tests/WebKitCocoa/WKContentExtensionStore.mm:

(TEST_F):

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

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Tools/TestWebKitAPI/Tests/WebKitCocoa/WKContentExtensionStore.mm

    r295473 r295642  
    225225                auto path = HTTPServer::parsePath(request);
    226226                auto response = [&] {
    227                     if (path == "/com"_s)
     227                    if (path == "/com"_s) {
     228#if CPU(ARM64E) && defined(NDEBUG)
     229                        // FIXME: This is exactly equivalent code, but the code below crashes on release builds on arm64e.
     230                        // See rdar://95391568
     231                        HashMap<String, String> headerFields;
     232                        headerFields.reserveInitialCapacity(1);
     233                        headerFields.add("Set-Cookie"_s, "testCookie=42; Path=/; SameSite=None; Secure"_s);
     234                        return HTTPResponse(WTFMove(headerFields), "<script>alert('hi')</script>"_s);
     235#else
    228236                        return HTTPResponse({ { "Set-Cookie"_s, "testCookie=42; Path=/; SameSite=None; Secure"_s } }, "<script>alert('hi')</script>"_s);
     237#endif
     238                    }
    229239                    if (path == "/org"_s)
    230240                        return HTTPResponse("<script>fetch('https://example.com/cookie-check', {credentials: 'include'})</script>"_s);
Note: See TracChangeset for help on using the changeset viewer.