Add handling for multipart/mixed #2
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This is where a single multipart section is itself a multipart section. This happens when a file input field is filled with multiple uploaded files.
It's worth noting that this style is not seen in modern browsers, but I believe it should still be supported.
I'm not finding concrete specs for multipart/mixed. Is it historically only used to specify a named array of files? Or can you mix and match files and inline text content? Is it valid to infinitely nest multipart/mixed parts? Once I know what this library should support, I can implement this feature.
Interesting. Since it's not seen in modern browsers, I will mark this P-Low. Still useful just in case.
multipart/mixedis defined in RFC 1341 section 7.2. It parses very much the same as multipart/form-data parsed, so significant sharing of code would be expected.The top level
multipart/form-datasection would specify in itsContent-Dispositionheader the input name of the file input, so all the parts of anymultipart/mixedshould be considered as files submitted under that form input.Each one should offer a(edited: just leave filename: None)Content-Dispositionheader itself with afilenameparameter, and if not, we may need some algorithm to make up filenames like "userfile1"..."userfileN" or whatever.I personally wouldn't bother coding for the case of recursive descent, but you can if you like, I wouldn't consider it wrong.