LINUX.ORG.RU
ФорумAdmin

freebsd sendmail sasl cyrus-imap проверка rcpt to


0

0

Имеется настроенный почтовый сервер. Авторизация проходит через sasl2, хранение почты в cyrus-imap

Конфик почтового сервера:

divert(-1)
divert(0)
VERSIONID(`$FreeBSD: src/etc/sendmail/freebsd.mc,v 1.30.2.2 2006/08/23 03:31:00 gshapiro Exp $')
OSTYPE(freebsd6)
DOMAIN(generic)

FEATURE(access_db, `hash -o -T<TMPF> /etc/mail/access')
FEATURE(blacklist_recipients)
FEATURE(local_lmtp)
FEATURE(mailertable, `hash -o /etc/mail/mailertable')
FEATURE(virtusertable, `hash -o /etc/mail/virtusertable',`relaytofulladdress')
dnl define(`_RELAY_FULL_ADDR_',`1')
dnl define(`LUSER_RELAY', `*file*:/dev/null')dnl

dnl Uncomment to allow relaying based on your MX records.
dnl NOTE: This can allow sites to use your server as a backup MX without
dnl your permission.
dnl FEATURE(relay_based_on_MX)

dnl DNS based black hole lists
dnl --------------------------------
dnl DNS based black hole lists come and go on a regular basis
dnl so this file will not serve as a database of the available servers.
dnl For that, visit
dnl http://directory.google.com/Top/Computers/Internet/Abuse/Spam/Blacklists/

dnl Uncomment to activate Realtime Blackhole List
dnl information available at http://www.mail-abuse.com/
dnl NOTE: This is a subscription service as of July 31, 2001
dnl FEATURE(dnsbl)
dnl Alternatively, you can provide your own server and rejection message:
dnl FEATURE(dnsbl, `blackholes.mail-abuse.org', `"550 Mail from " $&{client_addr} " rejected, see http://mail-abuse.org/cgi-bin/lookup?"; $&{client_addr}')

INPUT_MAIL_FILTER(`relaydelay', `S=local:/var/run/relaydelay.sock, T=S:1m;R:2m;E:3m')dnl
INPUT_MAIL_FILTER(`clamav', `S=local:/var/run/clamav/clamav-milter.sock, F=, T=S:4m;R:4m')dnl

dnl Dialup users should uncomment and define this appropriately
dnl define(`SMART_HOST', `your.isp.mail.server')

dnl Uncomment the first line to change the location of the default
dnl /etc/mail/local-host-names and comment out the second line.
dnl define(`confCW_FILE', `-o /etc/mail/sendmail.cw')
define(`confCW_FILE', `-o /etc/mail/local-host-names')

dnl Enable for both IPv4 and IPv6 (optional)
DAEMON_OPTIONS(`Name=IPv4, Family=inet')
DAEMON_OPTIONS(`Name=IPv6, Family=inet6, Modifiers=O')

define(`confAUTH_OPTIONS', `A')dnl
TRUST_AUTH_MECH(`DIGEST-MD5 CRAM-MD5 LOGIN PLAIN')dnl
define(`confAUTH_MECHANISMS', `DIGEST-MD5 CRAM-MD5 LOGIN PLAIN')dnl

define(`confBIND_OPTS', `WorkAroundBrokenAAAA')
define(`confNO_RCPT_ACTION', `add-to-undisclosed')
define(`confPRIVACY_FLAGS', `goaway,noetrn,novrfy,noexpn,restrictqrun,nobodyreturn,noreceipts')

define(`confTO_IDENT',`0s')dnl

define(`CYRUS_MAILER_PATH',`/usr/local/cyrus/bin/deliver')
define(`confLOCAL_MAILER',`cyrusv2')
MAILER(`cyrusv2')
MAILER(local)
MAILER(smtp)



В /etc/mail/access:

127.0.0 RELAY
192.168.0 RELAY

В /etc/mail/virtusertable:

ящик1@089.ru info123
ящик2@pallets.ru boxpallets
ящик3@taxorg.org mailbox
ящик4@pallets.ru thbox


Суть проблемы состоит в том, что почтовик принимает почту для несуществующих юзверей и потом уже генерит отлуп 550 5.1.1 xxxx@089.ru... User unknown

При этом в сессии он проглатывает этот ящик как Recipient ok...

shinkei@shinkei ~ $ telnet 089.ru 25
Trying 83.171.84.182...
Connected to 089.ru.
Escape character is '^]'.
220 ksunny.089.ru ESMTP Sendmail 8.13.8/8.13.8; Fri, 30 May 2008 11:02:47 +0400 (MSD)
helo shinkei.ru
250 ksunny.089.ru Hello [81.222.211.146], pleased to meet you
mail from: shinkei@ya.ru
250 2.1.0 shinkei@ya.ru... Sender ok
rcpt to: xxxx@089.ru
250 2.1.5 xxxx@089.ru... Recipient ok
data
354 Enter mail, end with "." on a line by itself
blah
.
250 2.0.0 m4U72l9t014861 Message accepted for delivery


После чего в логах:

cat /var/log/maillog | grep m4U72l9t014861
May 30 11:03:07 ksunny sm-mta[14861]: m4U72l9t014861: from=shinkei@ya.ru, size=7, class=0, nrcpts=1, msgid=<200805300703.m4U72l9t014861@ksunny.089.ru>, proto=SMTP, daemon=IPv4, relay=[81.222.211.146]
May 30 11:03:07 ksunny sm-mta[14861]: m4U72l9t014861: Milter add: header: X-Virus-Scanned: ClamAV version 0.93, clamav-milter version 0.93 on ksunny.089.ru
May 30 11:03:07 ksunny sm-mta[14861]: m4U72l9t014861: Milter add: header: X-Virus-Status: Clean
May 30 11:03:07 ksunny sm-mta[14875]: m4U72l9t014861: to=xxxx@089.ru, delay=00:00:06, xdelay=00:00:00, mailer=cyrusv2, pri=30007, relay=localhost, dsn=5.1.1, stat=User unknown
May 30 11:03:07 ksunny sm-mta[14875]: m4U72l9t014861: m4U7379t014875: DSN: User unknown


И далее:

May 30 11:03:08 ksunny sm-mta[14875]: m4U7379t014875: to=shinkei@ya.ru, delay=00:00:01, xdelay=00:00:01, mailer=esmtp, pri=30000, relay=mx1.yandex.ru. [213.180.204.89], dsn=2.0.0, stat=Sent (accepted; S8778325AbYE3HEV)


Как сделать так, чтобы sendmail проверял пользователя на стадии rcpt to: ????

Вы не можете добавлять комментарии в эту тему. Тема перемещена в архив.