cubicweb #5280949 httpcache / http_headers crash in parseDateTime [open]

2015-04-20 10:04:48 - (cubicweb.web) ERROR: IndexError('list index out of range',)
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/cubicweb/web/", line 462, in core_handle
    result = controller.publish(rset=rset)
  File "/usr/lib/python2.7/dist-packages/cubicweb/web/views/", line 132, in publish
    if self._cw.is_client_cache_valid():
  File "/usr/lib/python2.7/dist-packages/cubicweb/web/", line 776, in is_client_cache_valid
    validators = get_validators(self._headers_in)
  File "/usr/lib/python2.7/dist-packages/cubicweb/web/", line 161, in get_validators
    value = headers_in.getHeader(header)
  File "/usr/lib/python2.7/dist-packages/cubicweb/web/", line 1384, in getHeader
    return self._toParsed(name)
  File "/usr/lib/python2.7/dist-packages/cubicweb/web/", line 1341, in _toParsed
    h = self.handler.parse(name, r)
  File "/usr/lib/python2.7/dist-packages/cubicweb/web/", line 76, in parse
    header = p(header)
  File "/usr/lib/python2.7/dist-packages/cubicweb/web/", line 626, in parseIfModifiedSince
    return parseDateTime(header.split(';', 1)[0])
  File "/usr/lib/python2.7/dist-packages/cubicweb/web/", line 164, in parseDateTime
    if not parts[0][0:3].lower() in weekdayname_lower:
IndexError: list index out of range

looks like we're trusting user submitted data to be well formed (either that, or misparsing well-formed data).

done in<not specified>
load left0.500
closed by<not specified>