PCZONE 討論區

PCZONE 討論區 (https://www.pczone.com.tw/vbb3/)
-   ☉ -- 架 站 DIY 討 論 版 (https://www.pczone.com.tw/vbb3/forum/47/)
-   -   【求助】Postfix 架在NAT之後被判定成有接受 relay (https://www.pczone.com.tw/vbb3/thread/47/108340/)

jerdd00 2005-03-12 11:13 PM

【求助】Postfix 架在NAT之後被判定成有接受 relay
 
目前我已經換成Postfix 2.2.0版本
收發信都可以,
但發生Mail Relay 的問題..
我的main.cf大致設定為
myhostname = mail.xxxx.xxx123.com
mydomain = xxxx.xxx123.com
myorigin = $myhostname
mydestination = $myhostname, www.$mydomain, mail.$mydomain, localhost
inet_interfaces = all
mynetworks = hash:/etc/postfix/access
relay_domains = $mydomain
alias_maps = hash:/etc/postfix/aliases
alias_database = hash:/etc/postfix/aliases
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain =
smtpd_sender_restrictions = reject_unknown_sender_domain
smtpd_recipient_restrictions = permit_mynetworks,permit_sasl_authenticated, reject_unauth_destination,
permit_mynetworks,reject_unknown_recipient_domain
smtpd_client_restrictions = permit_sasl_authenticated
smtpd_sasl_security_options = noanonymous

access內容
localhost.localdomain RELAY
localhost RELAY
127.0.0.1 RELAY
192.168.1 RELAY
mail.xxxx.xxx123.com RELAY
xxxx.xxx123.com RELAY

在http://140.111.1.22/tanet/spam.html測試後
會發生 "不行喔, 有接受 relay, 請依前頁說明修正你的 mail server"
maillog中產生訊息為
Mar 12 22:44:44 xxx postfix/smtpd[14099]: connect from unknown[192.168.1.250]
Mar 12 22:44:45 xxx postfix/smtpd[14099]: 112CE4B927: client=unknown[192.168.1.250]
Mar 12 22:44:45 xxx postfix/smtpd[14099]: lost connection after RCPT from unknown[192.168.1.250]
Mar 12 22:44:45 xxx postfix/smtpd[14099]: disconnect from unknown[192.168.1.250]

我在想,因我只有一個Public IP , 所有寄進來mail的IP,在分享器都會被轉換成Private IP,
也就是內部的GateWay IP 192.168.1.250 , 符合smtpd_recipient_restrictions = permit_mynetworks
而這造成postfix無法區分真正的來源而統統Relay!!

不知要如何解決...
請您幫幫忙哦!! :confused:

isakira 2005-03-13 08:36 AM

將ACCESS的這兩行拿掉:
mail.xxxx.xxx123.com RELAY
xxxx.xxx123.com RELAY

在分享器的設定,如果你要躲在NAT後:
你的分享器是否開了DMZ,且對應到你的SERVER?
請關閉DMZ,改用PORT對應。
(只開25,80,110)

jerdd00 2005-03-13 08:52 AM

我的分享器是用Port mapping , 開tcp port 25
沒有DMZ的功能耶...

access 也只剩
localhost.localdomain RELAY
localhost RELAY
127.0.0.1 RELAY

還是會Relay..

有安裝 cyrus-sasl-2.1.19-3..
在測試的時候都正常..
220 mail.xxxx.xxx123.com ESMTP Postfix
250-mail.xxxx.xxx123.com
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-AUTH LOGIN PLAIN <---
250 8BITMIME

但別人還是可以直接寄進來並Relay 出去..
怪怪?? :confused:


所有時間均為 +8。現在的時間是 06:02 AM



 XML   RSS 2.0   RSS 
本站使用 vBulletin 合法版權程式
站務信箱 : [email protected]

本論壇所有文章僅代表留言者個人意見,並不代表本站之立場,討論區以「即時留言」方式運作,故無法完全監察所有即時留言,若您發現文章可能有異議,請 email :[email protected] 處理。