def split_headers(value: bytes):
    """Splits a whole portion of multipart form data representing headers into name, value pairs"""
    for raw_header in value.split(b'\r\n'):
        header_name, header_value = raw_header.split(b':', 1)
        yield header_name.lower(), header_value.lstrip(b' ')
