Changes for page Multipart form-data

Last modified by Erik Bakker on 2024/06/17 11:39

From version 22.1
edited by Eva Torken
on 2023/12/07 15:02
Change comment: There is no comment for this version
To version 23.2
edited by Erik Bakker
on 2024/06/17 11:39
Change comment: Update document after refactoring.

Summary

Details

Page properties
Parent
... ... @@ -1,1 +1,1 @@
1 -WebHome
1 +Main.eMagiz Academy.Microlearnings.Legacy Functionality.WebHome
Author
... ... @@ -1,1 +1,1 @@
1 -XWiki.etorken
1 +XWiki.ebakker
Content
... ... @@ -27,6 +27,13 @@
27 27  * Defining the content types of each part of the message
28 28  * Construction of the complete message according to the specification
29 29  
30 +{{info}}
31 +The following criteria apply when utilizing the boundary functionality within the multipart/form-data construction:
32 +* The value of the Boundary must begin with a double horizontal bar –, this is called a leading hyphen
33 +* The value of the Boundary must not contain more than 70 characters in addition to the leading hyphen.
34 +* The value of the Boundary must not contain characters that are disabled by the HTTP protocol or the URL, such as the colon: etc.
35 +* A boundary within the request body must always be preceeded by a CRLF line. This means that when the request body **ends** with a CRLF line an **additional** CRLF line is needed **before** the boundary doubling the CRLF lines in that part of the request body.{{/info}}
36 +
30 30  === 3.1 Prepare the message ===
31 31  
32 32  To construct the message, several steps are needed to make it work. Luckily, most of the steps necessary have to do with concepts we have already discussed in previous microlearnings. As you can imagine, based on what multipart/form-data entails, we need a way to both store the meta information and the file(s) we want to send to the external party. For example, put the metadata in one (or multiple) header(s) and use the file content as a payload. This you can achieve with a header enricher and standard transformer.