Cant receive mails with .eml attachement through proxmox

JoshuaSign

New Member
Oct 5, 2019
3
0
1
19
Hi,

I just test Proxmox Mail Gateway 6.0-4 and i cant understand why i cant receive .eml attachments from outside.

I do many tries with different gw and everytime a mail comes by the proxmox gw, the file.eml attachement is deleted.

I try to disable every rules, but same problem.
I investigate were it can be done in the postfix or spamassassin, but did'nt found it :-(.

Can you please give me a way ?


Regards.
Joshua
 

JoshuaSign

New Member
Oct 5, 2019
3
0
1
19
Hi,

After many hours and hundreds tests, i finaly find why the eml attachment disapear.
I explain below.

The filter process /usr/bin/pmg-smtp-filter call functions from /usr/share/perl5/PMG
I found that HTMLMail.pm, MailQueue.pm and Unpack.pm deal with MIME types using : /usr/share/perl5/MIME/Parser.pm
Take a look around line 1046 of this file.

The default in /usr/share/perl5/MIME/Parser.pm is extract_nested_messages to 1.
And only HTMLMail.pm set extract_nested_messages to 0
MailQueue.pm
and Unpack.pm explicitly set to 1.

If you want to be able to receive eml attachements, just change :

"MailQueue.pm" at line 350 :

$parser->extract_nested_messages (1);
by
$parser->extract_nested_messages (0);

"Unpack.pm" at line 541 :
$parser->extract_nested_messages (1);
by
$parser->extract_nested_messages (0);

Later, if you prefer avoid eml files attachement, be sure to put these 3 types in the "Dangerous Files" list :
Content-Type: message/rfc822;
Content-Type: message/external-body
Content-Type: message/partial;


I hope this will help.

JoshuaSign_
 

Stoiko Ivanov

Proxmox Staff Member
Staff member
May 2, 2018
4,140
519
118
sending .eml attachments works here (without the modifications).
Could you please post the (anonymized) logs of such a mail without the modifications?
and maybe also the whole mail including the .eml attachment (again anonymized)

thanks!
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE and Proxmox Mail Gateway. We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get your own in 60 seconds.

Buy now!