[issue31456] SimpleCookie fails to parse any cookie if an entry has whitespace in the name

Brad Smith report at bugs.python.org
Tue Oct 10 22:47:10 EDT 2017


Brad Smith <brad82 at gmail.com> added the comment:

According to RFC-6265 (which also references RFC-2616 to define "tokens"), the space character (and whitespace in general) is not valid in cookie-names or cookie-values.

RFC-6265: https://tools.ietf.org/html/rfc6265#section-4.1.1
RFC-2616: https://tools.ietf.org/html/rfc2616#section-2.2

I think it's reasonable for Python to quietly throw away malformed NAME=VALUE pairs since web browsers are likely doing the same.

----------
nosy: +infinitewarp

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue31456>
_______________________________________


More information about the Python-bugs-list mailing list