Koozali.org: home of the SME Server

Email is displayed incorrectly

Offline yythoss

  • *
  • 532
  • +0/-0
    • http://www.hylafax-client.de
Email is displayed incorrectly
« on: March 19, 2024, 12:26:51 PM »
Hello forum, I have a strange problem.

I have two identical SME 10 servers and one has an email display problem.
The email is generated by Veeam on a Windows computer and indicates the success of a backup. This email goes directly to the admin via port 25 on the SME server.
On one server it looks like this (this is ok):




On the other server it looks like this (this is not ok):

PGh0bWw+DQogIDxoZWFkPg0KICAgIDxNRVRBIGh0dHAtZXF1aXY9IkNvbnRlbnQtVHlw ZSIgY29udGVudD0idGV4dC9odG1sOyBjaGFyc2V0PXV0Zi04Ij4NCiAgICA8TUVUQSBo dHRwLWVxdWl2PSJDb250ZW50LVR5cGUiIGNvbnRlbnQ9InRleHQvaHRtbDsgY2hhcnNl dD11dGYtOCI+DQogIDwvaGVhZD4NCiAgPGJvZHk+DQogICAgPHRhYmxlIGNlbGxzcGFj aW5nPSIwIiBjZWxscGFkZGluZz0iMCIgd2lkdGg9IjEwMCUiIGJvcmRlcj0iMCIgc3R5 bGU9ImJvcmRlci1jb2xsYXBzZTogY29sbGFwc2U7Ij4NCiAgICAgIDx0cj4NCiAgICAg ICAgPHRkIHN0eWxlPSJib3JkZXI6bm9uZTsgcGFkZGluZzogMHB4O2ZvbnQtZmFtaWx5 OiBUYWhvbWE7Zm9udC1zaXplOiAxMnB4OyI+DQogICAgICAgICAgPHRhYmxlIGNlbGxz cGFjaW5nPSIwIiBjZWxscGFkZGluZz0iMCIgd2lkdGg9IjEwMCUiIGJvcmRlcj0iMCIg c3R5bGU9ImJvcmRlci1jb2xsYXBzZTogY29sbGFwc2U7Ij4NCiAgICAgICAgICAgIDx0 ciBzdHlsZT0iaGVpZ2h0OjcwcHgiPg0KICAgICAgICAgICAgICA8dGQgc3R5bGU9Indp ZHRoOiA4MCU7Ym9yZGVyOiBub25lO2JhY2tncm91bmQtY29sb3I6ICMwMEIwNTA7Y29s b3I6IFdoaXRlO2ZvbnQtd2VpZ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Q6IDE3cHg7Ij4NCiAgICAgICAgICAgICAgICAgICAgPHRkIGNvbHNw YW49IjkiIGNsYXNzPSJzZXNzaW9uRGV0YWlscyIgc3R5bGU9ImJvcmRlci1zdHlsZTog c29saWQ7IGJvcmRlci1jb2xvcjojYTdhOWFjOyBib3JkZXItd2lkdGg6IDFweCAxcHgg MCAxcHg7aGVpZ2h0OiAzNXB4O2JhY2tncm91bmQtY29sb3I6ICNmM2Y0ZjQ7Zm9udC1z aXplOiAxNnB4O3ZlcnRpY2FsLWFsaWduOiBtaWRkbGU7cGFkZGluZzogNXB4IDAgMCAx NXB4O2NvbG9yOiAjNjI2MzY1OyBmb250LWZhbWlseTogVGFob21hOyI+PHNwYW4+VHVl c2RheSwgMTkgTWFyY2ggMjAyNCAxMjoxMDoyMDwvc3Bhbj48L3RkPg0KICAgICAgICAg ICAgICAgICAgPC90cj4NCiAgICAgICAgICAgICAgICAgIDx0ciBzdHlsZT0iaGVpZ2h0 OiAxN3B4OyI+DQogICAgICAgICAgICAgICAgICAgIDx0ZCBub3dyYXAgc3R5bGU9Indp ZHRoOiAxJTtwYWRkaW5nOiAycHggM3B4IDJweCAzcHg7dmVydGljYWwtYWxpZ246IHRv


I have compared all qpsmtpd and qmail configuration files on both servers and cannot find any errors.
If I send the email directly via the provider's SMTP, the email is also ok. So it's a problem with the SME Server.
Does somebody has any idea?

Offline bunkobugsy

  • *
  • 283
  • +4/-0
Re: Email is displayed incorrectly
« Reply #1 on: March 19, 2024, 03:20:17 PM »
It's Base64 encoded, try checking in webmail (horde).

<html>
  <head>
    <META http-equiv="Content-Type" content="text/html; charset=utf-8">
    <META http-equiv="Content-Type" content="text/html; charset=utf-8">
  </head>
  <body>
    <table cellspacing="0" cellpadding="0" width="100%" border="0" style="border-collapse: collapse;">
      <tr>
        <td style="border:none; padding: 0px;font-family: Tahoma;font-size: 12px;">
          <table cellspacing="0" cellpadding="0" width="100%" border="0" style="border-collapse: collapse;">
            <tr style="height:70px">
              <td style="width: 80%;border: none;background-color: #00B050;color: White;font-weight: bold;font-size: 16px;height: 70px;vertical-align: bottom;padding: 0 0 17px 15px;font-family: Tahoma;">Agent Backup job: Backup Job WIN2012 <div class="jobDescription" style="margin-top: 5px;font-size: 12px;"> Veeam Agent for Microsoft Windows </div>
              </td>
              <td style="background-color: #00B050;color: White;font-weight: bold;font-size: 16px;height: 70px;vertical-align: bottom;padding: 0 0 17px 15px;font-family: Tahoma;padding-bottom: 42px;">Success</td>
            </tr>
            <tr>
              <td colspan="2" style="border: none; padding: 0px;font-family: Tahoma;font-size: 12px;">
                <table width="100%" cellspacing="0" cellpadding="0" class="inner" border="0" style="margin: 0px;border-collapse: collapse;">
                  <tr style="height: 17px;">
                    <td colspan="9" class="sessionDetails" style="border-style: solid; border-color:#a7a9ac; border-width: 1px 1px 0 1px;height: 35px;background-color: #f3f4f4;font-size: 16px;vertical-align: middle;padding: 5px 0 0 15px;color: #626365; font-family: Tahoma;"><span>Tuesday, 19 March 2024 12:10:20</span></td>
                  </tr>
                  <tr style="height: 17px;">
                    <td nowrap style="width: 1%;padding: 2px 3px 2px 3px;vertical-align: to
« Last Edit: March 19, 2024, 03:22:03 PM by bunkobugsy »

Offline yythoss

  • *
  • 532
  • +0/-0
    • http://www.hylafax-client.de
Re: Email is displayed incorrectly
« Reply #2 on: March 19, 2024, 03:34:50 PM »
Yes I know, but what can I do?

Offline ReetP

  • *
  • 3,804
  • +5/-0
Re: Email is displayed incorrectly
« Reply #3 on: March 19, 2024, 04:14:06 PM »
Yes I know, but what can I do?

Start debugging it?

Start narrowing down where the issue might lie rather than just guessing.

Start by looking at the headers in the emails, and the body. Look at the ACTUAL file in the directory on the server rather than via webmail or a mail program.

Are the files exactly the same on both servers?

Are the mails sent the same as those received i.e. is SME interfering in any way? Can you get it to sned a copy to another mail service at the same to compare?

Are you using the same mail reading program to view them? If so, have you tried another program?

You say they are identical servers.

Have a read here and do some auditing. The usual stuff - newrpms and templates.

https://forums.koozali.org/index.php/topic,54724.0.html

...
1. Read the Manual
2. Read the Wiki
3. Don't ask for support on Unsupported versions of software
4. I have a job, wife, and kids and do this in my spare time. If you want something fixed, please help.

Bugs are easier than you think: http://wiki.contribs.org/Bugzilla_Help

If you love SME and don't want to lose it, join in: http://wiki.contribs.org/Koozali_Foundation

Offline bunkobugsy

  • *
  • 283
  • +4/-0
Re: Email is displayed incorrectly
« Reply #4 on: March 19, 2024, 07:16:24 PM »
Same email client with both? How does it show in webmail?

Offline yythoss

  • *
  • 532
  • +0/-0
    • http://www.hylafax-client.de
Re: Email is displayed incorrectly
« Reply #5 on: March 20, 2024, 10:59:09 AM »
The email client is always the same, Outlook.
I'll have the email sent to this email account.
So really always the same Outlook on the same Windows client.

I watched qpsmtp closely. What I then noticed was this line in the log file:
I don't see this line on the good SME server

@4000000065fab0b70d1f275c 9667 dispatching MAIL FROM:<info@domain.de>
@4000000065fab0b70d2a75e4 9667 (mail) badmailfrom: skip, relay client
@4000000065fab0b70d2bd18c 9667 250 <info@domain.de>, sender OK - how exciting to get mail from you!
@4000000065fab0b70d34ca6c 9667 dispatching RCPT TO:<admin@domain.de>
@4000000065fab0b70d39b054 9667 (rcpt) badrcptto: skip, relay client
@4000000065fab0b70d3abddc 9667 (rcpt) rcpt_ok: skip, relay client
@4000000065fab0b70d3c7b2c 9667 250 <admin@domain.de>, recipient ok


(I replace the original domainname!)
From my point of view the email address is ok.
Is this my problem?

Offline yythoss

  • *
  • 532
  • +0/-0
    • http://www.hylafax-client.de
Re: Email is displayed incorrectly
« Reply #6 on: March 20, 2024, 11:30:17 AM »
Important Information!
Both SME10 were updated from SME9 to SME10 with the migratehelper script.
Could this be the cause?

Offline Jean-Philippe Pialasse

  • *
  • 2,818
  • +11/-0
  • aka Unnilennium
    • http://smeserver.pialasse.com
Re: Email is displayed incorrectly
« Reply #7 on: March 20, 2024, 12:44:50 PM »
relay client means the client sending is on the same lan or an authorized ip and check  will not be done for this plugin.

suggest you put  full log of the two qpsmtpd transactions.

Offline yythoss

  • *
  • 532
  • +0/-0
    • http://www.hylafax-client.de
Re: Email is displayed incorrectly
« Reply #8 on: March 20, 2024, 01:11:58 PM »
Ok, this is the qpsmtpd logfile from the good mail:

2024-03-20 13:06:35.433473500 10627 220 lserver.domain.de ESMTP
2024-03-20 13:06:35.434267500 10627 dispatching EHLO WIN2019
2024-03-20 13:06:35.435369500 10627 250-domain.de Hi server.domain.de [192.168.201.8]
2024-03-20 13:06:35.435409500 10627 250-PIPELINING
2024-03-20 13:06:35.435424500 10627 250-8BITMIME
2024-03-20 13:06:35.435438500 10627 250-SIZE 250000000
2024-03-20 13:06:35.435466500 10627 250 STARTTLS
2024-03-20 13:06:35.436079500 10627 dispatching MAIL FROM:<veeam@domain.de>
2024-03-20 13:06:35.436780500 10627 (mail) badmailfrom: skip, relay client
2024-03-20 13:06:35.436899500 10627 250 <veeam@domain.de>, sender OK - how exciting to get mail from you!
2024-03-20 13:06:35.437429500 10627 dispatching RCPT TO:<recipient@domain.de>
2024-03-20 13:06:35.437740500 10627 (rcpt) badrcptto: skip, relay client
2024-03-20 13:06:35.437834500 10627 (rcpt) rcpt_ok: skip, relay client
2024-03-20 13:06:35.437947500 10627 250 <recipient@domain.de>, recipient ok
2024-03-20 13:06:35.438447500 10627 dispatching DATA
2024-03-20 13:06:35.438589500 10627 354 go ahead
2024-03-20 13:06:35.439204500 10627 spooling message to disk
2024-03-20 13:06:35.440314500 10627 (data_post_headers) dkim: skip, DKIM not configured for domain.de
2024-03-20 13:06:35.456116500 10627 (data_post) bogus_bounce: pass, not a null sender
2024-03-20 13:06:35.456232500 10627 (data_post) headers: skip, relay client
2024-03-20 13:06:35.460972500 10627 (data_post) virus::clamdscan: pass, clean
2024-03-20 13:06:35.461490500 10627 (queue) logging::logterse: ` 192.168.201.8  server.domain.de  WIN2019 <veeam@domain.de>   <recipient@domain.de>    queued          <>
2024-03-20 13:06:35.463589500 10628 (queue) queue::qmail_2dqueue: (for 10627) Queuing to /var/qmail/bin/qmail-queue
2024-03-20 13:06:35.467621500 10627 250 Queued! 1710936395 qp 10628 <>
2024-03-20 13:06:35.468398500 10627 dispatching QUIT
2024-03-20 13:06:35.468606500 10627 221 domain.de closing connection. Have a wonderful day.
2024-03-20 13:06:35.468659500 10627 click, disconnecting
2024-03-20 13:06:36.382427500 27199 cleaning up after 10627

Ok, this is the qpsmtpd logfile from the bad mail:

2024-03-20 12:53:29.909649500 25396 220 server.domain.de ESMTP
2024-03-20 12:53:29.910586500 25396 dispatching EHLO WIN2012
2024-03-20 12:53:29.911669500 25396 250-domain.de Hi win2012.domain.de [192.168.2.4]
2024-03-20 12:53:29.911670500 25396 250-PIPELINING
2024-03-20 12:53:29.911688500 25396 250-8BITMIME
2024-03-20 12:53:29.911689500 25396 250-SIZE 250000000
2024-03-20 12:53:29.911699500 25396 250 STARTTLS
2024-03-20 12:53:29.912251500 25396 dispatching MAIL FROM:<veeam@domain.de>
2024-03-20 12:53:29.912968500 25396 (mail) badmailfrom: skip, relay client
2024-03-20 12:53:29.913065500 25396 250 <veeam@domain.de>, sender OK - how exciting to get mail from you!
2024-03-20 12:53:29.913613500 25396 dispatching RCPT TO:<recipient@domain.de>
2024-03-20 12:53:29.913928500 25396 (rcpt) badrcptto: skip, relay client
2024-03-20 12:53:29.914020500 25396 (rcpt) rcpt_ok: skip, relay client
2024-03-20 12:53:29.914119500 25396 250 <recipient@domain.de>, recipient ok
2024-03-20 12:53:29.914677500 25396 dispatching DATA
2024-03-20 12:53:29.914828500 25396 354 go ahead
2024-03-20 12:53:29.915459500 25396 spooling message to disk
2024-03-20 12:53:29.916637500 25396 (data_post_headers) dkim: skip, DKIM not configured for domain.de
2024-03-20 12:53:29.933876500 25396 (data_post) bogus_bounce: pass, not a null sender
2024-03-20 12:53:29.933958500 25396 (data_post) headers: skip, relay client
2024-03-20 12:53:29.952323500 25396 (data_post) virus::clamdscan: pass, clean
2024-03-20 12:53:29.952913500 25396 (queue) logging::logterse: ` 192.168.2.4    win2012.domain.de   WIN2012 <veeam@domain.de>   <recipient@domain.de>    queued          <>
2024-03-20 12:53:29.955061500 25398 (queue) queue::qmail_2dqueue: (for 25396) Queuing to /var/qmail/bin/qmail-queue
2024-03-20 12:53:29.970131500 25396 250 Queued! 1710935609 qp 25398 <>
2024-03-20 12:53:29.970905500 25396 dispatching QUIT
2024-03-20 12:53:29.971084500 25396 221 domain.de closing connection. Have a wonderful day.
2024-03-20 12:53:29.971135500 25396 click, disconnecting
2024-03-20 12:53:30.832976500 1788 cleaning up after 25396

I see no problems.

Offline yythoss

  • *
  • 532
  • +0/-0
    • http://www.hylafax-client.de
Re: Email is displayed incorrectly
« Reply #9 on: March 20, 2024, 01:30:56 PM »
Email Header from the Good Mail:

Received: (qmail 11688 invoked by alias); 20 Mar 2024 12:14:23 -0000
Delivered-To: alias-localdelivery-admin@domain.de
Received: (qmail 11685 invoked by uid 453); 20 Mar 2024 12:14:23 -0000
X-Virus-Checked: by ClamAV 0.103.11 on domain.de
X-Virus-Found: No
Authentication-Results: domain.de; auth=none
Received: from server.domain.de (HELO WIN2019) ( 192.168.201.8 )
 by domain.de (qpsmtpd/0.96) with ESMTP ; Mi, 20 Mär 2024 13:14:23 +0100
MIME-Version: 1.0
From: veeam@domain.de
To: admin@domain.de
Date: 20 Mar 2024 12:14:23 +0100
Subject: [WIN2019] Veeam Agent for Microsoft Windows
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: quoted-printable

Email Header from the Bad Mail:

Received: (qmail 28638 invoked by alias); 20 Mar 2024 12:24:15 -0000
Delivered-To: alias-localdelivery-admin@domain.de
Received: (qmail 28635 invoked by uid 453); 20 Mar 2024 12:24:15 -0000
X-Virus-Checked: by ClamAV 0.103.11 on domain.de
X-Virus-Found: No
Authentication-Results: domain.de; auth=none
Received: from win2012.domain.de (HELO WIN2012) (192.168.2.4)
 by domain.de (qpsmtpd/0.96) with ESMTP ; Mi, 20 Mär 2024 13:24:15 +0100
MIME-Version: 1.0
From: veeam@domain.de
To: admin@domain.de
Date: 20 Mar 2024 13:24:15 +0100
Subject: [WIN2012] Veeam Agent for Microsoft Windows
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: quoted-printable

Offline bunkobugsy

  • *
  • 283
  • +4/-0
Re: Email is displayed incorrectly
« Reply #10 on: March 20, 2024, 03:45:15 PM »
Those emails come from 2 different WIN servers, I'd blame Veeam Agent running on them for the mime content.

Try sending emails to them from another source.

Offline yythoss

  • *
  • 532
  • +0/-0
    • http://www.hylafax-client.de
Re: Email is displayed incorrectly
« Reply #11 on: March 20, 2024, 03:58:18 PM »
No, Veeam is not the problem.

Offline bunkobugsy

  • *
  • 283
  • +4/-0
Re: Email is displayed incorrectly
« Reply #12 on: March 20, 2024, 04:01:35 PM »
Only veeam on win2012 might be.

Try sending emails to them from another source and see if that looks ok.

Offline yythoss

  • *
  • 532
  • +0/-0
    • http://www.hylafax-client.de
Re: Email is displayed incorrectly
« Reply #13 on: March 20, 2024, 04:05:24 PM »
I have the same Problem on Windows 10 and Windows Server 2019.
It is a Problem from SME.

Offline ReetP

  • *
  • 3,804
  • +5/-0
Re: Email is displayed incorrectly
« Reply #14 on: March 20, 2024, 05:03:52 PM »
It is a Problem from SME.

You have assumed as such but have done nothing to actually PROVE it.

You have told us it can't be this and can't be that with no evidence. Please stop guessing and assuming and start looking at facts.

Have you checked the actual headers and bodies of the emails on the server as I said above?

Look in here:

/home/e-smith/Maildir

Look in cur or new for the emails and check then whole email.

eg

cat "/home/e-smith/Maildir/cur/1682671895.26537_1.host.domain.com:2,S"

Clearly the headers seem OK. In your email headers you pasted what comes in the next few lines following this:

Code: [Select]
Content-Transfer-Encoding: quoted-printable
The text following should be plain text. Where does the base64 part start?

Also, if we ask you to paste information like I did above, please do so. We aren't doing it to waste your time but to look at your server and try to understand it.

So please paste the output of 'newrpms' and 'templates', and answer JPs question:

Code: [Select]
suggest you put  full log of the two qpsmtpd transactions.
Thanks.

...
1. Read the Manual
2. Read the Wiki
3. Don't ask for support on Unsupported versions of software
4. I have a job, wife, and kids and do this in my spare time. If you want something fixed, please help.

Bugs are easier than you think: http://wiki.contribs.org/Bugzilla_Help

If you love SME and don't want to lose it, join in: http://wiki.contribs.org/Koozali_Foundation

Offline Jean-Philippe Pialasse

  • *
  • 2,818
  • +11/-0
  • aka Unnilennium
    • http://smeserver.pialasse.com
Re: Email is displayed incorrectly
« Reply #15 on: March 20, 2024, 06:25:59 PM »
header of the « good email » is actually bad
Quote
by domain.de (qpsmtpd/0.96) with ESMTP ; Mi, 20 Mär 2024 13:14:23 +0100


while bad mail header is good.
Quote
by domain.de (qpsmtpd/0.96) with ESMTP ; Mi, 20 Mär 2024 13:24:15 +0100

please what returns this command on each SME
Code: [Select]
locale
also please check the locale on each windows machine. if only one is sending something iso encoded or partly iso encoded this will lead with part of the email read wrong.

Offline yythoss

  • *
  • 532
  • +0/-0
    • http://www.hylafax-client.de
Re: Email is displayed incorrectly
« Reply #16 on: March 21, 2024, 01:54:00 PM »
Hello Forum,

I forgot to write that I am a developer and the site
Code: [Select]
https://forums.koozali.org/index.php/topic,54724.0.htmlof course I know and use it.

There are no different or new rpm's on both servers.
locale shows the correct encoding:

Germany:
Code: [Select]
LANG=de_DE.UTF-8
LC_CTYPE="de_DE.UTF-8"
LC_NUMERIC="de_DE.UTF-8"
LC_TIME="de_DE.UTF-8"
LC_COLLATE="de_DE.UTF-8"
LC_MONETARY="de_DE.UTF-8"
LC_MESSAGES="de_DE.UTF-8"
LC_PAPER="de_DE.UTF-8"
LC_NAME="de_DE.UTF-8"
LC_ADDRESS="de_DE.UTF-8"
LC_TELEPHONE="de_DE.UTF-8"
LC_MEASUREMENT="de_DE.UTF-8"
LC_IDENTIFICATION="de_DE.UTF-8"
LC_ALL=

I was now able to narrow down the problem.
All SME 10 are configured as an MTA and forwards the emails to the provider.
With the German provider

IONOS
1und1


I have a problem with the email.
With the German provider

Strato

not. I also tested this with other SME 10
« Last Edit: March 21, 2024, 02:17:25 PM by yythoss »