OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
Re: append_at_myorigin for envelope addresses?

From: mouss (moussnetoyen.net)
Date: Fri Aug 29 2008 - 10:18:37 CDT


Stefan Palme wrote:
> Hi,
>
> the following SMTP sessions works:
>
> ----------------------------------------------
>> telnet localhost 25
> ...
> EHLO localhost
> ...
> MAIL FROM: root
> 250 2.1.0 Ok
> RCPT TO: root
> 250 2.1.5 Ok
> DATA
> 354 End data with <CR><LF>.<CR><LF>
> To: root
> From: root
> Subject: test
>
> .
> 250 2.0.0 Ok: queued as 1FE944A4078
> ----------------------------------------------
>
> I receive the email in the correct mailbox. My main.cf contains
>
> append_at_myorigin = yes
> append_dot_mydomain = yes
> local_header_rewrite_clients =
>
> In the received mail the From: and To: headers are indeed only
> "root" (and not "rootmydomain.com").
>
> But what makes postfix accept the non-fully-qualified envelope
> sender and recipient addresses?

postfix is also used as a submission MTA. to reject non fqdn addresses,
use the appropriate smtpd checks.

> I don't want to allow this,
> I want to enforce "MAIL FROM: rootmydomain.com" etc...

This is invalid syntax. take a look at rfc[2]821.