.. image:: https://github.com/defnull/multipart/actions/workflows/test.yaml/badge.svg :target: https://github.com/defnull/multipart/actions/workflows/test.yaml :alt: Tests Status
.. image:: https://img.shields.io/pypi/v/multipart.svg :target: https://pypi.python.org/pypi/multipart/ :alt: Latest Version
.. image:: https://img.shields.io/pypi/l/multipart.svg :target: https://pypi.python.org/pypi/multipart/ :alt: License
.. _HTML5: https://html.spec.whatwg.org/multipage/form-control-infrastructure.html#multipart-form-data .. _RFC7578: https://www.rfc-editor.org/rfc/rfc7578 .. _WSGI: https://peps.python.org/pep-3333 .. _ASGI: https://asgi.readthedocs.io/en/latest/ .. _SansIO: https://sans-io.readthedocs.io/ .. _asyncio: https://docs.python.org/3/library/asyncio.html
This module provides a fast incremental non-blocking parser for
multipart/form-data
[HTML5, RFC7578], as well as blocking alternatives for
easier use in WSGI_ or CGI applications:
MultipartPart
instances.multipart
and urlencoded
form submissions.benchmarks <https://github.com/defnull/multipart_bench>
_).All parsers in this module implement multipart/form-data
as defined by HTML5
and RFC7578, supporting all modern browsers or HTTP clients in use today.
Legacy browsers (e.g. IE6) are supported to some degree, but only if the
required workarounds do not impact performance or security. In detail this means:
multipart/form-data
, not suitable for email parsing.multipart/mixed
support (deprecated in RFC7578_).base64
or quoted-printable
transfer encoding (deprecated in RFC7578_).encoded-word
or name=_charset_
encoding markers (deprecated in HTML5_).pip install multipart
Examples and API documentation can be found at: https://multipart.readthedocs.io/
.. __: https://github.com/defnull/multipart/raw/master/LICENSE
Code and documentation are available under MIT License (see LICENSE__).