WebKit Bugzilla
Attachment 340890 Details for
Bug 185838
: Web Automation: always return an empty cookie list if document.cookieURL() is empty
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-185838-20180521142002.patch (text/plain), 1.96 KB, created by
BJ Burg
on 2018-05-21 14:20:03 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
BJ Burg
Created:
2018-05-21 14:20:03 PDT
Size:
1.96 KB
patch
obsolete
>Subversion Revision: 232025 >diff --git a/Source/WebKit/ChangeLog b/Source/WebKit/ChangeLog >index 0c6056afd860756ceb07b79faaa3e7140c1331b6..b473100b17195ac75a39b62501fc1fba9aa14ec4 100644 >--- a/Source/WebKit/ChangeLog >+++ b/Source/WebKit/ChangeLog >@@ -1,3 +1,16 @@ >+2018-05-21 Brian Burg <bburg@apple.com> >+ >+ Web Automation: always return an empty cookie list if document.cookieURL() is empty >+ https://bugs.webkit.org/show_bug.cgi?id=185838 >+ <rdar://problem/37737526> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * WebProcess/Automation/WebAutomationSessionProxy.cpp: >+ (WebKit::WebAutomationSessionProxy::getCookiesForFrame): >+ This crashes in CFNetwork code because an empty cookie URL is not a valid input. >+ Just return an empty list since there couldn't be any cookies returned. >+ > 2018-05-21 Sihui Liu <sihui_liu@apple.com> > > Add a diskCacheSizeOverride accessor function on WKContextConfigurationRef >diff --git a/Source/WebKit/WebProcess/Automation/WebAutomationSessionProxy.cpp b/Source/WebKit/WebProcess/Automation/WebAutomationSessionProxy.cpp >index b4221647f5aecd72ea4cce27603b28587f81aa2a..1f8ac9b54c98ce51dea64e482e1b70664a6aa556 100644 >--- a/Source/WebKit/WebProcess/Automation/WebAutomationSessionProxy.cpp >+++ b/Source/WebKit/WebProcess/Automation/WebAutomationSessionProxy.cpp >@@ -751,7 +751,8 @@ void WebAutomationSessionProxy::getCookiesForFrame(uint64_t pageID, uint64_t fra > // This returns the same list of cookies as when evaluating `document.cookies` in JavaScript. > auto& document = *frame->coreFrame()->document(); > Vector<WebCore::Cookie> foundCookies; >- WebCore::getRawCookies(document, document.cookieURL(), foundCookies); >+ if (!document.cookieURL().isEmpty()) >+ WebCore::getRawCookies(document, document.cookieURL(), foundCookies); > > WebProcess::singleton().parentProcessConnection()->send(Messages::WebAutomationSession::DidGetCookiesForFrame(callbackID, foundCookies, String()), 0); > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 185838
: 340890