[Zope] Re: Re: Re: File uploads: filename with ';'

Tino Wildenhain tino at wildenhain.de
Wed Oct 27 07:03:55 EDT 2004


Hi,

On Wed, 2004-10-27 at 12:55, Vova wrote:
> Tino Wildenhain wrote:
> >> So filename is sent correctly as 'a;b'. But Zope says that filename is
> >> '"a'.
> > 
> > cool :-) We come close. Then you have to file a bug for the cgi.py
> > which does the hard work of reading and parsing. Looks like an
> > insufficience in handling of the " " quoting while parsing header
> > lines.
> You are right. Bug is in cgi.py at line 325:
> plist = map(lambda x: x.strip(), line.split(';'))
> 
> One question: is it right that browser sends 'a;b' as '"a;b"' ? What RFC

rfc822 I believe. But the quoting looks right. Otherwise
the ; in the name would have to be handled as delimiter
like cgi.py does in the case because it ignores the Quoting.

I wonder how the other mime handling modules in python do
this: rfc822, mimetools, email

Regards
Tino



More information about the Zope mailing list