Bug 107692

Summary: [Curl] There is no way for a WebKit client to set the Curl cookie jar path
Product: WebKit Reporter: peavo
Component: WebCore Misc.Assignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: ap, bfulgham, peavo, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: PC   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch
none
Patch none

peavo
Reported 2013-01-23 07:39:59 PST
There exists a method setCookieJarFileName() in WebCore\platform\network\curl\ResourceHandleManager.cpp, but noone uses it.
Attachments
Patch (1.62 KB, patch)
2013-01-23 07:46 PST, peavo
no flags
Patch (1.95 KB, patch)
2013-01-30 07:39 PST, peavo
no flags
Patch (1.95 KB, patch)
2013-01-31 07:25 PST, peavo
no flags
peavo
Comment 1 2013-01-23 07:46:23 PST
peavo
Comment 2 2013-01-25 08:01:52 PST
Setting the Curl cookie jar path makes Curl enable cookies, which is important for many sites to work.
peavo
Comment 3 2013-01-30 07:39:57 PST
peavo
Comment 4 2013-01-30 07:42:31 PST
Modified patch to set a default cookie jar path, this will enable the Curl cookie engine by default (and persistent cookies).
Brent Fulgham
Comment 5 2013-01-30 09:54:05 PST
Comment on attachment 185502 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=185502&action=review Thanks for working on this. I think it would be cleaner if you encapsulated this in a helper function (like I did with the "certificatePath"). Then we can provide port-specific logic for identifying where the cookie jar should live. > Source/WebCore/platform/network/curl/ResourceHandleManager.cpp:122 > + , m_cookieJarFileName("cookies.dat") I would prefer you write a helper function like "certificatePath" that encapsulates the identification of this cook jar. > Source/WebCore/platform/network/curl/ResourceHandleManager.cpp:137 > + m_cookieJarFileName = fastStrDup(cookieJarPath); This logic should go in the helper function. Then I can add a CF-variant without cluttering the code.
peavo
Comment 6 2013-01-31 07:25:55 PST
peavo
Comment 7 2013-01-31 07:27:21 PST
Modified patch according to review comments.
Brent Fulgham
Comment 8 2013-01-31 11:41:50 PST
Comment on attachment 185780 [details] Patch Looks great!
peavo
Comment 9 2013-01-31 12:32:44 PST
(In reply to comment #8) > (From update of attachment 185780 [details]) > Looks great! Thanks for the review ;)
WebKit Review Bot
Comment 10 2013-01-31 12:45:44 PST
Comment on attachment 185780 [details] Patch Clearing flags on attachment: 185780 Committed r141464: <http://trac.webkit.org/changeset/141464>
WebKit Review Bot
Comment 11 2013-01-31 12:45:48 PST
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.