sendmail De vazio ao retransmitir

1

Ao enviar um e-mail logado como ec2-user para um usuário desconhecido:

echo "Subject: test" | /usr/lib/sendmail -v abc

o From:<> está em branco quando redirecionado para o alias do usuário ec2, o que está fazendo com que o servidor externo rejeite o e-mail. Mesmo definir -f "ec2-user@internal" não corrige isso.

Dentro do meu /etc/aliases tenho

root:     webmaster@external
ec2-user: webmaster@external

A saída detalhada exibe o seguinte:

abc... Connecting to [127.0.0.1] via relay...
220 internal ESMTP Sendmail 8.14.4/8.14.4; Thu, 24 Mar 2016 16:42:37 GMT
>>> EHLO internal
250-internal Hello localhost [127.0.0.1], pleased to meet you
250-ENHANCEDSTATUSCODES
250-PIPELINING
250-8BITMIME
250-SIZE
250-DSN
250-ETRN
250-DELIVERBY
250 HELP
>>> MAIL From:<ec2-user@internal> SIZE=14
250 2.1.0 <ec2-user@internal>... Sender ok
>>> RCPT To:<abc@internal>
>>> DATA
550 5.1.1 <abc@internal>... User unknown
503 5.0.0 Need RCPT (recipient)
>>> RSET
250 2.0.0 Reset state
>>> RSET
250 2.0.0 Reset state
ec2-user... Using cached ESMTP connection to [127.0.0.1] via relay...
>>> MAIL From:<> SIZE=1038
250 2.1.0 <>... Sender ok
>>> RCPT To:<ec2-user@internal>
>>> DATA
250 2.1.5 <ec2-user@internal>... Recipient ok
354 Enter mail, end with "." on a line by itself
>>> .
250 2.0.0 u2OGgbZL022963 Message accepted for delivery
ec2-user... Sent (u2OGgbZL022963 Message accepted for delivery)
Closing connection to [127.0.0.1]
>>> QUIT
221 2.0.0 internal closing connection

Quando envio um email para um usuário conhecido, como ec2-user ou root , o email é recebido.

Como posso configurar o sendmail para definir o endereço From ao transmitir desta maneira?

    
por Christian 24.03.2016 / 18:07

1 resposta

0

OK - isso tem a ver com a política de rejeição

5.2.9 Command Syntax: RFC-821 Section 4.1.2 

The syntax shown in RFC-821 for the MAIL FROM: command omits the case of an empty path: "MAIL 
FROM: <>" (see RFC-821 Page 15). An empty reverse path MUST be supported. 

5.3.3 Reliable Mail Receipt 
....... 
If there is a delivery failure after acceptance of a message, the receiver-SMTP MUST formulate 
and mail a notification message. This notification MUST be sent using a null ("<>") reverse 
path in the envelope; see Section 3.6 of RFC-821. The recipient of this notification SHOULD be 
the address from the envelope return path (or the Return-Path: line). However, if this address 
is null ("<>"), the receiver-SMTP MUST NOT send a notification. If the address is an explicit 
source route, it SHOULD be stripped down to its final hop.

Também no WIKI

Bounce messages in SMTP are sent with the envelope sender address <>, known as the null sender address.

link

    
por 24.03.2016 / 19:41

Tags