[Svn] r4116 - in trunk/roundcubemail: . program/include

trac at roundcube.net trac at roundcube.net
Wed Oct 20 14:24:21 CEST 2010


Author: alec
Date: 2010-10-20 07:24:21 -0500 (Wed, 20 Oct 2010)
New Revision: 4116

Modified:
   trunk/roundcubemail/CHANGELOG
   trunk/roundcubemail/program/include/rcube_message.php
Log:
- Fix handling of attachments when Content-Disposition is not inline nor attachment (#1487051)


Modified: trunk/roundcubemail/CHANGELOG
===================================================================
--- trunk/roundcubemail/CHANGELOG	2010-10-20 11:41:48 UTC (rev 4115)
+++ trunk/roundcubemail/CHANGELOG	2010-10-20 12:24:21 UTC (rev 4116)
@@ -36,6 +36,7 @@
 - Add ANNOTATEMORE extension support into IMAP classes (draft-daboo-imap-annotatemore)
 - Add METADATA extension support into IMAP classes (RFC5464)
 - Fix decoding of e-mail address strings in message headers (#1487068)
+- Fix handling of attachments when Content-Disposition is not inline nor attachment (#1487051)
 
 RELEASE 0.4.2
 -------------

Modified: trunk/roundcubemail/program/include/rcube_message.php
===================================================================
--- trunk/roundcubemail/program/include/rcube_message.php	2010-10-20 11:41:48 UTC (rev 4115)
+++ trunk/roundcubemail/program/include/rcube_message.php	2010-10-20 12:24:21 UTC (rev 4116)
@@ -448,7 +448,9 @@
                 }
                 // part is a file/attachment
                 else if (preg_match('/^(inline|attach)/', $mail_part->disposition) ||
-                    $mail_part->headers['content-id'] || (empty($mail_part->disposition) && $mail_part->filename)
+                    $mail_part->headers['content-id'] ||
+                    ($mail_part->filename &&
+                        (empty($mail_part->disposition) || preg_match('/^[a-z0-9!#$&.+^_-]+$/i', $mail_part->disposition)))
                 ) {
                     // skip apple resource forks
                     if ($message_ctype_secondary == 'appledouble' && $secondary_type == 'applefile')

_______________________________________________
http://lists.roundcube.net/mailman/listinfo/svn



More information about the Svn mailing list