banjo Posted October 1, 2003 Report Share Posted October 1, 2003 I recently received an email from a Mac computer. The email has a .pdf file embedded in it in MIME format, and Kmail will not display it as an attachment. If I view the email in plain text format, I can see the MIME section, so I know that it is there. It starts out like this: --MS_Mac_OE_3147240150_3640249_MIME_Part-- --MS_Mac_OE_3147240150_3640249_MIME_Part Content-type: application/pdf; name="Rau_Fall_2003.pdf"; x-mac-creator="4341524F"; x-mac-type="50444620" Content-disposition: attachment Content-transfer-encoding: base64 JVBERi0xLjQNJeLjz9MNCjM1NCAwIG9iag08PCANL0xpbmVhcml6ZWQgMSANL08gMzU2IA0v SCBbIDIyMDcgMzM0IF0gDS9MIDE3MTIyODcgDS9FIDM0MTQzNSANL04gNSANL1QgMTcwNTA4 ..... etc............... After the header I can see the MIME encoded data. The other parts of the email are MIME types that are text/plain and text/html, and Kmail has no trouble decoding and displaying them. Does anybody here know if I can use some other tool to decode this document? I am not familiar enough with the innards of email and MIME to figure it out. Thanks in advance Banjo (_)=='=~ BTW, I found out quite by accident (I went for shift key and bumped the 'v' key...... don't ask) that Kmail will show the actual text of a message by selecting the message in the message list and typing the 'v' key. Very kewl Quote Link to comment Share on other sites More sharing options...
banjo Posted October 2, 2003 Author Report Share Posted October 2, 2003 Just in case anybody else is interested in this I thought I would post my progress trying to unpack an errant email with an invisible attachment. I captured the email in a .txt file so that I can mess with it. After a few hours of research I found mpack-1.5-9.i686.rpm and installed it. This installs mpack and munpack, which are tools to pack and unpack MIME parts. These are old CLI tools from the dark ages of email. I ran munpack against my text file like this: ~/apps/mpack>munpack raumail.txt Did not find anything to unpack from raumail.txt This is consistent with what my readers are telling me................ that the attachment is not there. But when I open the text file and scroll down to the section where the attachment resides, the MIME part is there along with all the base64 codes and 2.2 Meg of junk. To test a bit further, I sent myself a different email with an attachment of a zip file. I converted that email into a text file and ran munpack against it. It extracted the .zip file just fine. So, now I am off to compare the two email files to see why the Mac-generated file thinks that it has no attachment. They both look very similar in content. I am learning a lot about the nitty-gritty of the innards of email. Pretty scary. Banjo (_)=='=~ Quote Link to comment Share on other sites More sharing options...
banjo Posted October 4, 2003 Author Report Share Posted October 4, 2003 Well, I finally got my attachment from the email. Suspecting that something was wrong with the headers in the original, I edited the other message (the one that worked), deleting the base64 code that was there and replacing it with the base64 code from the errant message. So, if all is well, I should have the .pdf data stored in the other message using the other file name etc. Then, I used munpack to extract the new data. It worked fine, so I changed the file name back to a .pdf file and I can read it using Adobe. :D I did not figure out exactly what is wrong with the MIME headers in the original message. I guess I won't because I have no idea how to start debugging something like that. But I have my file. Do I get to stop being a NOObie now? :lol: Banjo (_)=='=~ Quote Link to comment Share on other sites More sharing options...
mystified Posted October 4, 2003 Report Share Posted October 4, 2003 Do I get to stop being aNOObie now? :lol: Banjo (_)=='=~ :lol: Thanks for posting your progress. I'm sure someday somebody else will have the problem and find your thread very useful. As far as being a noobie you can change your title anytime you want. Just pm one of us admins and we'll be happy to do it. :) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.