0

Is there any possibility to redirect / discard email of unknown users instead of sending it back to the sender with a rejection message that user is unknown?

I don't want to use any milter for this purpose or any sender validation tool. Have sendmail ability into it to do this?

User4283
  • 781
  • 3
  • 10
  • 27

1 Answers1

2

The sendmail option you want is called LUSER_RELAY. To send all mail addressed to unknown users to "unknown" on the local system, you would put this line in your mc file:

define(LUSER_RELAY',local:unknown')dnl

Once you have built a new sendmail.cf file you will have a line that specifies the destination for all email addressed to unknown users:

DLlocal:unknown

To never deal with the email, put a .forward file in the target user's home:

| /dev/null

Chris Ting
  • 899
  • 4
  • 5