ResourceHandler: cookies not created during POST request

Having problems with building or using CEF's C/C++ APIs? This forum is here to help. Please do not post bug reports or feature requests here.

ResourceHandler: cookies not created during POST request

Postby Czarek » Thu Jul 17, 2014 8:32 am

I've added response filtering support by implementing ResourceHandler (with the use of URLRequest/URLRequestClient, see https://code.google.com/p/chromiumembed ... ?id=515#c6). There is a problem with creating cookies during POST requests. Cookies are working fine when created during GET requests (on server-side). Creating this same cookie during POST request doesn't work. Tested the same php script that creates the cookie in Google Chrome and it works fine. Could this be a bug in CEF? POST requests are working fine when using ResourceHandler, cookies in GET requests too, so it's only a case with cookies during POST requests.

Using CEF 3 branch 1547 rev. 1491 on Ubuntu.
I will be upgrading to branch 1650 soon, is there a chance that this is fixed there?

Thanks for help.
Maintainer of the CEF Python, PHP Desktop and CEF C API projects. My LinkedIn.
User avatar
Czarek
Virtuoso
 
Posts: 1927
Joined: Sun Nov 06, 2011 2:12 am

Re: ResourceHandler: cookies not created during POST request

Postby magreenblatt » Fri Jul 18, 2014 10:40 am

Czarek wrote:I will be upgrading to branch 1650 soon, is there a chance that this is fixed there?

I would suggest upgrading to 1916 branch. 1650 is already out of support and a new branch will be cut in the next few weeks.

Are you setting the UR_FLAG_ALLOW_CACHED_CREDENTIALS and UR_FLAG_ALLOW_COOKIES flags on the CefRequest?
magreenblatt
Site Admin
 
Posts: 12408
Joined: Fri May 29, 2009 6:57 pm

Re: ResourceHandler: cookies not created during POST request

Postby Czarek » Fri Jul 18, 2014 12:04 pm

magreenblatt wrote:Are you setting the UR_FLAG_ALLOW_CACHED_CREDENTIALS and UR_FLAG_ALLOW_COOKIES flags on the CefRequest?

Adding these flags solved the problem. Thank you.
Maintainer of the CEF Python, PHP Desktop and CEF C API projects. My LinkedIn.
User avatar
Czarek
Virtuoso
 
Posts: 1927
Joined: Sun Nov 06, 2011 2:12 am


Return to Support Forum

Who is online

Users browsing this forum: No registered users and 53 guests