Thank you, sometime I forget to RTFM.

A 2 part question.
abc.com  550 Spam from ABC.com

Will this match anything with abc.com, as an example if the message comes
from m...@test.abc.com will it get rejected?
Additionally in the doc I see REJECT and below that 5xx, do I need to have
REJECT 550 We don't like you
or does
500 We don't like you
Work?

Thank you



On Wed, Oct 28, 2020 at 11:51 AM Viktor Dukhovni <postfix-us...@dukhovni.org>
wrote:

> On Wed, Oct 28, 2020 at 11:34:35AM -0400, Joey J wrote:
>
> > Since you are looking within the code, on a reject we used to put
> > @abc.com   550 and custom reject message
>
> There's no need to consult the code.  The lookup keys for access(5)
> tables are documented.  They DO NOT include "@domain".  To reject
> mail to/from all users at a domain the lookup key is just the
> domain name.  See the documentation.
>
>     http://www.postfix.org/access.5.html
>
>     EMAIL ADDRESS PATTERNS
>            With lookups from indexed files such as DB or DBM,  or  from
> networked
>            tables  such  as  NIS,  LDAP or SQL, patterns are tried in the
> order as
>            listed below:
>
>            user@domain
>                   Matches the specified mail address.
>
>            domain.tld
>                   Matches domain.tld as the domain part of an email
> address.
>
>                   The pattern domain.tld also matches subdomains,  but
> only  when
>                   the  string  smtpd_access_maps  is  listed  in  the
> Postfix par-
>                   ent_domain_matches_subdomains configuration setting.
>
>            .domain.tld
>                   Matches subdomains of  domain.tld,  but  only  when
> the  string
>                   smtpd_access_maps   is   not   listed   in   the
>  Postfix  par-
>                   ent_domain_matches_subdomains configuration setting.
>
>            user@  Matches all mail addresses with the specified user part.
>
>            Note: lookup of the null sender address is not possible with
> some types
>            of lookup table. By default, Postfix uses <> as the lookup key
> for such
>            addresses. The value is specified with the
> smtpd_null_access_lookup_key
>            parameter in the Postfix main.cf file.
>
> --
>     Viktor.
>


-- 
Thanks!
Joey

Reply via email to