On 11/12/2010 01:00 PM, [email protected] wrote:
Zitat von Mingliang Zu <[email protected]>:

Hi,

I'm using postfix 2.3. My intention is to reject "MAIL FROM" command (give a 501 syntax error) if the sender doesn't contains '@'. I have worked on it
for two days but without any luck.

The following lines are added to main.cf. I was expecting
"strict_rfc821_envelope" to do the trick, but unfortunately, it doesn't.

smtpd_sender_restrictions =
    permit_mynetworks,
    reject_non_fqdn_sender,
    reject_unknown_sender_domain,
    permit
strict_rfc821_envelopes = yes
append_dot_mydomain = no
append_at_myorigin = no


See my test with these configurations:
[r...@rhel5 postfix]# telnet localhost smtp
Trying 127.0.0.1...

Don't test from localhost because it is included in permit_mynetworks most of the time. Further on you should use recipient verification

No. Why ?

so *every* MAIL FROM not valid is rejected,

Address verification is not a silver bullet. Don't make blanket statements like he SHOULD use it.


--
J.

Reply via email to