On Sonntag, 15. M?rz 2020 22:37:40 CET Martin Johannes Dauser
wrote:> On Sonntag, 15. M?rz 2020 21:43:08 CET Juri Haberland wrote:
> > On 15/03/2020 21:26, GMX Account wrote:
> > > have a look at this:
> > >
> > > http://www.postfix.org/postconf.5.html#recipient_delimiter
> > >
> > > [...]When the recipient_delimiter [1] set contains multiple
characters
> > > (Postfix 2.11 and later), a user name or .forward file name is
> > > separated from its extension by the first character that matches
the
> > > recipient_delimiter [1] set.[...]
> >
> > Uhm, yes, I know what this option should do, but what happens, if I
> > already have a user with e.g. a hyphen (-) in its name (e.g. foo-bar)
> > and I set recipient_delimiter to "-"?
> >
> > Will this character become a somewhat illegal character for usernames
in
> > the user database?
> >
> >
> > Cheers,
> >
> > Juri
>
> Yes, of course . By setting the delimiter "-", the address
foo-bar at ex.tld
> becomes foo at ex.tld . Postfix seems to have a special interpretation of
"+-"
> as it is compatible to qmail extension (another smtp server), which seems
> to have "-" hardcoded as delimiter. So I guess postfix is using
"+" OR "-"
> as delimiter...
>
> foo-bar at ex.tld
> foo+bar at ex.tld
> foo+-bar at ex.tld
> ... would all be sent to foo at ex.tld ??
>
> From http://www.postfix.org/postconf.5.html#recipient_delimiter
> # Handle both Postfix and qmail extensions (Postfix 2.11 and later).
> recipient_delimiter = +-
>
> (Who would need such a compatibility option -- I mean where is the use case
> ?!) Martin
Ah, answering my own post, sk71 already gave the hint:
When the recipient_delimiter set contains multiple characters , a FILE NAME is
separated from its extension by the FIRST CHARACTER THAT MATCHES the
recipient_delimiter set. So postfix will act similar to qmail and check files:
"the delivery instructions for username-extension are in
~username/.qmail-extension."
So setting the delimiter to "+-" postfix will interpret
* foo-bar at ex.tld as an email for foo at ex.tld and will check a file
matching "bar".
* foo+bar at ex.tld -> foo at ex.tld, file matching "bar"
* foo+-bar at ex.tls -> foo at ex.tld, file matching "-bar"
* foo-+bar at ex.tls -> foo at ex.tld, file matching "+bar"
Well and you might want to use that when transfering from/to qmail.
Martin