Bug 110370 - libkmime: MIME checking code does not recognize uuencoded content because of ContentType checking
Summary: libkmime: MIME checking code does not recognize uuencoded content because of ...
Status: RESOLVED REMIND
Alias: None
Product: knode
Classification: Miscellaneous
Component: general (show other bugs)
Version: unspecified
Platform: Gentoo Packages NetBSD
: NOR normal
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-08-08 00:54 UTC by Tony Moore
Modified: 2009-04-24 19:53 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tony Moore 2005-08-08 00:54:38 UTC
Version:           0.9.2 (using KDE KDE 3.4.2)
Installed from:    Gentoo Packages
OS:                NetBSD

in kmime_content.cpp:125 the code checks whether the content is Text:

if(ct->isText()) 
       return; //nothing to do

In some messages with UUencoded binaries the content-type is "text/plain" and the body is the data, but this if statement will exit the function rendering the encoded data. 

The other part of code that goes along with this is the code a few lines down:

else if (ct->mimeType()=="invalid/invalid") { //non-mime body => check for uuencoded content

This will only enter if the content-type was set to "text".

I made two changes to fix this problem.

1. Remove the first "if" listed
2. change "else if ..." to "else"
Comment 1 Olivier Trichet 2009-04-24 19:53:35 UTC
Uuencoded messages should not declare a text/plain mime-type.

In fact they usually declare no mime-type at all which, in a MIME world, means text/plain. A change in kmime has been made to always try to uudecode message with no MIME headers.

This should fix parsing of almost every message with uuencoded data.

PS : I know it is a very late reply...