[OGo-Developer] multipart/form-data and text encoding
Helge Hess
developer@opengroupware.org
Thu, 23 Aug 2007 21:01:38 +0200
On 23.08.2007, at 00:09, Wolfgang Sourdeau wrote:
> I think there was mention of modifying the parsers instead
I have not found the time to look at the changes yet, but changing
default encodings for decoding from ASCII to UTF-8 should almost
always make sense (since every ASCII char is a valid UTF-8 char).
Anyways, the more important thing is that we should not work on
NGHttpRequest and the NGMime based HTTP parser! Quite a while ago I
started that "SimpleHTTPParser" which can be enabled using the
"WOHttpTransactionUseSimpleParser" default. (and in fact its much
more reliable and efficient for WebDAV usage!, so its recommended for
ZideStore/xmlrpcd)
The NGMime stuff is *quite* complex (and I'm relunctant to change a
lot there, because it works quite well for b0rked messages). This is
necessary for mail, but completely unnecessary for HTTP which is
rather clean and well implemented in 'da real world.
There is only one issue which is why the SimpleParser is not enabled
by default: it doesn't implement multipart/formdata=>WORequest
decoding (which is not that hard, but some work).
So IMHO the proper thing would be to finish the SimpleParser instead
of tweaking NGMime. If you would want to do this, it would be a
welcome and useful addition to SOPE.
Helge
PS: I'll have a look at the patch later this week.
--
Helge Hess
http://www.helgehess.eu/