Opened 18 years ago
Last modified 17 years ago
#2806 closed defect
Cookie system does not support "port" — at Initial Version
Reported by: | Owned by: | Adrian Holovaty | |
---|---|---|---|
Component: | Contrib apps | Version: | dev |
Severity: | normal | Keywords: | cookies |
Cc: | Triage Stage: | Accepted | |
Has patch: | no | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
When loading my web page with a .NET application's cookie system (in WebRequest) it'll send this cookie:
sessionid=a2be2e7debe71af8d88d350c4d14d768;$Path=/;$Domain=192.168.0.2;$Port="8000"
Python will here fail on a cookie error:
File "/home/neuron/Documents/Programming/django/django_src/django/core/handlers/wsgi.py", line 128, in _get_cookies
self._cookies = http.parse_cookie(self.environ.get('HTTP_COOKIE', ))
File "/home/neuron/Documents/Programming/django/django_src/django/http/init.py", line 151, in parse_cookie
c.load(cookie)
File "/usr/lib64/python2.4/Cookie.py", line 621, in load
self.ParseString(rawdata)
File "/usr/lib64/python2.4/Cookie.py", line 646, in ParseString
M[ K[1:] ] = V
File "/usr/lib64/python2.4/Cookie.py", line 437, in setitem
raise CookieError("Invalid Attribute %s" % K)
CookieError: Invalid Attribute port