smtp_header_checks를 사용하여 보낸 사람 주소를 변경할 수 없습니다.

smtp_header_checks를 사용하여 보낸 사람 주소를 변경할 수 없습니다.

postfix 2.10을 사용하세요. main.cf의 기본값이 아닌 옵션:

smtp_header_checks = pcre:/etc/postfix/smtp_header_checks
relayhost = smtp.company.org

/etc/postfix/smtp_header_checks :

/from:.*/i REPLACE From: [email protected]

그러나 tcpdump는 다음 줄이 릴레이로 전송되었음을 보여줍니다.

MAIL FROM:<[email protected]>

로컬 sendmail로 보내겠습니다

답변1

나는 이 작업에 일반 지도를 좋아하지만, 게다가 이 방법으로는 야후에서 보낼 수 없습니다.

postconf -e smtp_generic_maps=hash:/etc/postfix/generic
echo 'root [email protected]' >> /etc/postfix/generic
postmap /etc/postfix/generic
service postfix restart

야후에서 보내려고요.

postconf -e relayhost=smtp.yahoo.co.uk:465 
echo 'smtp.yahoo.co.uk username:password' >>/etc/postfix/sasl_passwd
chown root:root /etc/postfix/sasl_passwd
chmod 600 /etc/postfix/sasl_passwd 
postmap hash:/etc/postfix/sasl_passwd

postfix가 설치되어 있으면 sendmail 명령을 실행하더라도 이를 사용하고 있거나 둘 중 하나를 설치할 수 있으면 postfix는 sendmail 래퍼를 설치합니다.

관련 정보