'Do pre-processing (for content-length) and store this header away.
Enforce the per-request header limit.
@type line: C{bytes}
@param line: A line from the header section of a request, excluding the
line delimiter.
@return: A flag indicating whether the header was valid.
@rtype: L{bool}'

def headerReceived(self, line):

    try:
        (header, data) = line.split(':', 1)
    except ValueError:
        self._respondToBadRequestAndDisconnect()
        return False
    header = header.lower()
    data = data.strip()
    if (header == 'content-length'):
        try:
            self.length = int(data)
        except ValueError:
            self._respondToBadRequestAndDisconnect()
            self.length = None
            return False
        self._transferDecoder = _IdentityTransferDecoder(self.length, self.requests[(-1)].handleContentChunk, self._finishRequestBody)
    elif ((header == 'transfer-encoding') and (data.lower() == 'chunked')):
        self.length = None
        self._transferDecoder = _ChunkedTransferDecoder(self.requests[(-1)].handleContentChunk, self._finishRequestBody)
    reqHeaders = self.requests[(-1)].requestHeaders
    values = reqHeaders.getRawHeaders(header)
    if (values is not None):
        values.append(data)
    else:
        reqHeaders.setRawHeaders(header, [data])
    self._receivedHeaderCount += 1
    if (self._receivedHeaderCount > self.maxHeaders):
        self._respondToBadRequestAndDisconnect()
        return False
    return True
