Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the IMAP-BodyStructure CPAN distribution.

Report information
The Basics
Id: 97966
Status: open
Priority: 0/
Queue: IMAP-BodyStructure

People
Owner: KAPPA [...] cpan.org
Requestors: jonas [...] paranormal.se
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 1.01
Fixed in: (no value)



Subject: Handle subjects without quotes
I encounterd an example of a bodystructure with the subject without quotes. Example: 6 UID FETCH 3038 bodystructure * 1137 FETCH (UID 3038 BODYSTRUCTURE (("text" "plain" ("charset" "ISO-8859-1") NIL NIL "8bit" 248 6 NIL NIL NIL NIL)("Message" "Delivery-Status" NIL NIL NIL "7bit" 362 NIL NIL NIL NIL)("message" "rfc822" NIL NIL NIL "7bit" 73557 ("Thu, 03 Apr 2014 19:10:41 +0200" Avisita Aktuellt - Mer tid =?ISO-8859-1?Q?f=F6r=20?=konferensbokningar (("Avisita" NIL "webb" "avisita.com")) (("Avisita" NIL "webb" "avisita.com")) (("Avisita" NIL "webb" "avisita.com")) ((NIL NIL "vinverde" "algonet.se")) NIL NIL NIL "<E1WVlA1-00087n-8S@lyx.ls1.se>") (("text" "plain" ("charset" "ISO-8859-1" "format" "flowed") NIL NIL "8bit" 3995 100 NIL NIL NIL NIL)("text" "html" ("charset" "ISO-8859-1") NIL NIL "7bit" 67986 1085 NIL NIL NIL NIL) "alternative" ("boundary" "------------070805040901060600000602") NIL NIL NIL) 1226 NIL NIL NIL NIL) "Report" ("report-type" "delivery-status" "boundary" "========/52D6B96701F305CA/mm-proxy2.telenor.se") NIL NIL NIL)) This would be handled by accepting spaces in the fallback alternative of sub _get_nstring Change the liine from } elsif ($$str =~ /\G([^"\(\)\{ \%\*\"\\\x00-\x1F]+)/gc) { to } elsif ($$str =~ /\G([^"\(\)\{\%\*\"\\\x00-\x1F]+)/gc) {
From: jonas [...] cpan.org
A better solution might be to make a special parser just for env-subject to limit the potential danger. of accepting spaces. But I haven't come across an example there this type of string is followed by for exampel NIL. It's always some of the special chars. Usually '('.
08 Eki 2014 Çrş, 05:59:43 tarihinde, jonas@cpan.org yazdı: Show quoted text
> A better solution might be to make a special parser just for env- > subject to limit the potential danger. of accepting spaces. But I > haven't come across an example there this type of string is followed > by for exampel NIL. It's always some of the special chars. Usually > '('.
Jonas, hello. Do you remember what IMAP server generated such response? Right now, I am strongly against this change unless it's some very popular server that cannot fix the bug on their side.
06 Eki 2015 Sal, 15:36:19 tarihinde, KAPPA yazdı: Show quoted text
> 08 Eki 2014 Çrş, 05:59:43 tarihinde, jonas@cpan.org yazdı:
> > A better solution might be to make a special parser just for env- > > subject to limit the potential danger. of accepting spaces. But I > > haven't come across an example there this type of string is followed > > by for exampel NIL. It's always some of the special chars. Usually > > '('.
> > > Jonas, hello. > > Do you remember what IMAP server generated such response? > > Right now, I am strongly against this change unless it's some very > popular server that cannot fix the bug on their side.