Dolibarr ERP CRM is a modern software package to manage your company or foundation's activity (contacts, suppliers, invoices, orders, stocks, agenda, accounting, ...). it's an open source Web application (written in PHP) designed for businesses of any sizes, foundations and freelancers.
From a fresh Dolibarr 20.0.0, the default phpmailer sends corrupted e-mails. Both Roundcube and Mozilla Thunderbird interpret parts of the headers (e.g. enclosed PDF filename) as recipients.
If I set e-mail settings to other sending method (such as SMTP/SMTPS socket library), then this bug does not occur.
I am not sure whether this is a bug introduced by the server's phpmail configuration, so I would need the help of someone to corroborate that bug.
Dolibarr Version
20.0.0
Environment PHP
8.1
Environment Database
No response
Steps to reproduce the behavior and expected behavior
Activate phpmail method in /admin/mails.php
Send any e-mail from Dolibarr, e.g. from a 3rd party card: societe/card.php?socid=1&action=presend
Check the recipient mailbox: the received message is broken as on the screenshot here above
Update: it seems due to the MAIN_FIX_FOR_BUGGED_MTA that was TRUE on all my Dolibarr setups: is that variable useful in 2024? Can it be defaulted to FALSE?
Bug
From a fresh Dolibarr 20.0.0, the default phpmailer sends corrupted e-mails. Both Roundcube and Mozilla Thunderbird interpret parts of the headers (e.g. enclosed PDF filename) as recipients.
If I set e-mail settings to other sending method (such as SMTP/SMTPS socket library), then this bug does not occur.
I am not sure whether this is a bug introduced by the server's phpmail configuration, so I would need the help of someone to corroborate that bug.
Dolibarr Version
20.0.0
Environment PHP
8.1
Environment Database
No response
Steps to reproduce the behavior and expected behavior
/admin/mails.php
societe/card.php?socid=1&action=presend
Attached files
No response