kryskool / cefpython

Automatically exported from code.google.com/p/cefpython
0 stars 1 forks source link

ResourceHandler: creating cookie during POST request fails (wxpython-response.py) #127

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Server-side cookies seem not to work when using custom resource handler. 
Client-side cookies created in javascript on the other hand are working fine.

Tested with the wxpython-response.py script that is distributed along with the 
Linux binaries.

Original issue reported on code.google.com by czarek.t...@gmail.com on 17 Jul 2014 at 12:08

GoogleCodeExporter commented 9 years ago
Creating server-side cookie during GET request works fine. The problem appears 
only when setting cookie during POST request.

Original comment by czarek.t...@gmail.com on 17 Jul 2014 at 1:10

GoogleCodeExporter commented 9 years ago
Reported problem on the CEF Forum:
http://www.magpcss.org/ceforum/viewtopic.php?f=6&t=11958

Original comment by czarek.t...@gmail.com on 17 Jul 2014 at 1:32

GoogleCodeExporter commented 9 years ago
Setting request flags to allow cookies solves the problem. In 
ResourceHandler.`ProcessRequest()` add these lines:

    request.SetFlags(cefpython.Request.Flags["AllowCachedCredentials"]\
                | cefpython.Request.Flags["AllowCookies"])

Original comment by czarek.t...@gmail.com on 18 Jul 2014 at 5:03

GoogleCodeExporter commented 9 years ago
Fixed in revision aa52a160ca30.

Original comment by czarek.t...@gmail.com on 28 Jul 2014 at 9:41