This is a HTTP POST request sent with the request body specially formatted as a series of “parts”, separated by a boundary string. It allows a mix for form data, files etc to be sent as a HTTP POST.

Resources

https://ec.haxx.se/http-multipart.html

https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods/POST

Example 1

Form
<form action="my_post_page.php" method="post" enctype="multipart/form-data">

</form> 
html that is sent
POST /submit.cgi HTTP/1.1
Host: example.com
User-Agent: curl/7.46.0
Accept: */*
Content-Length: 313
Expect: 100-continue
Content-Type: multipart/form-data; boundary=------MyFormBoundaryvZ0ZHShNAcBABWFy
------MyFormBoundaryvZ0ZHShNAcBABWFy
Content-Disposition: form-data; name="fileToUpload"; filename="data.txt"
Content-Type: text/plain

Hello
------MyFormBoundaryvZ0ZHShNAcBABWFy
Content-Disposition: form-data; name="secret"; filename="file.txt"
Content-Type: text/plain

The contents of this file
------MyFormBoundaryvZ0ZHShNAcBABWFy--

The last boundary has “–” added to the end of it

UK Electronic Designer
USEFUL?
We benefit hugely from resources on the web so we decided we should try and give back some of our knowledge and resources to the community by opening up many of our company’s internal notes and libraries through mini sites like this. We hope you find the site helpful.
Please feel free to comment if you can add help to this page or point out issues and solutions you have found, but please note that we do not provide support on this site. If you need help with a problem please use one of the many online forums.

Comments

Your email address will not be published.