Here is what I do, but maybe slightly different purpose: Listen on internal 
network, accept every mail and rewrite the recipient to LOCALUSERNAME (match 
and action bbb).
The LOCALUSERNAME has a .forward file with the desired MYUSER@MYDOMAIN address, 
which is then processed by match and action aaa.

Not the most elegant solution, but gets the job done.

listen on IF0
listen on IF1
listen on IF2

table authinfo db:/etc/mail/authinfo.db

action aaa relay host smtp+tls://USERNAME@RELAYHOST auth <authinfo>
action bbb mbox virtual { "@" => LOCALUSERNAME }

match from any for domain MYDOMAIN rcpt-to MYUSER@MYDOMAIN action aaa
match from any for any action bbb


> On 11. Apr 2022, at 17:05, Beau Ford <> wrote:
> Josey,
> On Mon, 11 Apr 2022, Josey Smith wrote:
>> Might not be what you want, but this two part guide includes a simple
>> catchall inbox in part two:
>> and
> Thanks - I will look at these.
>> It also does use a @ in the aliases file. Does this only work with
>> virtual users?
> I feel like I saw an example once where the '@' catchall address was 
> implemented neither in aliases nor in virtusers - there was actually a 2-3 
> line configuration *directly inside* smtpd.conf that implemented the '@' 
> catchall.
> Am I misremembering or is that a possibility - to implement the '@' catchall 
> directly inside smtpd.conf without reference to lookup tables or virtusers 
> (or aliases) ?
> Thanks.

Reply via email to