Message271901
The problem is similar to https://bugs.python.org/issue22931 with square brackets in cookie values.
Incorrect value is serialized JSON in this case, for example:
>>> from Cookie import SimpleCookie
>>> cookie = SimpleCookie()
>>> cookie.load('a=b; c={"somekey":"value"}; d=e, f=g, some=other')
>>> cookie.output()
'Set-Cookie: a=b'
>>>
From my tests I figured out that quote mark (") is causing problems.
In fact, according to HTTP specification, cookies can't be JSON objects, but I think that python library shouldn't silently allow incorrect values. Probably incorrect cookies should be skipped, or some exception should be thrown there. |
|
Date |
User |
Action |
Args |
2016-08-03 12:22:28 | Artur Smęt | set | recipients:
+ Artur Smęt |
2016-08-03 12:22:28 | Artur Smęt | set | messageid: <1470226948.72.0.0645301470223.issue27674@psf.upfronthosting.co.za> |
2016-08-03 12:22:28 | Artur Smęt | link | issue27674 messages |
2016-08-03 12:22:28 | Artur Smęt | create | |
|