Re: lower case email address for delivery

2020-11-29 Thread Andrew Sullivan

On Mon, Nov 30, 2020 at 12:48:09AM +1000, Nikolai Lusan wrote:


however the
domain part of the address shouldn't be case sensitive.


This is only kind of true.

In the DNS, domain names match in a case-insensitive but case-preserving way, _only if_ 
you are talking about an ASCII letter (i.e. a-z using the US alphabet with no 
"decorations").  This is specified in STD 13 (RFCs 1034 and 1035).  All other 
octets in a domain name label match exactly only.

Note that with internationalized domain names in the mix, the issue is more 
complicated.  In the current specifications (IDNA2008), capital letters aren't 
allowed at all, and it would be an error to encounter one in a domain name slot 
(such as the domain part of an email address).  Bizarrely, this means that the 
domain names example.tld and EXAMPLE.TLD and even eXaMpLe.TlD are all 
equivalent, but éxample.tld is legal, éxample.TLD is legal, and ÉXAMPLE.TLD is 
an error.  (I'm aware that's not how you spell example in French, I'm just 
using it for illustration.)  I don't think that the above considered TLDs or 
EAI, so I don't expect it is relevant; I just mention it for completeness.

Best regards,

A

--
Andrew Sullivan
a...@anvilwalrusden.com


Re: lower case email address for delivery

2020-11-29 Thread Bill Cole

On 29 Nov 2020, at 9:48, Nikolai Lusan wrote:


Traditionally SMTP systems forced everything to be lower case


This is not true.

RFC821 and RFC822 (1982) both define the local part of email addresses 
as including upper or lower case letters and optionally case-sensitive 
with the sole exception of the required "postmaster" address, which 
systems must treat as equivalent in any mix of cases. In both of those 
RFCs, the examples used for email addresses typically used mixed-case 
local parts.


--
Bill Cole
b...@scconsult.com or billc...@apache.org
(AKA @grumpybozo and many *@billmail.scconsult.com addresses)
Not Currently Available For Hire


Re: myorigin will not be honored

2020-11-29 Thread Johannes Black

Okay thanks, I will investigate further.

On 29.11.2020 18:11, Wietse Venema wrote:

Johannes Black:

Hi,

I am using Debian 10 and I am bulding a server with a mail.someurl.com
hostname and an MX entry for someurl.com.

I have setup

myorigin = /etc/mailname

and /etc/mailname has

someurl.com

as an entry.

If I test it with

echo "test"| mail destination-addr...@gmail.com

(mail comes from the mailutils package)

I unfortunately still get the johan...@mail.someurl.com source address.
The same result happens if I use mutt. I reloaded the configuration with
'postfix reload' before.

Any idea why myorigin is not working? Did I miss a configuration?


myorigin is ussed only if an email address does not already have a
domain name. If the mail submission program already appends a
domain then myorigin will not be used.

Wietse



Re: myorigin will not be honored

2020-11-29 Thread Wietse Venema
Johannes Black:
> Hi,
> 
> I am using Debian 10 and I am bulding a server with a mail.someurl.com 
> hostname and an MX entry for someurl.com.
> 
> I have setup
> 
> myorigin = /etc/mailname
> 
> and /etc/mailname has
> 
> someurl.com
> 
> as an entry.
> 
> If I test it with
> 
> echo "test"| mail destination-addr...@gmail.com
> 
> (mail comes from the mailutils package)
> 
> I unfortunately still get the johan...@mail.someurl.com source address. 
> The same result happens if I use mutt. I reloaded the configuration with 
> 'postfix reload' before.
> 
> Any idea why myorigin is not working? Did I miss a configuration?

myorigin is ussed only if an email address does not already have a
domain name. If the mail submission program already appends a 
domain then myorigin will not be used.

Wietse


myorigin will not be honored

2020-11-29 Thread Johannes Black

Hi,

I am using Debian 10 and I am bulding a server with a mail.someurl.com 
hostname and an MX entry for someurl.com.


I have setup

myorigin = /etc/mailname

and /etc/mailname has

someurl.com

as an entry.

If I test it with

echo "test"| mail destination-addr...@gmail.com

(mail comes from the mailutils package)

I unfortunately still get the johan...@mail.someurl.com source address. 
The same result happens if I use mutt. I reloaded the configuration with 
'postfix reload' before.


Any idea why myorigin is not working? Did I miss a configuration?

Greetings and thanks,
Johannes



Re: lower case email address for delivery

2020-11-29 Thread Michael Ströder
On 11/29/20 3:48 PM, Nikolai Lusan wrote:
> Traditionally SMTP systems forced everything to be lower case ... but
> then people like Microsoft started making MTA's that where case
> sensitive for the reciever part of the email address (at the time this
> was not RFC complianat behaviour).

IIRC the local part of e-mail address was always defined as case-sensitive.

BTW: In old Internet mail systems the local part was often the Unix user
name. And according to POSIX standard this is case-sensitive (which most
people also forget).

Ciao, Michael.


Re: lower case email address for delivery

2020-11-29 Thread Nikolai Lusan
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA512

On Sat, 2020-11-28 at 11:30 +0100, Juerg Reimann wrote:

FWIW it looks like a dovecot/lda issue.

Traditionally SMTP systems forced everything to be lower case ... but
then people like Microsoft started making MTA's that where case
sensitive for the reciever part of the email address (at the time this
was not RFC complianat behaviour). A quick parsing of the current RFC's
shows that for the reciever part (i.e. before the "@" symbol) it's up
to the delivery agent how it handles case sensetivity, however the
domain part of the address shouldn't be case sensitive. I have always
run on the basis that all email addresses should be case insensetive,
and that the MTA/MDA should ignore the case of any characters in any
part of the address. In the case outlined below I would look more
closely at your dovecot configuration than your postfix configuration.
I have a similar setup, but addmittedly I haven't tried (or seen anyone
try) using anything upper case in the email addresses I'm serving.

But, yeah, according to the RFC's it's up to the MDA/LDA how it handle
character case sensetivity :)


> Interesting phenomenon on a newly setup system:
> 
> 2020-11-28T11:15:48+01:00 localhost postfix/lmtp[98782]: [ID 197553
> mail.info] DDB5E8456: to=,
> relay=my.host.tld[private/dovecot-lmtp], delay=0.04,
> delays=0.02/0/0.01/0.01, dsn=5.1.1, status=bounced (host
> my.host.tld[private/dovecot-lmtp] said: 550 5.1.1 
> User doesn't exist: u...@domain.tld (in reply to RCPT TO command))
> 2020-11-28T11:16:01+01:00 localhost postfix/lmtp[98782]: [ID 197553
> mail.info] BF1678458: to=, relay=
> my.host.tld[private/dovecot-lmtp], delay=0.26, delays=0.25/0/0/0.01,
> dsn=5.1.1, status=bounced (host my.host.tld[private/dovecot-lmtp]
> said: 550 5.1.1  User doesn't exist:
> u...@domain.tld (in reply to RCPT TO command))
> 2020-11-28T11:26:37+01:00 localhost postfix/lmtp[99560]: [ID 197553
> mail.info] BA35E88DC: to=,
> relay=my.host.tld[private/dovecot-lmtp], delay=0.16,
> delays=0.08/0/0/0.08, dsn=2.0.0, status=sent (250 2.0.0
>  YIesL90lwl+2hAEA0J78UA Saved)
> 
> How can I lowercase the complete email address in postfix before
> delivery? It happens like this in my case:
> 
> virtual_transport = lmtp:unix:private/dovecot-lmtp


When in doubt RTR [Read The RFC] :)

- -- 
Nikolai Lusan 
-BEGIN PGP SIGNATURE-

iQIzBAEBCgAdFiEEVfd4GW6z4nsBxdLo4ZaDRV2VL6QFAl/DtKkACgkQ4ZaDRV2V
L6TVaQ/+Jv2bekHh4igxgl6BSz0huiI0FTGOXPKZlVObKflha/8kszR8hRI8DKaR
7I2noZknNbwh93wvfYQsz8Qf45FnNzB/231UAQyetBhQg1wB5vzJugsLD2Odk+PT
L7kcVOSn2KSQH96Rf6V4qQr6SOrUKhGwos8KBl/mMIvyja4aor84VaLHgES5rG3k
PdOkh1XkIm3va6blipsfVQVGriRBzFAMqrNm7s/84m/mJ2Xfr6qHe75OsZDCHGgy
sinvXtF9blOsLilFIqI+ZyhXGNMbnZrzG4DvooS9tycc2JygmgcVV3ugcSLfGndI
ziFIT6SftnWyndhKJlBqD2R7DUNxlMB7v2AL/Tw2ldURGnZF/bt4G3erUcF8VEAU
o9X4RJOOc7dTjYIGOrfDzHn99JLy5m/rbo2nkBZPYcIx4O5HuPcTVXKKYV/6s1Yu
xwZyk287esRNi9mZN2v5SPT3pOXhFTCzEaGGJMjh7aQycZNXWxxzIkv9wP1p1ZEe
3TxTdkVVwNC3YRmt2/Tq4ISuWAiVpygjabD6U2YDJghFWNhaJr1M/0pn5MpP5clG
Gew4Hj6AZks9XN8t4VPtCvAELeBoUMk7dg4SJQbbH5qlOGqKkk0Y7WWCxHZWo9xS
d17fkruJFR7wtslRlygVfjrb2EKZxM7AKCF+dmgW3o849dNvQ+c=
=XsX8
-END PGP SIGNATURE-