Duplicate
Details
Assignee
CalebCalebReporter
FlorenFlorenLabels
Impact
MediumComponents
Affects versions
Priority
Low
Details
Details
Assignee
Caleb
CalebReporter
Floren
FlorenLabels
Impact
Medium
Components
Affects versions
Priority
More fields
More fields
More fields
Katalon Platform
Katalon Platform
Katalon Platform
Created November 26, 2022 at 8:10 AM
Updated May 8, 2024 at 6:07 PM
Resolved November 30, 2022 at 5:55 PM
There is a strange behaviour with emails being sent with SMTP method. If I define the hostname
uranus.lan
, everything is functional. However this breaks the mDNS authentication in a Mac.Hostname is not correctly defined but X-TrueNAS-Host had the correct hostname, so emails work:
# cat /etc/resolv.conf nameserver 192.168.1.1 # hostname uranus.lan # hostname -f uranus.lan. # cat /var/log/mail.log # echo 'This is a test.' | mail -s 'Hello World' hello@domain.com Nov 26 02:50:45 uranus middlewared[1086]: sending mail to hello@domain.com Content-Type: multipart/mixed MIME-Version: 1.0 Subject: Hello World From: Uranus <mail@icloud.com> To: hello@domain.com Date: Sat, 26 Nov 2022 07:50:44 -0000 Message-ID: <truenas-20221126.075044.617651.b'-jhK'@uranus.lan> Content-Transfer-Encoding: 8bit X-Mailer: TrueNAS X-TrueNAS-Host: uranus.lan
If I define correctly the hostname, mDNS authentication is fixed, but emails are not being sent anymore:
# cat /etc/resolv.conf domain lan nameserver 192.168.1.1 # hostname uranus # hostname -f uranus.lan # echo 'This is a test.' | mail -s 'Hello Broken' hello@domain.com # cat /var/log/mail.log Nov 26 02:59:12 uranus middlewared[1086]: sending mail to hello@domain.com Content-Type: multipart/mixed MIME-Version: 1.0 Subject: Hello Broken From: Uranus <mail@icloud.com> To: hello@domain.com Date: Sat, 26 Nov 2022 07:59:10 -0000 Message-ID: <truenas-20221126.075910.998769.b'U1UN'@uranus> Content-Transfer-Encoding: 8bit X-Mailer: TrueNAS X-TrueNAS-Host: uranus
As you can see, X-TrueNAS-Host is not looking for the full hostname as it should, which makes the email to fail being sent.