Kiev1.org Карта сайта Файлы Фотографии Киева
  
Реклама:






???????
 
 Sysadmin
 ??????????????
 ????? ? ?????
 ??????????
 ???????????? ???????
 ?????????????
 ? ???????
 ? ???????????
 ???????? ? ??????
 ???????????
 ??????????? ???????
 ???????? ????? ?????? ?????? ???????? ??????????
 ??????
 ??????
 ?????? ?????? 1924-1994
 ??????? ?? ??????
 ???? ? ???????
 ????? ??????????
 ?????????


Внимание! Читая пророчества на этом сайте помните что достоверность трудно проверить и все может во времени изменяться - самое главное думать своей головой и не верить легкомысленно всему что говорят, особенно советское телевидение
"О дне же том, или часе, никто не знает, ни Ангелы небесные, ни Сын, но только Отец (Мк. 13, 32)"

???????? SpamAssassin, Postfix, MySQL, WebUsePref



????????? Postfix
???????????? SpamAssissin
????????? DrWeb (????? ??????? clamav)

????????? ???????? ???????

???????? ?? ????????? - ????????? ????????????.

????????? ???????? ??????? ?? Gentoo linux ??? ????????? ???????

???????????? postfix + cyrus-imap, ??????????? ????????????? ????? cyrus-sasl ??? ????????????? ?????-???? ?? (???????? ??? ?????? ? ??????????? ????????? ???????? ?????? - ??????? ???-???? ? mysql ??? postgress ? ?????? ?????? ??? ??????). ???????????? ???????? ? ???? sasldb, ??????? ??? ????? ???????? ? ??????? ???????? ?????????????.

???????? ??? ????????? ????????? ??????? ??????????? ?????????? ??? ???????????, ??????? ??? ?? ????? ?????. ??????????? ??????? ????? ???????????, ??? ?? ?? ?? ??????? - ??? ? ???? ?????? ??????? ???????????.

??????????? ???????????? ??? /var reiserfs, ?? ??? ?????? ?????? ????????????.


emerge -pv cyrus-sasl
[ebuild   N   ] dev-libs/cyrus-sasl-2.1.20  -authdaemond +berkdb -debug +gdbm +java -kerberos -ldap +mysql  +pam -postgres +ssl -static 0 kB

?? ?????? ?????? ????????? ????? - ??? ??

emerge cyrus-sasl

???? ????? ?????????, ???? ??????

emerge -pv postfix
These are the packages that I would merge, in order:
 Calculating dependencies ...done!
[ebuild   N   ] mail-mta/postfix-2.1.5-r1  +ipv6 -ldap -mailwrapper -mbox +mysql +pam -postgres -sasl*(-selinux) +ssl -vda 0 kB

????? ??? ????? ??????????? ???? sasl, ???? ? ???? ?????? ???? ??? ????? ?????????????? ?? smtp, ???????? ? ?????????? ????? ????? ??????? ??????????? ????? cyrus-sasl ?? smtp - ??????? ??????????? ????? ?? ????? ???? ??? ????

USE="sasl" emerge postfix

???????? ????????

emerge -pv cyrus-imapd
These are the packages that I would merge, in order:
Calculating dependencies ...done!
[ebuild   N   ] net-mail/cyrus-imapd-2.2.10  -afs -drac -idled -kerberos +pam -snmp +ssl +tcpd 0 kB

????? ???????? ? ????????? ?????? ??? ?????? ???????? imap-??????

emerge cyrus-imapd


????????? ??? ????????????????? ?????????? ??????

emerge cyrus-imap-admin


????? ???? ??? ??? ?????? ??? ?????? ??????????, ????? ?????????? ? ?????????

??????? cyrus-sasl

passwd cyrus
pwconv
chown -R cyrus:mail /etc/sasl2 - ?????? cyrus ? ???? /etc/sasl2/sasldb2
saslpasswd2 cyrus - ??????? ? sasldb2 
sasldblistusers2 - ??? ????????


??????????? ? postfix

C????????? /etc/postfix/main.cf, ???? ????????? ????????? ???????????? ????????? ??????? ????????????? ???????? ? ????? (?? ????? relayhost), ??????????? ??? ????? ?????? ?????? ???? MX-?????? ? ???. ???????????, ??? ????????? ??????? ?????? ????????? ? main.cf, ????? ?? ????????? ????????. ???????? ??? ????????? ?????????????? ????????????? postfix.


queue_directory = /var/spool/postfix
command_directory = /usr/sbin
daemon_directory = /usr/lib/postfix
mail_owner = postfix
myhostname = mail.domain.tld
mydomain = mail.domain.tld
myorigin = $mydomain
inet_interfaces = all
mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain
local_recipient_maps =
unknown_local_recipient_reject_code = 550
mynetworks_style = subnet
mynetworks = 192.168.1.0/24, 127.0.0.0/8
relay_domains = $mydestination
?? ??? ??????? ???????? ????????!!!
mailbox_transport = lmtp:unix:/var/imap/socket/lmtp


????? ???????? ???, ??? ????? ? main.cf, ???? ? /etc/postfix/master.cf

???? ????? ??????

 # Also specify in main.cf: cyrus_destination_recipient_limit=1
cyrus     unix  -       n       n       -       -       pipe
 user=cyrus argv=/cyrus/bin/deliver -e -r ${sender} -m ${extension} ${user}
 

? ???????? ???? ??

 # Also specify in main.cf: cyrus_destination_recipient_limit=1
cyrus     unix  -       n       n       -       -       pipe
 user=cyrus argv=/cyrus/deliver -e -r ${sender} -m ${extension} ${user}
 

???, ?????????? ???????????, ?????? cyrus-imapd

??????????? /etc/cyrus.conf

# $Header: /var/cvsroot/gentoo-x86/net-mail/cyrus-imapd/files/cyrus.conf,v 1.4 2004/07/18 04:02:23 dragonheart  Exp $
# Standard standalone server configuration.
START {
 # Do not delete this entry!
 recover	cmd="ctl_cyrusdb -r"
 # This is only necessary if using idled for IMAP IDLE.
 #idled		cmd="idled"
}
# UNIX sockets start with a slash and are put into /var/imap/socket.
SERVICES {
  # Add or remove based on preferences.
  imap		cmd="imapd" listen="imap2" prefork=0
  pop3		cmd="pop3d" listen="pop-3" prefork=0
   # Don't forget to generate the needed keys for SSL or TLS
  # (see doc/html/install-configure.html).
  imaps		cmd="imapd -s" listen="imaps" prefork=0
  pop3s		cmd="pop3d -s" listen="pop3s" prefork=0
  sieve		cmd="timsieved" listen="sieve" prefork=0
  # at least one LMTP is required for delivery
  #lmtp		cmd="lmtpd" listen="lmtp" prefork=0
   ##???????? ???????? ?? ??? ??????
  lmtpunix	cmd="lmtpd" listen="/var/imap/socket/lmtp" prefork=0
     # this is only necessary if using notifications
  #notify	cmd="notifyd" listen="/var/imap/socket/notify" proto="udp" prefork=1
}
EVENTS {
  # This is required.
  checkpoint	cmd="ctl_cyrusdb -c" period=30
  # This is only necessary if using duplicate delivery suppression.
  delprune	cmd="ctl_deliver -E 3" period=1440
  # This is only necessary if caching TLS sessions.
  tlsprune	cmd="tls_prune" period=1440
}


????? ??????????? /etc/imapd.conf

configdirectory:	/var/imap
partition-default:	/var/spool/imap
auto_transition:	yes
tls_ca_path:            /etc/ssl/certs
tls_cert_file:		/etc/ssl/cyrus/server.crt
tls_key_file:		/etc/ssl/cyrus/server.key
admins:			cyrus
hashimapspool:		yes
allowanonymouslogin:	no
allowplaintext:		yes
sasl_pwcheck_method:	auxprop
sasl_auxprop_plugin:	sasldb
sasldb_path:		/etc/sasl2/sasldb2
sasl_mech_list:		LOGIN PLAIN 

??????????? ????? ???? sasldb, ????????? ??????????? LOGIN,PLAIN ????? ?? ? ?????????? cyrus ?????????

?????? ???????? ????????? ??????? ??????, ??? ????? ?????????? ????????? cyradm

/etc/init.d/cyrus start
cyradm -user cyrus -server localhost
localhost> cm user.testuser
localhost> help - ??????? ??? ??????? ??? ??????? ????????? ???????
localhost> exit

?? ???????? ?????? ? sasldb2 ?????? ?????:

sasldbpasswd2 testuser


????????? ???????

/etc/init.d/postfix start
/etc/init.d/cyrus start

??????????? ????????? ??????? (????????? ? thunderbird 1.0 ? ? KMail 1.7.1, ? Outlook Express ???? ?????? ???? ???????).

??????? ????????? ?????? , ???? ???-?? ?? ???????? - ??????? ????, ?????? ????? ????????? ????? ?? ?????? ? /var/imap/socket/lmtp ??? ????????????? postfix ? cyrus, ???? ????? ???????? ??????? ?????? ? ????. ????? ????????? ????? ?? ?????? ? /etc/sasl2/sasldb2 ??? ???????????? cyrus.

?????????? ????????? ????????? ???????? cmalav ?????????? ??? ????? ?????? clamav + clamsmtp ???? ???????? ? ?????? ???????? ???????? amavisd-new. ????????? ????????? ??????? ????? http://www.nixp.ru/articles/clamav_postfix>, ?????????? ????????????????? ??,??????????? ? ?????????? ??? ?????? Gentoo

emerge clamav
ACCEPT_KEYWORDS="~x86" emerge clamsmtp (???? ???????????? ? ?????????)

????? ? ????? /etc/conf.d/clamd START_CLAMD = yes (??? ?????? ?????? 0.85 ??? ?? ????????? - ??? ????????? ?????? ? clamd.conf ? clamsmtpd.conf)

??????????? ????? /etc/clamd.conf ? /etc/clamsmtpd.conf ? ???????????? ? ?????????????? ???????????? ???? ?? ?????? ???????? ???????? ?? ????????? LocalSocket: /var/run/clamav/clamd.sock ? /etc/clamav.conf ? ClamAddress: /var/run/clamav/clamd.sock ? /etc/clamsmtpd.conf - ???? ? ??? ????? ?????? ?????????? ??? ????? ????????

rc-update add clamd default
rc-update add clamsmtpd default
/etc/init.d/postfix reload

??? - ????????? ?????? ????????? ??? ????? ?????????? ????? ??? ????????


P.S. ??? ????????????? ??????????? ?? ???? ??????? ?????? ? ?? ??????? ????????? ???????. ????? (??? ??????) ?? ????? ??????????????? ?? ???????????? ? ???????????? ?????????? ??????? ???????????. ???? ???????????? ? ????? ????? ? ? ??????! ?????? ???????? ?? ?????????? ?? ?????? ? ??????????? ? ?? ???????? ??????????? ????????? ????????? ????????????. ????? ??????? ??????????????? ????????????? ????????????? ????????????? ???????? ?? ?????????? ?????????? ? ??????? ????????????. ??????????? ??? ?????????????? ??????????? ?? ???????????? ? ????? ???????, ? ????? ????????? ????? ???????? ?? ?????????? ??????, ?????????? ? ?????? - ??????? ??????? ?? ??? ?? ???????.

 http://ru.gentoo-wiki.com/%D0%A3%D1%81%D1%82%D0%B0%D0%BD%D0%BE%D0%B2%D0%BA%D0%B0_%D0%BF%D0%BE%D1%87%D1%82%D0%BE%D0%B2%D0%BE%D0%B9_%D1%81%D0%B8%D1%81%D1%82%D0%B5%D0%BC%D1%8B

1. ?????????/????????? ????????? ??????? Postfix

????????? ?????????? ?? ?????, ?????????? ???????? ?????? Postfix:

# urpmi postfix

??? ??????? ??????? ????????? ???????:

# /etc/init.d/postfix start

??? ???????? ??????? ????????? ???????:

# /etc/init.d/postfix stop

???????? ?????? Postfix ????? ????? ????????? ????? ?????????, ??????????? ???????????? ??? ??? SMTP-?????? ??? ???????? ????? ? ????????? ??????.

??? ?? ?????, ?? ??????????? ???????? ? ???????????????? ????? /etc/postfix/main.cf ????????? ??????????:

  • myhostname = virtual.domain.tld ??????? ????? ???????? ??? ?????? ????? (????????, mail.mycompanyname.com.ua).

  • mydomain =domain.tld: ??????? ????? ???? ?????????? ???????? ???????? ??? (????????, mycompanyname.com.ua).

??? ????, ????? ???????????? ??????????? ?????????? ????? ????? ???? SMTP ?????? ?????? ? ????? ????????? ????, ????? ? ???????????????? ????? /etc/postfix/main.cf ????????? ?????????? ????????? ??????????:

  • inet_interfaces = all: ??? ?????????? ??????? ??? ????, ????? ? ??????? ????? ???????????? ?? ?????? ????????? ???????? ???????.

  • ????? ?????????? ????????? ?????????? mynetworks. ?? ????? ???????? ? ??????? ??: mynetworks = 127.0.0.0/8, 192.168.1.0/24 , ??? 192.168.1.0/24 ??? ???? ???????, ? ??????? ?? ?????????? ???????? ????? ????? ???? SMTP ??????.

    ????????

    ?? ?????????? ?????? ?? ????? ????! ?? ?????? ????????? ????????? ???????? ??????? ? ?????????? ????? ??????? ??? ???????? ?????. ????? ????, ? ???? ?????? ????? ????? ??????? ? black-list.

??? ????, ????? ??? ???????? ?????? ??? ????????? ????? ??? ?????? ????????? ??????, ?????????? ????? ??????????? ????????? ???????:

  1. ?????? ???? ????????? ??? ??? ??????? ????.

  2. ? ??? ?????? ???? ??????????? IP-????? ? ?????????? ??????????? ? ????????.

  3. ? ??? ?????? ???? ???????????????? ??????????????? ???????? ??? (???????? example.com).

  4. ?????? MX ?????? ?????? ?????? ????????? ?? ?????? ????.

?? ???????? ????? ???????? ????? ????????? ? ??????? ????????????? Postfix, ??? ??? ????????? ???????? ? ???? ?????? ????? ??????????? ????? ??????.

???????, ??? ???? ????????? ??????? ????????? ? ???????? /var/log/mail/. ??? ????????? ? ???????? ?????? ??????? ????? ????????? ??????? ????? ??????????????? ????????:

 # tail -f /var/log/mail/info

????? ????, ????? ?????? ??????? ?????????? ?? ??????? ????????? ???????. ??? ????? ??????? ???????????:

# mailq

???? ?? ?????? ??????????? ???????? ????? ?? ???????, ????? ????? ???????? ????????:

# postfix flush

2. ????????? pop3/imap ???????

????????, ???????? ?????????? ?????, ?? ??????? ????????? ???????? ?????? ????? ???????, ??? ?? ????? ?????????? ? ????????? ?????. ?????? ????? ???????? ????, ????? ???????????? ????? ???????? ???? ????? ? ???????. ??? ????? ?????? ???????????? ???????? POP3 (Post Office Protocol version 3) ???, ????, ???????? IMAP. ????? ????? ???????????? ?????????? ?????? ???? ?????????? POP3s ? IMAPs.

????????????? ????? imap:

# urpmi imap

???? ????? ???????? ???????, ??????????? ???????????? ????? ?? ??????? ????????????? ??????????. ?????? ??? ???????? ?????? ???????? ??????????? ??? ???????.

????, ?? ????? ???? ?? ?????????? ????????: ipop3, pop3s, imap, imaps. ???????? ???? ??????? ?????????? ????? xinetd. ??? ??????? ?? ?????????? ??? ???????? ????? ipop3, ??? ????? ?????? ????????????. ??????????? ???????? ????? ? ????? ???????? ?? ????? ???????? ????????.

?????? ????????? ??????, ?? ???? ?????????? ??????? ?? ?? ? xinetd:

# chkconfig --list ipop3

???? ?? ???????, ???????? ????? ? xinetd:

# chkconfig ipop3 on

????????? ????? ? xinetd ????? ???:

# chkconfig ipop3 off

???????? ????????, ??? ????? on ????? ????????? ??? ?????? ? ?????? ??? ????????, ? ????? off ????? ????????? ? ????????? ???? ??????.

??????? ?????????????? ????????? ??? ??????? ?????? ?? ???????.

 http://www.linux.opennet.ru/docs/RUS/mdkman/#id2873592 HOWTO postfix+spamassassin+AVP(via avcheck)+cyrus under FreeBSD

??????? ???????????

?????? POSTFIX?

postfix - ?????????????? MTA, ???????????? ??????? ?????? sendmail.
? ???? ????? ??????????? (???????????? ???????? ?????, ???????? ???? ????????????, ?????????? ????????? MySQL (?? ????? ??????????) ? ?.?. ? ?.?.), ?? ??? ????, ? ???? ?????, ???????? ???????? ????? ??????????? ??????? ?????????? ?????? ? ~/.forward. ??? ?????????? ????????? ?????, ??? ??? sendmail ?? ????????? ??????? ????? ? ???????????? ??? ????????? ????? ~/.forward ? ??? ????????? ?????????? ??????? ???? ? ???????????? ???????. ??? ?????????? ?????? ?????????, ???????? ?????? ?????????? ?????????? ? ???? .forward ? ???????? ??????? ???????????? ? ???????? ??? ?????
(| whoami |  mail -s test You@e-mail.ua)
??? ???????????? ???????? ???? ???? ????????? ???????? ???????? ????? ? ?????????????? ????????? vulnerabilities.
postfix ?????? ??? ???????? ??? ?? ?????????, ??? ? ????? ??????, ????? ??????? ? ????? ????????????
  # security reason - disable run commands from  ~/.forward
  allow_mail_to_commands = alias

p.s. telnet mx1.freebsd.org smtp :)

?????? AVP?

??? ?? ?????????, ??? ??????? ????? ? ??? ????????? ???????????? ?????? ??? ?????? ???????????????. ????????? ????? ????? ??????????????. ??? ???????, ????? ?????? ???????????? ?????????? ????????????. ??????? - ????????????? ?????????? ??? ? ???????????, ???????? ???? ???, ?? ??????????? ? ?????? ? ??????????. ?? ????????? AVP, ??? ??? ? ????????????? ????? ?????? ???. :) ? ???????? ???????? ?????? ??? ?????????? kavkeeper, ??????? ???????????? ????? ????? MTA ? ????? ???????????? ???????. ? ??? ??????? ????? ?? ??????? ????????????. ??????? - ??? ????????????? ?????? ?? ??????????. ??? ????? ????????? ????????, ?? ?? ????? ????????? postfix ? qmail. :( ?????? ????? ?? ????? ???????????? avcheck, ?????????? Michael Tokarev. ????? ????, ??? ??? ??? ????????, ?? ?? ???? ????????, ??? ????????? ?????????? ??? ???????????? ?????. ?? ???? ?? ??????????? ???????.

?????? CYRUS?

??? ??? ?????? ? ???????????? ?? ????????? - ?? ?????? ?? ??????????. ?? ????? ????????? ????????? ?????????????. ? ???? ?? ?? ????? ???????????? LMTP, ? ??? ??? ????? ??????????? ? ??????????. ????? ????, ?????? ? ????????? ? ??? cyrussasl ????????? ????????????????? ?????????????, ?????????? ????? ?? ?????????? POP3/IMAP ?? ?????? plain text, ?? ? CRAM-MD5, DIGEST-MD5. Outlook Express ?? ?? ????????????, ???? ?? ???????????? The Bat!, ??????? ????? ??????????? ? ??? :). ????????, ?????????? ?????????, ??? cyrus ??? ?? ???????????? SSL ????????? POP3S ? IMAPS. ? ???, ??????? ?? cyrussasl ????, ?? ????? ??????? ??? ?????????????? ?? ???? MySQL.

SPAM

???????? ?????? ??? ???? ??? ?????????????? ??? ????????, ????? ???? ??????? rbl, regexp ???? headers_check, body_check (? ???????????? postfix) ????? ?? ???????? ??????? ???????????. ???????? ??????? ?????? - ?????? ????????????. ??? ???????? ????? ?????????? ???? ?????????. ???, ?????????? ????????? ???. ????????? ??? spamassassin-??, ????? ??? ?????? BAYES ???????? ??? ???? ? ?????? ?????????????, ?.?. ??? ?????????? ???? ????????? ?? ???????? ??? ???? spam, ? ??? ???? ham - ?????????? ???????????????. ???????????? ?????, ????? ???? ;)

???????????? ? ???????????? ??????????, ????????? ? ?????????.
?????? ? postfix

  # cd /usr/ports/mail/postfix-current/
  # make all install  clean
??? ????? ???????????? ?????
  [ ] PCRE Perl Compatible Regular  Expressions
  [x] SASL Cyrus SASLv1 (Simple Authentication and Security  Layer)
  [ ] DB3 Berkeley DB3 (required if SASL also built with DB3)
  [ ]  MySQL MySQL map lookups 
  [ ] PgSQL PostgreSQL map lookups 
  [ ] OpenLDAP  OpenLDAP map lookups 
  [ ] Test SMTP/LMTP test server and generator 
  [ ]  TLS SSL and TLS (currently broken)
  [ ] IPv6 IPv6 support (not KAME  official)
? ?????? ?????? ??? ??????????? ?????? SASL
????? ????????? ?????? ??? ???????????? ? /usr/local/share/doc/postfix/,
????? ???????????? ? /usr/local/etc/postfix/
? FreeBSD ?????????? ? ???????? ?????????? ????????? ? /etc/mail/mailer.conf
? ????? ?????? ?? ?????? ????????? ???
  # more  /etc/mail/mailer.conf
  #
  # Execute the Postfix sendmail program, named  /usr/local/sbin/sendmail
  #
  sendmail /usr/local/sbin/sendmail
  send-mail  /usr/local/sbin/sendmail
  mailq /usr/local/sbin/sendmail
  newaliases  /usr/local/sbin/sendmail
????? ????, ??? ??? sendmail, ??? ???????, ??? ?????? ?? ???????????, ??????? ? /etc/make.conf ??????
  NO_SENDMAIL=true

??? ?????????? ? ????????? ???? sendmail ?????? ?? ?????????.
?????? ? /etc/rc.conf, ??? sendmail ?? ?????? ?? ??????????
  sendmail_enable="NONE"

????????????? ???????? ???? ???????????? postfix /usr/local/etc/postfix/main.cf
??????????? ????????? ?????? ????????, ?? ??? ??????? - ??????? ???:

? ?????? ???????? ???????????? ????????????? ????? ????????????. ?????

  mail_owner = postfix
  myhostname = ???_??????_?????
  mydomain =  ???_??????
  mydestination = ?????? ????? ??????? ??? ?????? ??????, ???  ??????? ?? 
                  ????????? ????? (???????? ????? ??????????) ??? ????????? ??  ????????.
  mynetworks_style = subnet (????, ????? ?? ??????? ?? ??????????  ?? ??????? ???. ?????? ????? ???????
                     ????? ??, ? ????? ? ??????? ??? ? ????.  ???? ?? ????????, ? ????? ????????????
                     ???????? ??? ???????????? ??????????  :)
  mynetworks = 192.168.1.0/24, 127.0.0.0/8
  #mynetworks =  $config_directory/mynetworks
????? ?????? ??????, ??? ??????? ?? ?????? ?????. ???? ?? ????, ????????? ??????.
  relay_domains =
???? ?? ?? ?????? ?????????? ????? ???????? ? ??? ? ??? ??????? ????????????? ??? ??????????, ?? ??? ???? ????????
  #relayhost = SMART_????_?????????? (? ???????????? sendmail)
?????????, ??? ???? aliases ????? ????????? ? ? ????? ???????
  #alias_maps =  dbm:/etc/aliases
  alias_maps =  hash:/usr/local/etc/postfix/aliases
  #alias_maps = hash:/etc/aliases,  nis:mail.aliases
  #alias_maps = netinfo:/aliases
  #alias_database =  dbm:/etc/aliases
  alias_database =  hash:/usr/local/etc/postfix/aliases
  #alias_database =  hash:/etc/aliases
  #alias_database = hash:/etc/aliases,  hash:/opt/majordomo/aliases
???, ??? ?? ???????????? ?? CYRUS, ?? ???????? ?? ???? ?????
  mailbox_transport = cyrus
???????? cyrus ??????? ? ????? ???????????? /usr/local/etc/postfix/master.cf
?? ???????? ? ???? ????? ????????? cyrus-?. ??????, ??? cyrus ????? ?????????? ?? ???? ?? ??????. ???? ?? ????? ???????????? lmtp, ?? ??? ????? ?????????? ????????? virtual. ????? ????????? ???????? ? ????????????.
????? ?? ?????? ?????? ??? ???????? ????? ?? ??????. ???? ?? ?? ?????????? ????????????? AVP - ??????????????? ??? ??????, ???????? ?????? ?????? #.
  # Antivirus scanner, see  /usr/local/etc/postfix/master.cf for more details
  content_filter =  avcheck
?????? ????, ?????????? ???????????? ?????????
  header_checks =  regexp:/usr/local/etc/postfix/bad_headers
(?? ? ???? ???????? ???:
          # don't receive mail with next file attachments 
          /^(Content-(Disposition: attachment;|Type:).*|(t| )+)(file)?name=.*.(vbs|pif|com|bat|scr|lnk)"?$/ REJECT We do not accepted mail with vbs|pif|com|bat|scr|lnk file extentions

	  /^Reply-To: .*@otvet.net/ 	REJECT We do not accepted mail from  spammers
	  /^Reply-To: .*@blabla.com/ 	REJECT We do not accepted mail from  spammers
	  /^Content-Type:.*X-Priority:.*X-Mailer:/ REJECT We do not accepted  mail with virus
	                                           (????????? (?) Netch ??? Klez-?)
}
????? ??????? ????????? :)
  smtpd_banner = $myhostname ESMTP service ready (Postfix  Rulezzz!!!)
??????????? ????????
  smtpd_sender_restrictions =  hash:/usr/local/etc/postfix/access
  transport_maps =  hash:/usr/local/etc/postfix/transport
?? ????????
  # security reason -  disable run commands from ~/.forward
  allow_mail_to_commands = alias
? ???? ????? ???. ? ??? ?? ?????????? ?????????????? ????? (access, transport ? aliases). ????? ?? ?????????????? ???????? ?? hash-?. ??? ????? postfix ?????????? ???? ??????? - postmap ? postalias ??? ????? aliases
  # postmap /usr/local/etc/postfix/access
  # postmap  /usr/local/etc/postfix/transport
  # postalias  /usr/local/etc/postfix/aliases
???? ? postfix ???.

????????? cyrus.

  
  # cd /usr/ports/mail/cyrus-imapd/
  # make configure
????? ?????????? ???????????????? ?????????, ?.?. ?? RFC 2047 ? Subject 8-?????? ??????? ?? ???????????, ?? ? ?????? ????????? ?? ??? ?????? ?? ???????? ????????. ???? ?? ?? ??????????? ??????????? RFC, ?? ???? ??? ?????????? ??????????. ???? ?? ?? ????? ?? ???????, ?? ????????? ?????? ?????? ?? ? ??? ????????? ? ?????: ?????????, ?? ??? ???-?? ? ???? ????. ????,
  # cd work/cyrus-imapd.??????/imap/
  # grep 'X' *
?????? ???, ??? ? ????? message.c (? ??? cyrus2 ? ? lmtpengine.c) ???? ???? if, ? ??????? ? ???????????? ?????. ?????? ????????. ? ???????? ??? ?????????? ?????? ???????, ?? ???? ?????????? ??? ????? ?????????? ?????? ;). ?????? ????????
  if (inheader && *p >= 0x80) { 
  ??
if ( 0 && inheader && *p >= 0x80 ) {
??? ????? ??????? ????????? ???? ??????? ?? ?????????? ;). ????????? ?????????:
  # cd ../../..
  # make all install clean
? ???????? ????????? ????? ????????????? ? ?????????? ? cyrussasl
??? ??????, ???????????? ? /usr/local/share/doc/cyrus/
????? ???????????? ? /usr/local/etc/ ?? ???
  cyrus.conf
  imapd.conf
???? ?? ?? ?????????? lmtp, ?? ???? cyrus.conf ????????????? ?? ?????????.
????????????? cyrus ?????? imapd.conf
??????, ??? ???? ???????, ??? ???????, ??? ????? ???????????????. ????????????? ?? ???????????? root ??? ?????. ????? ???????? ? ????????????.
  admins: admin
?????? ????
  sievedir:  /var/imap/sieve
  sendmail: /usr/local/sbin/sendmail
? ????? ?????????????? ?????????????
  sasl_pwcheck_method: sasldb
?????????, ?? ??? ???????? ?? ???????, ??? ??? ??????????? ?? ???????? ???????????? ? ????? ???? ????????????? ???????.
  sasl_auto_transition: no
???? ?????????? ???? ???????? ? yes, ?? ????? (!) ????????????, ???????? ?? ?????????? POP3|IMAP ????? ??????? ? ???? ? ??? ???? ????? ?????? ???????? ????.
????? ???? ??? ?? ???????? ? imapd.conf ??? ????, ????? ??????? ???????? ????????? ??? ???????? ??????
# /usr/local/cyrus/bin/mkimap
????? ? ?????? ???? ????????????? ???????? ? ????? /usr/local/etc/sasldb. ????????:
  -rw-r----- 1 cyrus mail  sasldb
??????????? ???????????? ????????????? ????? ???????? sasldblistusers.
??? ???? ???????? ???????????? admin
  # saslpasswd -c admin
? ?????? ??????.
?????? ?? ????? ????????? cyrus.
cyrus ?? ????????? ?????????? ????????? tcp wrappers. ? ????? /etc/hosts.allow ?????????? ??????? IP ?????????????, ??????? ????? ???????? ?????. ?? ???????? ??? ?????? ???? ??? ?? ??????, ???????? ? ??????????? ?????, ?? ?????? ?????????, ??? ???? ??? ?? "??????????????". ????? ?????, ??????? ????, ?? ?????? ? ???? ?? ?????? ?? ?????. :( ? ?? ?????????????? ????????? ???? ???????????? pop3, imap, sieve (port tcp/2000), ? ??????? ??? ????? ? ???? firewall-??.
??? ????????? cyrus-? ? ???????? /usr/local/etc/rc.d/ ??? ?????? ?????? ??????? cyrus.sh.
???????? ??? ? ?????????? start.
  # /usr/local/etc/rc.d/cyrus.sh start
??????????? ? ????????? ??????? ???????? ????? ???????
  # cyradm -u admin localhost 
??? ??? ??????? ? ??? ??????? ??????, ??????? ?? ??????? ??? ???????? ????? ???????????? saslpasswd
??????? help ????????? ??? ?? ????????? ????????. ???????? ????????, ??? ???????? ????? ????? ????? ??????? user.????.
??? ????, ??? ?? ??????? ???????? ???? ????????? ????? ???????
  localhost> cm  user.uafug
  localhost> lm
??????? ??? ??? ???????????? ???????? ?????.
  localhost> quit
?? ??????? ???????? ???? ??? ???????????? uafug. ?? ?????????? ?? ?????? ?????????? ??? ??????
  # saslpasswd -c uafug
??? ?? ?????, ???? ????? ???????? ????, ?????????????? ???? /etc/syslog.conf
  auth.* /var/log/auth.log
  local6.debug  /var/log/cyrus.log
? ??? ?? ???? ?? ??????????? ???? ?????? /etc/newsyslog.conf
  /var/log/auth.log  600  3 100 * Z
  /var/log/cyrus.log 600  3 100 * Z
??? ?????????? ??????????? ? ????
  # touch /var/log/auth.log /var/log/cyrus.log
  # chmod 600 /var/log/auth.log /var/log/cyrus.log
  # killall -HUP syslogd 

???????? ? postfix

  # cd /usr/local/etc/postfix
? ?????? ???, ??? ???????? ?????????? ????? ??? ????? ????????????? ? ????? master.cf. ??? ????? ?? ? ?????????? ????????? ???? ????? ? ????? main.cf ???????? cyrus
  cyrus  unix - n n - - pipe
  flags=Ru user=cyrus argv=/usr/local/cyrus/bin/deliver -e  -m ${extension} ${user}
????????? ???????????? ????. ???? u ?????????, ??? ????? ????????????? ??? ???????? ?????????? ????????? ? ?????? ???????.
See man pipe for more.
???? ??? ????? postfix ????? ? ??????. ???? ? ??? ??? ???????? sendmail - ????????? ???
  # cd  /etc/mail
  # make stop
? ???????? postfix
  # /usr/local/sbin/postfix  start
??? ????, ??? ?? postfix ?????????? ?????????????, ??????? ?????????? ????
  # ln -s /usr/local/sbin/postfix /usr/local/etc/rc.d/postfix.sh
????????? ?????. ??????? ? /etc/daily.local ?????????
  #!/bin/sh 

  echo
  echo Checking for troubles in mail: 
  start=`date -v-1d '+%b %d' | sed 's/0(.)$/ 1/'`
  cat /var/log/maillog |  grep "$start" | egrep '(reject|warning|error|fatal|panic):'

? ?????? ???.

?????? ???????? ? AVP.
??? ????? kav-WorkStationSuit-3.0.136-FreeBSD-4.x.tgz, ???? ???????? (???, ???????, ?? ?????? ????? ? ???????) ? avcheck (? ????? http://www.corpit.ru/avcheck/).> ?? kav-WorkStationSuit-3.0.136-FreeBSD-4.x.tgz ??? ????????? ?????? ?????, updater ??? ? ???? ?????? ?????????. ???????????? kav-postfix-3.0.136-FreeBSD-4.x.tgz ?? ?? ?????. ????? ??????? ?? ?????????? ?? ?????.
??? ?????? ?????????? ????? ? ???? SYSV*. ????? ???????? ??. /sys/i386/conf/LINT. ???????? ??????????? ??????????? ???? ???? ? ????? ??????? ;).
???????? ???????, ? ??????? ? ????? ???? ??? ???? ?????????? ? ??????? ????? chroot ??? ????? ???????????? ????????. ? ???? ??? /var/spool/avp/.

  # mkdir /var/spool/avp/
  # cd  /var/spool/avp/
?? ????????? kavdaemon ?????? ???????? ?? ????, ?? ??? ? ??? ???? ;). ???? ??????? ????????????? ? ?????? ??? ?????.
  #  vipw
  avdaemon:*:64:65::0:0:AVP  Daemon:/nonexistent:/nonexistent
  avclient:*:65:65::0:0:AVP  Client:/nonexistent:/nonexistent
? ? /etc/group
  avgroup:*:65:
?????? ?? ?????? ??????????????? avcheck ? ???? ?????? avcheck-0.8
  # tar xvfz  avcheck-0.8.tar.gz
  # cd avcheck-0.8
  # make
  # cp avcheck  /var/spool/avp/
  # cp uchroot /var/spool/avp/
  # mkdir  /var/spool/avp/infected
  # cp infected.ex2.ru  /var/spool/avp/infected
?????????????? /var/spool/avp/infected/infected.ex2.ru
  FROM=Antivirus-Daemon
  VIRUS_ALERT=alert@you_host.ua  # set to empty to skip administrator email

? ???????, ? ??????????????? ???? ???? ???, ??? ?? ??????????? ?? ?????????? ????? ???????? (??????? ???? ???? ????????? ;)
???????? ? ???????????? ?????????? ??????, ??? ?? ??? ??????? ??????????????. ???????????? ?????????? ??????. ;)
???? ?????????
  # cd  /var/spool/avp
  # cp /???/? ???/???/kavdaemon /var/spool/avp/
  # cp /???/?  ???/???/kavupdater /var/spool/avp/
  # cp /???/? ???/???/AvpUnix.ini  /var/spool/avp/
  # cp /???/? ???/???/defUnix.prf /var/spool/avp/
  # cp  /???/? ???/???/?????/key /var/spool/avp/
  # mkdir bases ctl dev proc tmp tst  usr
  # chown avdaemon:avgroup bases ctl kavdaemon tmp
  # chown  avclient:avgroup tst
  # cd dev
  # mknod console c 0 0
  # mknod null c 2 2
? ????? ?? ?????? ???????? ?????????
  -rw-r--r-- 1 root     wheel     1199 12 ??? 2001  00030ADE.key
  -rw-r--r-- 1 root     wheel      116 12 ??? 2001  AvpUnix.ini
  -rwxr-xr-x 1 root     wheel    19282 13 ??? 10:14 avcheck*
  drwxr-xr-x 2 avdaemon avgroup   1024  6 ??? 03:55 bases/                 ???????? ???????? ?? ????????? ????? ????????
  drwxrwx--- 2 avdaemon avgroup    512 28 ??? 15:38 ctl/
  -rw-r--r-- 1 root     wheel     1854 15 ??? 09:36 defUnix.prf
  drwxr-xr-x 2 root     wheel      512 12 ??? 2001  dev/
  drwxr-xr-x 2 root     wheel      512 12 ??? 2001  infected/
  -rwxr-xr-x 1 avdaemon avgroup 254572 12 ??? 2001  kavdaemon*
  -rwxr-xr-x 1 root     wheel    95672 15 ??? 11:08 kavupdater*
  drwxr-xr-x 2 root     wheel      512 12 ??? 2001  proc/
  drwxrwx--- 2 avdaemon avgroup    512  6 ??? 11:56 tmp/
  drwxr-x--- 2 avclient avgroup    512  6 ??? 11:56 tst/
  -rwxr-xr-x 1 root     wheel     7205 13 ??? 10:14 uchroot*
  drwxr-xr-x 4 root     wheel      512 12 ??? 2001  usr/

?????? ????????, ?????? ???????????? ?????????? kavdaemon ? kavupdater
  # ldd  kavupdater
  kavupdater:
  libintl.so.1 => /usr/local/lib/libintl.so.1  (0x28078000)
  libm.so.2 => /usr/lib/libm.so.2 (0x2807d000)
  libc.so.4  => /usr/lib/libc.so.4 (0x28099000)
  # ldd  kavdaemon
  kavdaemon:
  libintl.so.1 => /usr/local/lib/libintl.so.1  (0x28097000)
  libm.so.2 => /usr/lib/libm.so.2 (0x2809c000)
  libc.so.4  => /usr/lib/libc.so.4 (0x280b8000)

????????? ??? ?????????? ? ??? ??????? usr/, ??? ?? ???????? ????? ?? ???? ???????????? ???????? ????????, ??????? ? ????? ??? ????????.
? ????? AvpUnix.ini ?????????? ???????? ????????? ??????
  [AVP32]
  DefaultProfile=defUnix.prf
  [Configuration]
  KeyFile=00030ADE.key
  KeysPath=/
  SetFile=avp.set
  BasePath=/bases
? ? defUnix.prf:
  # same section with parameters for  objects
  [Object]
  Names=*/tst
  [Report]
  Report=No
  [TempFiles]
  UseMemoryFiles=No
  LimitForMemFiles=6000
  MemFilesMaxSize=20000
  TempPath=/tmp
??????? ???? ?? ???????? softupdates ??? ????? ??????? ;) man tunefs
  [Mail]
  SendMail=No
????????? - ? ???????????? ? ????????????? ? ?? ?????? ??????????
??????? ???? (kavupdater ??? ?????????? ??? ?????????? wget. ??? ?????????? ????????? ?? ??????, ???? ? ??? ??? ???)
  /var/spool/avp/kavupdater -y -kb  -ui=ftp://ftp.avp.ru/updates -b=/var/spool/avp/bases/
??? ?????? ????? (???, ?????) ???????? ? crontab, ????? ???? ??????????? ?????? ????. ?? ????????? support-? ?? killall -HUP kavdaemon ?? ???? ???????????? ????.
???????? ????????? ??????. ? ???????? ???????? ???
  # more  /usr/local/etc/rc.d/kavdaemon.sh
  #!/bin/sh 
  
  echo Starting AVP Daemon
  /usr/bin/env - HOME=/ /usr/bin/nice  
  /var/spool/avp/uchroot -u avdaemon 
  /var/spool/avp /kavdaemon -Y -MP  -f=/ctl /tst 
???? ??? ????????? ? ????? ?????, ?????? postfix ;)
??? ?????? ??????? ? /usr/local/etc/postfix/master.cf ????????? ??????
  avcheck unix - n n - 5  pipe
  flags=q user=avclient argv=/var/spool/avp/avcheck
    -i  /var/spool/avp/infected/infected.ex2.ru -h Ok
    -d /var/spool/avp/./tst -s  AVP:/var/spool/avp/ctl/AvpCtl -f ${sender}
    -S  :1025 -- ${recipient}
  (??????, ?????????? ???????????? flags ?????? ?????????? ? ???????)
? ? ??????, ? ??????????? ?? ???? ????????
1) ??? ??????????? ?????? (????? ??????????? ???, ???? ???????????? ?? ????? smtp)
  smtp inet n - n - -  smtpd
  localhost:1025 inet n - n - - smtpd -o content_filter=
???????? ????????, ??? ??? ???? ?????? ? main.cf ?????? ???? ???????
  content_filter=avcheck

2) ??? relay ?????? (??????????? ?????? ??, ??? ?????? ????? smtp)

  smtp  inet n - n - - smtpd -o content_filter=avcheck
  localhost:1025 inet n - n - -  smtpd -o content_filter=
???, ??? ?????????? ????????? ? ????
  # postfix  reload
?? ????? ?????, ??? ????? ???????????, ???????? avcheck-?, ????? ???????????????? ?? localhost ? ???????? cyrus-?.

? ??? ?? SPAM?

? ??? ??? ?? ???????, ??? ??? ? ???? ?? ????????? ?????? ????? ????, ??? ?????????, ??? ??? ????????? ??? ????????. ??? ????????? ???? ????????, ??????? ???????? ;)
???? ????? ? ?????.

  # cd /usr/ports/mail/p5-Mail-SpamAssassin/
  # make install clean
  # cd /usr/local/etc/mail/spamassassin/
  # cat local.cf
trusted_networks 192.168/16 127/8           # all in 192.168.*.* and 127.*.*.*
trusted_networks 127.                       # all in 127.*.*.*
clear_trusted_networks
rewrite_subject 1
subject_tag             ***SPAM***

required_hits           5.0
report_safe             0
always_add_report       1

use_bayes               1
bayes_auto_learn        1

  # mkdir /var/spool/spamd
  # chown avclient:avclient /var/spool/spamd
  # vipw
 ? ??? ????? ?????? ???????? ??????? avclient ?? /var/spool/spamd
?????? ????? ????????? ???: avclient:*:65:65:AVP Client:/var/spool/spamd:/nonexistent
? ??????? ??????? ?????????? ?????? ????????? ? ?????? 38
spamd_flags=${spamd_flags:-"-u avclient -Q -L -m 16 -a -c -d -r ${pidfile}"}
? ????????? ??? ????? spamd.
  # /usr/local/etc/rc.d/spamd.sh start
???? ??????? ? /var/log/maillog, ??? ??? ??????????? ?????? ??? ?????? ? ??????, ????? ???? ???????????.
?? ? ?????? ????? ??????? ??? ;) ???? ?????? ? ????????? ? ????? master.cf ????? ??? ?????
avcheck   unix -        n       n       -       5       pipe
    flags=q user=avclient argv=/usr/local/bin/spamc -u avclient -e /var/spool/avp/avcheck
        -i /var/spool/avp/infected/infected.ex2.ru -h Ok
        -d /var/spool/avp/./tst -s AVP:/var/spool/avp/ctl/AvpCtl -f ${sender} -S :1025 -- ${recipient}

?????? ? ??? ????? ??? ?? ? ??????? ;)
????????? ??? ???????? ????????
  # postfix reload
?????! ;)

spamassassin "?? ???????" ????? ???????????? ????? 50-70% ?????, ?? ??? ?? ??? ???????, ?????????? ??? ????????
???????????? ???????????? ???????? ? (!) ?????????? ?????. ??????? 2 ????????, ?????? ???? ?????? ? ???????????
? ?? ?????????? ?? ??? sa-learn. ?????? bayes ?????? ??????? ???? ?????? ?????? ????? ?????????? ?
???? 200 (?? ?????????) ????? ???? ? ????? ????.

  # mkdir /var/spool/spamd/ham
  # mkdir /var/spool/spamd/spam
  # mv ~ftp/incoming/spam/* spam
  # mv ~ftp/incoming/ham/*  ham
  # sa-learn --ham /var/spool/spamd/ham/
  # sa-learn --spam /var/spool/spamd/spam/
  # rm /var/spool/spamd/spam/* /var/spool/spamd/ham/*
  # /usr/local/etc/rc.d/spamd.sh restart

That's all, folks.

??????? Gleb Smirnoff ?? ??????????? ? ??????????? ???? ??????.
??????? ?????????? ??? ????? ???????? ??????.

??? ????? ?????? ?? ?????????? ???????? ?????? ?????? ???? ???????, ??? ?... ???? ??? ????? ??? ?????????? - ???? ???.
????? ????, ??? ?? ?? ?????. ???????? ? 300-400 ?????? ?????? ?? ?????????, ?? ????????. ?????!

Konstantin Nikonenko
Last changed: ???????, 5 ????? 2004 ?. 09:33:32 (EET)

 http://www.kot.dp.ua/postfix_avp_cyrus.html

???????? SpamAssassin, Postfix, MySQL, WebUsePref

?????? ????????? SpamAssassin ? DrWeb - ????? ?????!!!

Mail-relay (?? Spam-????????) ????????? ????? ?? ?????????, ??????????? ?? ? ???????? ?? ????????? Mail-Server ( ????. Domino)

??????:gennadi.ru
Mail-relay: mail-relay.gennadi.ru 192.168.0.1
Mail-Server Domino:domino.gennadi.ru 192.168.0.2

????... ??? ??????? ??????? ??? ?????????? ????? ?????????? ????????? ??????:

rpm -i perl-Digest-SNA1*
rpm -i perl-Digest-SMAC*
rpm -i perl-HTML-Target*
rpm -i perl-HTML-Parser*
rpm -i perl-Net-DNS*
rpm -i perl-Time-HiRes*
rpm -i spamassassin*

???? ??? SuSE - ??? ?????:
??????:
mail-relay:~ # yast

- ? ?.?,

???? RedHat ?? :
??????:
mail-relay:~ # up2date spamassassin


1.) ????????? Postfix

???? /etc/postfix/main.cf ???????? ???:
??????:
mail_spool_directory = /var/mail
canonical_maps = hash:/etc/postfix/canonical
virtual_maps = hash:/etc/postfix/virtual
relocated_maps = hash:/etc/postfix/relocated
transport_maps = hash:/etc/postfix/transport
sender_canonical_maps = hash:/etc/postfix/sender_canonical
masquerade_exceptions = root
masquerade_classes = envelope_sender, header_sender, header_recipient
masquerade_domains = gennadi.ru
mydomain = gennadi.ru
myorigin = $mydomain
myhostname = mail-relay.gennadi.ru
internal_mail = 192.168.0.2 #(??? Domino Mail-Server)
mynetworks = $internal_mail, 127.0.0.0/8
program_directory = /usr/lib/postfix
inet_interfaces = all
mydestination = $mydomain
defer_transports =
disable_dns_lookups = no
relayhost =
content_filter =
mailbox_command =
smtpd_sender_restrictions = hash:/etc/postfix/access
smtpd_relay_reject = no
smtpd_client_restrictions =
smtp_always_send_ehlo = yes
smtpd_helo_required = no
smtpd_helo_restrictions =
strict_rfc821_envelopes = no
smtpd_recipient_restrictions = permit_mynetworks,permit_mx_backup,permit_sasl_authenticated,check_relay_domains
broken_sasl_auth_clients = yes
smtp_sasl_auth_enable = yes
smtp_sasl_security_options = noanonymous
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtpd_sasl_auth_enable = yes

smtpd_use_tls = yes
smtpd_tls_key_file = /etc/ssl/certs/server.key
smtpd_tls_cert_file = /etc/ssl/certs/server.key
smtpd_tls_CAfile = /etc/ssl/certs/server.key
smtpd_tls_loglevel = 3
smtpd_tls_received_header = yes
smtpd_tls_session_cache_timeout = 3600s
tls_random_source = dev:/dev/urandom

alias_maps = hash:/etc/aliases
mailbox_size_limit = 51200000
message_size_limit = 10240000

2.) ? ???? /etc/postfix/transport ?????? ????????? ??????:
??????:
gennadi.ru smtp:[192.168.0.2 ]

? ????????????? transport.db
??????:
mail-relay:~ # postmap /etc/postfix/transport

3.) ? ???? /etc/postfix/master.cf ?????? ????????? ?????????:
??????:
# ==========================================================================
# service type private unpriv chroot wakeup maxproc command + args
# (yes) (yes) (yes) (never) (100)
# ==========================================================================
smtp inet n - y - - smtpd -o content_filter=filter:
smtps inet n - n - - smtpd -o smtpd_tls_wrappermode=yes -o smtpd_sasl_auth_enable=yes

#submission inet n - n - - smtpd
# -o smtpd_enforce_tls=yes -o smtpd_sasl_auth_enable=yes
#628 inet n - n - - qmqpd
pickup fifo n - n 60 1 pickup
cleanup unix n - n - 0 cleanup
qmgr fifo n - n 300 1 qmgr
#qmgr fifo n - n 300 1 nqmgr
#tlsmgr fifo - - n 300 1 tlsmgr
rewrite unix - - n - - trivial-rewrite
bounce unix - - n - 0 bounce
defer unix - - n - 0 bounce
flush unix n - n 1000? 0 flush
proxymap unix - - n - - proxymap
smtp unix - - n - - smtp
relay unix - - n - - smtp
# -o smtp_helo_timeout=5 -o smtp_connect_timeout=5
showq unix n - n - - showq
error unix - - n - - error
local unix - n n - - local
virtual unix - n n - - virtual
#lmtp unix - - n - - lmtp

#localhost:10025 inet n - n - - smtpd -o content_filter=
#
# Interfaces to non-Postfix software. Be sure to examine the manual
# pages of the non-Postfix software to find out what options it wants.
#
# maildrop. See the Postfix MAILDROP_README file for details.
#
maildrop unix - n n - - pipe
flags=DRhu user=vmail argv=/usr/local/bin/maildrop -d ${recipient}
cyrus unix - n n - - pipe
flags=R user=cyrus argv=/usr/lib/cyrus/bin/deliver -e -m ${extension} ${user}

uucp unix - n n - - pipe
flags=Fqhu user=uucp argv=uux -r -n -z -a$sender - $nexthop!rmail ($recipient)
ifmail unix - n n - - pipe
flags=F user=ftn argv=/usr/lib/ifmail/ifmail -r $nexthop ($recipient)
bsmtp unix - n n - - pipe
flags=Fq. user=foo argv=/usr/local/sbin/bsmtp -f $sender $nexthop $recipient
vscan unix - n n - 10 pipe
user=vscan argv=/usr/sbin/amavis ${sender} ${recipient}
procmail unix - n n - - pipe
flags=R user=nobody argv=/usr/bin/procmail -t -m /etc/procmailrc ${sender} ${recipient}
filter unix - n n - - pipe
user=spamfilter argv=/usr/local/bin/spamfilter.sh -f $(sender) -- $(recipient)


4.) ???????? SSL Cerifikat ??? Postfix
??????:
mail-relay: # openssl req -new -x509 -sha1 -extensions v3_ca -nodes -days 365 -out cert.pem

???????? ??? ????? - privkey.pem ? cert.pem. ??????:
??????:
mail-relay: # cat privkey.pem cert.pem > /etc/ssl/certs/server.crt
mail-relay: # mv -f privkey.pem /etc/ssl/certs/server.key

5.) ???????? ????? spamfilter, ?? ????? ???????? ????? ??????????? ?????? spamfilter.sh .
??????:
mail-relay:~ # useradd -g mail -s /bin/false -d /var/spool/filter spamfilter
mail-relay:~ # mkdir /var/spool/filter
mail-relay:~ # chown spamfilter:mail /var/spool/filter


6.) ???? ?????? spamfilter.sh ???????? ? ?????????? /usr/local/bin.
??????:
#!/bin/sh

INSPECT_DIR=/var/spool/filter
SENDMAIL="/usr/sbin/sendmail -i"
SPAMASSASSIN=/usr/bin/spamc
EX_TEMPFAIL=75
EX_UNAVAILABLE=69

cd $INSPECT_DIR || { echo $INSPECT_DIR does not exist; exit $EX_TEMPFAIL; }

# Clean up when done or when aborting.
trap "rm -f in.$$; rm -f out.$$" 0 1 2 3 15

cat | $SPAMASSASSIN > out.$$ || { echo Message content rejected; exit $EX_UNAVAILABLE; }

$SENDMAIL "$@&quot; < out.$$

exit $?


7.) ???????????? SpamAssissin.
? ?????????? /etc/mail/spamassassin ??????? ???? local.cf ? ???????? ???? ????????????? ??????:
??????:
required_hits 5
rewrite_header 1
report_safe 1
use_bayes 1
auto_learn 1
use_terse_report 1
always_add_headers 1
fold_headers 1
spam_level_stars 1
spam_level_char *
rewrite_subject 1
subject_tag !!!!*****SPAM*****!!!!
ok_languages ru
ok_locales en
use_razor1 1
use_razor2 1
use_pyzor 1
use_dcc 1
skip_rbl_checks 0
body VIAGRA /viagra/i
body PENIS /penis/i
score VIAGRA 2
score PENIS 2
blacklist_from *@msn.com
blacklist_from *@hotmail.com
whitelist_from *@gennadi.ru


??? ??????? ???????????? ( ??? ??????? ), ??? ? ??????, ??? ?????? ?????????? ????? VIAGRA ? PENIS ??? ?? ???????????? *@msn.com ? *@hotmail.com ????? ???????? ??? spam. ?????? ?? ???????????? *@gennadi.ru ????? ???????? ?????????.
??????????????? ??? ??? ????? ???? ? ????? ????.
? Google ?????????? ???????? ?? ???????????? ????? ?????.
??????:
mail-relay:~ # postfix reload
mail-relay:~ # /etc/init.d/postfix restart
mail-relay:~ # /etc/init.d/spamd restart

8.) ??? ?? ??? ?????? ?? ????????? ????????? ???????? ?? spam, ???????? ?? ????? firewall'e NAT ? ????? mail-relay.gennadi.ru ?? ???? 25 ( smtp) ? ???? 465 ( smtps ).

9.) Test
?????? ????? ??????? ?????? ?? ????????? ?????????? ?????.
? ???? ??????? ??? gennadi@gmx.net ???????? ?????? ?? ????? gennadi@gennadi.ru.
??????:
mail-relay:~ # tail -fn 100 /var/log/mail

Jan 25 16:37:33 mail-relay postfix/smtpd[7484]: starting TLS engine
Jan 25 16:37:33 mail-relay postfix/smtpd[7484]: connect from unknown[213.165.64.20]
Jan 25 16:37:33 mail-relay postfix/smtpd[7484]: 93F9924C9E: client=unknown[213.165.64.20]
Jan 25 16:37:33 mail-relay postfix/cleanup[7486]: 93F9924C9E: message-id=<16175.1075044591@www15.gmx.net>
Jan 25 16:37:34 mail-relay postfix/qmgr[1555]: 93F9924C9E: from=<gennadi@gmx.net>, size=897, nrcpt=1 (queue active)
Jan 25 16:37:34 mail-relay postfix/smtpd[7484]: disconnect from unknown[213.165.64.20]
Jan 25 16:37:34 mail-relay spamd[7483]: connection from localhost [127.0.0.1] at port 34496
Jan 25 16:37:34 mail-relay spamd[7491]: info: setuid to spamfilter succeeded
Jan 25 16:37:34 mail-relay spamd[7491]: processing message <16175.1075044591@www15.gmx.net> for spamfilter:501.
Jan 25 16:37:34 mail-relay spamd[7491]: clean message (0.4/2.0) for spamfilter:501 in 0.7 seconds, 872 bytes.

Jan 25 16:37:35 mail-relay postfix/pickup[7265]: 3F4D624CDB: uid=501 from=<gennadi@gmx.net>
Jan 25 16:37:35 mail-relay postfix/cleanup[7486]: 3F4D624CDB: message-id=<16175.1075044591@www15.gmx.net>
Jan 25 16:37:35 mail-relay postfix/pipe[7487]: 93F9924C9E: to=<gennadi@gennadi.ru>, relay=filter, delay=2, status=sent (mail-relay.gennadi.ru)
Jan 25 16:37:35 mail-relay postfix/qmgr[1555]: 3F4D624CDB: from=<gennadi@gmx.net>, size=1168, nrcpt=1 (queue active)
Jan 25 16:37:35 mail-relay postfix/smtp[7496]: 3F4D624CDB: to=<gennadi@gennadi.ru>, relay=192.168.0.2[192.168.0.2], delay=0, status=sent (250 Ok: queued as BBA504A75)


?????? ?? gennadi@gmx.net, ?????? ???????? ????? spamfilter ?????????? ?? Domino-Server ??? ????? gennadi@gennadi.ru ....

10.) MySQL ? WebUserPrefs.
???? ??????????? ??????? SpamAssassin ? MySQL'?? ? ????????? ????? ??????????.
??? ????? ????? ????? SpamAssissin 2.55 - ?? ????!.
????? MySQL
????? WebUserPrefs
11.) ???????? SpamAssassin MySQL-??
??????? userpref
??????:
mail-relay:~ # mysql -h localhost -u root -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or g.
Your MySQL connection id is 159 to server version: 3.23.55-Max-log

Type 'help;' or 'h' for help. Type 'c' to clear the buffer.
mysql> create database spamassassin;
Query OK, 1 row affected (0.19 sec)
mysql> use spamassassin;
Database changed
mysql> CREATE TABLE userpref (
-> username varchar(100) NOT NULL,
-> value varchar(100) NOT NULL,
-> prefid int(11) NOT NULL auto_increment,
-> PRIMARY KEY (prefid),
-> INDEX (username)
-> ) TYPE=MyISAM;
Query OK, 0 rows affected (0.03 sec)

mysql>GRANT SELECT,INSERT,UPDATE,DELETE,CREATE,DROP,ALTER ON spamassassin.* TO spamassassin@localhost identified by 'spampassword';
Query OK, 0 rows affected (0.12 sec)
mysql>quit
mail-relay:~ #

12.) ? ?????????? /etc/mail/spamassassin ??????? ???? local.cf ? ???????? ???? ????????????? ??????:
??????:
user_scores_dsn
DBI:mysql:spamassassin:localhost
user_scores_sql_username spamassassin
user_scores_sql_password spampassword
user_scores_sql_table userpref

13.) ? ???? /etc/sysconfig/spamd ??????? ????????? ????????? ( ??? ????? ????? ??? ?????? ? MySQL'?? ):
??????:
## Path: Network/Mail/Spamassassin
## Description: Arguments for the spam d?mon
## Type: string
## Default: "-d -c -a -L"
## ServiceRestart: spamd
SPAMD_ARGS="-d -x -q "

??????????: ? RedHat ???? ???? ?????????? /etc/sysconfig/spamassassin

14.) ?????????? ?????????? ????? WebUserPrefs ? ?????????? ??? ? Root-?????????? - ?????? Web-Server'a Apache - "/srv/www/htdocs/"
? ????? /srv/www/htdocs/webuserprefs/config.php ??????? ????????? ????????? :
??????:
$prefs_source = "db";
$db_host = "localhost";
$db_username = "spamassassin";
$db_password = 'spampassword;
$db_database = "spamassassin";
$db_sauser = $PHP_AUTH_USER;

15.) ?????? ??? login spamassassin'a ????? Browser:
??????:
mail-relay: # mkdir /srv/www/passwd/
mail-relay: # mkdir /srv/www/passwd/spamassassin
mail-relay: # htpasswd -c /srv/www/passwd/spamassassin/users spamassassin
New password: spampassword
Re-type new password: spampassword
mail-relay: # echo "mail:spamassassin" > /srv/www/passwd/spamassassin/group

16.) Apache, SSL ? spamassassin-aliases
? ?????????? /etc/httpd ??????? ????? ???? httpd.conf ? ??????????????? ??? ??? ???? ???????:
??????:
<VirtualHost _default_:443>

# General setup for the virtual host
DocumentRoot "/srv/www/htdocs"
ServerName mail-relay.gennadi.ru
ServerAdmin webadmin@gennadi.ru
ErrorLog /var/log/httpd/error_log
TransferLog /var/log/httpd/access_log

# Server Certificate:
# Point SSLCertificateFile at a PEM encoded certificate. If
# the certificate is encrypted, then you will be prompted for a
# pass phrase. Note that a kill -HUP will prompt again. A test
# certificate can be generated with `make certificate' under
# built time. Keep in mind that if you've both a RSA and a DSA
# certificate you can configure both in parallel (to also allow
# the use of DSA ciphers, etc.)
SSLCertificateFile /etc/ssl/certs/server.crt
#SSLCertificateFile /etc/httpd/ssl.crt/server-dsa.crt

# Server Private Key:
# If the key is not combined with the certificate, use this
# directive to point at the key file. Keep in mind that if
# you've both a RSA and a DSA private key you can configure
# both in parallel (to also allow the use of DSA ciphers, etc.)
SSLCertificateKeyFile /etc/ssl/certs/server.key
#SSLCertificateKeyFile /etc/ssl/certs/server.key

Alias /spamassassin/ /srv/www/htdocs/spamassassin
<Directory /srv/www/htdocs/spamassassin/>
Options None
SSLRequireSSL
order deny,allow
deny from all
AuthType Basic
AuthUserFile /srv/www/passwd/spamassassin/users
AuthGroupFile /srv/www/passwd/spamassassin/group
AuthName "SpamAssassin Admin"
require group mail
Satisfy Any
</Directory>

? ?????????? /etc/ ??????? ????? ???? php.ini ??????? ????? ??????:
??????:
register_globals = Off

???????? ??:
??????:
register_globals = On


? ?????????? /etc/sysconfig ??????? ????? ???? apache ??????? ????? ??????:
??????:
HTTPD_SEC_MOD_SSL=no

???????? ??:
??????:
HTTPD_SEC_MOD_SSL=yes


? SuSE ? UnitedLinux ?????????? ????????? ????????? ???????:
??????:
mail-relay: # SuSEconfig
mail-relay: # rcapache restart

? ?????? ?????????????
??????:
mail-relay: # service httpd restart

???
??????:
mail-relay: # /etc/init.d/apache restart


https://mail-relay.gennadi.ru/webuserprefs



17.) ?????????????? ??????????? ?????? SpamAssissin 2.55

???? ?? ?????? ??????? ???? ?????? ???? ??????????? ??????? SpamAssissin ?????? ???????? ????? SPAM ? NOSPAM.
? SpamAssissin ???????????? Bayesian Filter, ??????? ???????????? ???????? sa-learn. ??????? ???????????? ???????? ?? 1000 SPAM ? NOSPAM(HAM) ????? ? ???????? SpamAssissin'? :
??????:
mail-relay: # sa-learn --spam --dir /path/to/spam/ordner
mail-relay: # sa-learn --ham --dir /path/to/nospam/ordner

??? ?? ??????? SpamAssissin ????????????? ????????? ?????? SPAM ?? NOSPAM ? ?????? ?? ? BAYES-???? ?????? (Autolearning). ????? ???? ??? SpamAssissin ?????? ?????????? ?????? ? ??????? ?? ? BAYES-???? ??????, ??? ??????? ????????????? ????????????.

?? ??? ? ??? ....

???????!
_________________
gennadi@gennadi.dyn.ee


????????? ??? ???????????????: admin (?? ??? 01, 2004 9:54 am), ????? ??????????????? 8 ???(?)
????????? ? ??????
?????????? ??????? ????????? ?????? ????????? ???????? ???? ??????
<noscript></noscript>
?????






??????????????????: ?? ??? 05, 2004 7:17 pm ????????? ?????????: ???????? ? ???????

???????????? ????????!
??????? ???, ????? ?? ???????????? ??? ?????? ??? ?????? Domino ???????? ? Relay ????????... ?? ????????? ??? ??? ????????? ?? ??????, ??????? ???????????? ?? ???????? ????????, ? ????? ????????!
????????? ??? ????? ??? ????? ?????????? ? ???? ???????
?????? ???????? - ?????? ????????? ???????????????!

??????? ??????????...
Boston, boston@fermo.ru, admin@fermo.ru
????????? ? ??????
<noscript></noscript>
admin
Newbie
Newbie


???????????????: Jun 05, 2003
?????????: 64

??????????????????: ?? ??? 26, 2004 9:19 am ????????? ?????????: ...??? ?????? Domino ???????? ? Relay ????????... ???????? ? ???????

???????????? boston!
??????:
??????? ???, ????? ?? ???????????? ??? ?????? ??? ?????? Domino ???????? ? Relay ????????...

??, ???????.
???? ? ??? ???? ?????????? Postfix, ?? ????? ?????? ?????????? SpamAssassin ?? ?????????? ????? ????????.


?????? ????????? SpamAssassin ? DrWeb

1. Postfix
a. ???? /etc/postfix//master.cf ?????? ????????? ???:
??????:

==========================================================================
# service type private unpriv chroot wakeup maxproc command + args
# (yes) (yes) (yes) (never) (100)
# ==========================================================================
smtp inet n - y - - smtpd -o content_filter=drweb:dummy
smtps inet n - n - - smtpd -o smtpd_tls_wrappermode=yes
-o smtpd_sasl_auth_enable=yes
-o content_filter=drweb:dummy

#628 inet n - n - - qmqpd
pickup fifo n - n 60 1 pickup
cleanup unix n - n - 0 cleanup
qmgr fifo n - n 300 1 qmgr
#qmgr fifo n - n 300 1 nqmgr
#tlsmgr fifo - - n 300 1 tlsmgr
rewrite unix - - n - - trivial-rewrite
bounce unix - - n - 0 bounce
defer unix - - n - 0 bounce
flush unix n - n 1000? 0 flush
proxymap unix - - n - - proxymap
smtp unix - - n - - smtp
relay unix - - n - - smtp
# -o smtp_helo_timeout=5 -o smtp_connect_timeout=5
showq unix n - n - - showq
error unix - - n - - error
local unix - n n - - local
virtual unix - n n - - virtual
#lmtp unix - - n - - lmtp
#localhost:10025 inet n - n - - smtpd -o content_filter=
# maildrop. See the Postfix MAILDROP_README file for details.
#
maildrop unix - n n - - pipe
flags=DRhu user=vmail argv=/usr/local/bin/maildrop -d ${recipient}
cyrus unix - n n - - pipe
flags=R user=cyrus argv=/usr/lib/cyrus/bin/deliver -e -m ${extension} ${user}
uucp unix - n n - - pipe
flags=Fqhu user=uucp argv=uux -r -n -z -a$sender - $nexthop!rmail ($recipient)
ifmail unix - n n - - pipe
flags=F user=ftn argv=/usr/lib/ifmail/ifmail -r $nexthop ($recipient)
bsmtp unix - n n - - pipe
flags=Fq. user=foo argv=/usr/local/sbin/bsmtp -f $sender $nexthop $recipient
vscan unix - n n - 10 pipe
user=vscan argv=/usr/sbin/amavis ${sender} ${recipient}
procmail unix - n n - - pipe
flags=R user=nobody argv=/usr/bin/procmail -t -m /etc/procmailrc ${sender} ${recipient}
drweb unix - n n - 5 pipe
flags=R user=drweb argv=/opt/drweb/filters.sh -f ${sender} -- ${recipient}


?. ???? /etc/postfix/main.cf ???????? ???:
??????:
mail_spool_directory = /var/mail
canonical_maps = hash:/etc/postfix/canonical
virtual_maps = hash:/etc/postfix/virtual
relocated_maps = hash:/etc/postfix/relocated
transport_maps = hash:/etc/postfix/transport
sender_canonical_maps = hash:/etc/postfix/sender_canonical
masquerade_exceptions = root
masquerade_classes = envelope_sender, header_sender, header_recipient
mydomain = gennadi.ru
myhostname = mail-server.gennadi.ru
program_directory = /usr/lib/postfix
inet_interfaces = all
masquerade_domains = gennadi.ru
mydestination = $myhostname, localhost.$mydomain
defer_transports =
disable_dns_lookups = no
relayhost =
local_recipient_maps =

content_filter =
mailbox_command =
mailbox_transport = cyrus
fallback_transport = cyrus
smtpd_sender_restrictions = hash:/etc/postfix/access
smtpd_relay_reject = no
smtpd_client_restrictions =
smtp_always_send_ehlo = yes
smtpd_helo_required = no
smtpd_helo_restrictions =
strict_rfc821_envelopes = no
smtpd_recipient_restrictions = permit_mynetworks,permit_mx_backup,permit_sasl_authenticated,check_relay_domains
broken_sasl_auth_clients = yes
smtp_sasl_auth_enable = yes
smtp_sasl_security_options = noanonymous
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtpd_sasl_auth_enable = yes
smtpd_use_tls = yes
smtpd_tls_key_file = /etc/ssl/certs/cert.pem
smtpd_tls_cert_file = /etc/ssl/certs/cert.pem
smtpd_tls_CAfile = /etc/ssl/certs/cert.pem
smtpd_tls_loglevel = 3
smtpd_tls_received_header = yes
smtpd_tls_session_cache_timeout = 3600s
tls_random_source = dev:/dev/urandom

alias_maps = hash:/etc/aliases
mailbox_size_limit = 51200000
message_size_limit = 10240000

2. ????????? DrWeb

????? ???????? ??? ??????:
ftp://ftp.drweb.ru/pub/unix/generic/drweb-4.31.4-glibc.2.3.i586.rpm
ftp://ftp.drweb.ru/pub/unix/drweb-postfix-4.31-linux.tar.gz

????? ? ????????? Evaluation key ??? ???????....
??????:
mail-server:~ # rpm -ihv drweb-4.31.4-glibc.2.3.i386.rpm

? ?????? ????????????: /opt/drweb/doc/readme.scanner.rus

??? ?????? ? ????.....
??????:
mail-server:~ # /etc/init.d/drwebd start
Starting Dr. Web daemon...Dr.Web (R) daemon for Linux, version 4.31.3 (March 9, 2004)
Copyright (c) Igor Daniloff, 1992-2003
Daniloff's Labs and DialogueScience
http://www.drweb.ru,> support@drweb.ru: +7 (812) 387-64-08
http://www.dials.ru,> antivir@dials.ru: +7 (095) 137-01-50
Key file: /opt/drweb/drwebd.key
Registration info:
0102000001
Evaluation key ID Anti-virus Lab St.-Petersburg
This is an EVALUATION version with limited functionality!
To get your registration key, call regional dealer.
Engine version: 4.31b
Loading /var/drweb/bases/drwtoday.vdb - Ok, virus records: 205
Loading /var/drweb/bases/drw43114.vdb - Ok, virus records: 285
Loading /var/drweb/bases/drw43113.vdb - Ok, virus records: 358
...................................
Loading /var/drweb/bases/drw43101.vdb - Ok, virus records: 227
Loading /var/drweb/bases/drw43102.vdb - Ok, virus records: 337
Loading /var/drweb/bases/drwebase.vdb - Ok, virus records: 45256
Total virus records: 49625
Daemon is installed, active interfaces: 127.0.0.1:3000
mail-server:~ #

????? ???????????? ???? ?????? ??????????? ????????????? - ??????? ?????? ? crontab:
??????:
5 */3 * * * root /opt/drweb/update/update.pl

?????? ????????????? ????? drweb-postfix-4.31-linux.tar.gz ? ????? ??????????, ????????- /usr/src ? ???????? ????? ? ?????????? /etc ? /opt.
??????:
mail-server:~ # cd /usr/src
mail-server:~ # tar xvfz drweb-postfix-4.31-linux.tar.gz
mail-server:~ # cd drweb-postfix
mail-server:~ # cp -a etc/* /etc
mail-server:~ # cp -a opt/* /opt
mail-server:~ # cp -a opt/drweb/doc/postfix/example.with_spamc/filters.sh /opt/drweb/

3. SpamAssassin

????????????? SpamAssassin ??? ??? ??????? ? ??????? ??????, ?? ??????????? ??????? 5.) ? 6.), ?????? ??? ?????? ?????????? ??????? filters.sh ????? ?? ???? user "drweb"

??? ?????????? ?????? SpamAssassin ????? ?????? ?????????? .spamassassin , ? ??????? ?????????? ???????? ???? user_prefs
??????:
mail-server:~ # cd /opt/drweb
mail-server:~ # mkdir .spamassassin
mail-server:~ # chown drweb:drweb .spamassassin
mail-server:~ # cd .spamassassin
mail-server:~ # touch user_prefs

???? user_prefs :
??????:
# Add your own customisations to this file. See 'man Mail::SpamAssassin::Conf'
# for details of what can be tweaked.
# rewrite the Subject: line with ****SPAM**** .* if set to 1 (default=1)
#rewrite_subject 0
# make the report in the header as opposed to in the body (default=0)
#report_header 1
# report briefly, recommended for report_header==1 (default=0)
#use_terse_report 1
# make conversion from mime to text/plain if set to yes (default=1)
#######################################################################################
defang_mime 0
required_hits 5
rewrite_header 1
report_safe 1
use_bayes 1
auto_learn 1
use_terse_report 1
always_add_headers 1
fold_headers 1
spam_level_stars 1
spam_level_char *
rewrite_subject 1
subject_tag *****SPAM*****
ok_languages ru
ok_locales en
use_razor1 1
use_razor2 1
use_pyzor 1
use_dcc 1
skip_rbl_checks 0
body VIAGRA /viagra/i
body PENIS /penis/i
score VIAGRA 2
score PENIS 2
blacklist_from @vmware.com
score __HAS_MSMAIL_PRI -2
score __OE_MUA -2
score __MIME_VERSION -2
score __HAS_X_MAILER -2
score __HAS_OUTLOOK_IN_MAILER -2
score __CTYPE_MULTIPART_ALT -2
score __NEXTPART_ALL -2
score __ANY_OUTLOOK_MUA -2
score __CTYPE_HAS_BOUNDARY -2
score __NEXTPART_NORMAL -2
score __CT -2
score __HAS_MIMEOLE -2
score __HAS_X_PRIORITY -2


?????
??????:
mail-server:~ # postfix reload
mail-server:~ # /etc/init.d/postfix restart
mail-server:~ # /etc/init.d/spamd start
mail-server:~ # /etc/init.d/drwebd start


T???
?????? ????? ??????? ?????? ?? ????????? ?????????? ?????.
? ???? ??????? ??? gennadi@gmx.net ???????? ?????? ?? ????? gennadi@gennadi.ru.? ??????? ????.
??????:
mail-relay:~ # tail -fn 100 /var/log/mail
May 9 11:38:06 mail-server postfix/smtpd[31759]: starting TLS engine
May 9 11:38:06 mail-server postfix/smtpd[31759]: connect from unknown[213.165.64.20]
May 9 11:38:06 mail-server postfix/smtpd[31759]: E0AC1B10: client=unknown[213.165.64.20]
May 9 11:38:07 mail-server postfix/cleanup[31760]: E0AC1B10: message-id=<7318.1084094939@www48.gmx.net>
May 9 11:38:07 mail-server postfix/qmgr[957]: E0AC1B10: from=<gennadi@gmx.net>, size=1009, nrcpt=1 (queue active)
May 9 11:38:07 mail-server spamd[841]: connection from localhost [127.0.0.1] at port 33117
May 9 11:38:07 mail-server postfix/smtpd[31759]: disconnect from unknown[213.165.64.20]
May 9 11:38:07 mail-server spamd[31766]: info: setuid to drweb succeeded
May 9 11:38:07 mail-server spamd[31766]: processing message <7318.1084094939@www48.gmx.net> for drweb:508.
May 9 11:38:08 mail-server spamd[31766]: clean message (0.7/5.0) for drweb:508 in 1.2 seconds, 1013 bytes.

May 9 11:38:09 mail-server drweb-postfix: dwlib[31765]: scan: the message(drweb.tmp.0be7Ys) sent by gennadi@gmx.net to gennadi@gennadi.ru is passed

May 9 11:38:09 mail-server postfix/pickup[31573]: 49D24B15: uid=508 from=<gennadi@gmx.net>
May 9 11:38:09 mail-server postfix/cleanup[31760]: 49D24B15: message-id=<7318.1084094939@www48.gmx.net>
May 9 11:38:09 mail-server postfix/pipe[31761]: E0AC1B10: to=<gennadi@gennadi.rue>, relay=drweb, delay=3, status=sent (dummy)
May 9 11:38:09 mail-server postfix/qmgr[957]: 49D24B15: from=<gennadi@gmx.net>, size=1293, nrcpt=1 (queue active)
May 9 11:38:09 mail-server postfix/pipe[31771]: 49D24B15: to=<gennadi@gennadi.ru>, relay=cyrus, delay=0, status=sent (gennadi.ru)


?????? ?? gennadi@gmx.net, ?????? ???????? ?? Spam ????? spamfilter ? ?? ????? ????? drweb - ?????????? ????? gennadi@gennadi.ru

?????? ??? ???? ?????? ? ???????.
??? ?????? ???????? test-virus ?????? ??????????:
??????:
X5O!P%@AP[4PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H*
? ??????? ????.
??????:
mail-relay:~ # tail -fn 100 /var/log/mail
May 9 11:35:05 mail-server postfix/smtpd[31734]: starting TLS engine
May 9 11:35:05 mail-server postfix/smtpd[31734]: connect from unknown[213.165.64.20]
May 9 11:35:05 mail-server postfix/smtpd[31734]: 6FE4B5DB: client=unknown[213.165.64.20]
May 9 11:35:05 mail-server postfix/cleanup[31735]: 6FE4B5DB: message-id=<opr7p65d1x9wdffd@linux.gennadi.ru>
May 9 11:35:05 mail-server postfix/qmgr[957]: 6FE4B5DB: from=<gennadi@gmx.net>, size=1008, nrcpt=1 (queue active)
May 9 11:35:05 mail-server spamd[841]: connection from localhost [127.0.0.1] at port 33114
May 9 11:35:05 mail-server postfix/smtpd[31734]: disconnect from unknown[213.165.64.20]
May 9 11:35:05 mail-server spamd[31742]: info: setuid to drweb succeeded
May 9 11:35:05 mail-server spamd[31742]: processing message <opr7p65d1x9wdffd@linux.gennadi.ru> for drweb:508.
May 9 11:35:08 mail-server spamd[31742]: clean message (1.0/5.0) for drweb:508 in 2.5 seconds, 1016 bytes.

May 9 11:35:08 mail-server drweb-postfix: dwlib[31741]: scan: the message(drweb.tmp.l3MWmE) sent by gennadi@gmx.net to gennadi@gennadi.ru has been stored in archive /var/drweb/infected/drweb.quarantine.jFuKh2

May 9 11:35:09 mail-server postfix/pickup[31573]: 2B12EB12: uid=508 from=<DrWEB-DAEMON>
May 9 11:35:09 mail-server postfix/cleanup[31735]: 2B12EB12: message-id=<20040509093509.2B12EB12@gennadi.ru>
May 9 11:35:09 mail-server postfix/qmgr[957]: 2B12EB12: from=<DrWEB-DAEMON@gennadi.ru>, size=3518, nrcpt=1 (queue active)
May 9 11:35:09 mail-server postfix/pickup[31573]: 6193FB13: uid=508 from=<DrWEB-DAEMON>
May 9 11:35:09 mail-server postfix/cleanup[31735]: 6193FB13: message-id=<20040509093509.6193FB13@gennadi.ru>
May 9 11:35:09 mail-server postfix/qmgr[957]: 6193FB13: from=<DrWEB-DAEMON@gennadi.ru>, size=3790, nrcpt=1 (queue active)
May 9 11:35:09 mail-server postfix/pickup[31573]: B4E6EB14: uid=508 from=<DrWEB-DAEMON>

May 9 11:35:09 mail-server postfix/cleanup[31735]: B4E6EB14: message-id=<20040509093509.B4E6EB14@gennadi.ru>
May 9 11:35:09 mail-server drweb-postfix: dwlib[31741]: scan: the message(drweb.tmp.l3MWmE) sent by gennadi@gmx.net to gennadi@gennadi.ru infected with EICAR Test File (NOT a Virus!)
May 9 11:35:09 mail-server postfix/pipe[31737]: 6FE4B5DB: to=<gennadi@gennadi.ru>, relay=drweb, delay=4, status=sent (dummy)
May 9 11:35:09 mail-server postfix/qmgr[957]: B4E6EB14: from=<DrWEB-DAEMON@gennadi.ru>, size=4056, nrcpt=1 (queue active)
May 9 11:35:10 mail-server postfix/pipe[31752]: 2B12EB12: to=<gennadi@gennadi.ru>, relay=cyrus, delay=1, status=sent (gennadi.ru)
May 9 11:35:10 mail-server postfix/pipe[31753]: 6193FB13: to=<gennadi@gennadi.ru>, relay=cyrus, delay=1, status=sent (gennadi.ru)

May 9 11:35:11 mail-server postfix/smtp[31757]: B4E6EB14: to=<gennadi@gmx.net>, relay=mx0.gmx.net[213.165.64.100], delay=2, status=sent (250 2.6.0 {mx034} Message accepted)


?????? ?? gennadi@gmx.net, ?????? ???????? ?? Spam ????? spamfilter?????????? drweb'?, ? drweb ?????????, ??? ??? ???????? ????? ? ??????? ??? ? ???????? (/var/drweb/infected), ? DrWEB-DAEMON ???????? ?? ???? ?????? gennadi@gennadi.ru ? gennadi@gennadi.net
??????:
????????? ??????????? gennadi@gmx.net !

?????????, ???????????? ? ?????? ?????? (???????? ???????
? ??????? ??????????) ?? ??????(??) gennadi@gennadi.ru
???????????? ? ?? ???? ??????????.

--- Dr.Web report ---
??????(?) ?????????(?) ?????(?):
Known virus(es):
EICAR Test File (NOT a Virus!)

???????????????? ????? Dr.Web:
127.0.0.1 [31743] drweb.tmp.l3MWmE - archive MAIL
127.0.0.1 [31743] drweb.tmp.l3MWmE/[text:plain] infected with EICAR Test File (NOT a Virus!)

?????????? ???????????? Dr.Web:
Evaluation key used !
Known viruses : 1

--- Dr.Web report ---

???? ????????? ????????? ? ????????? ??? ??????:
drweb.quarantine.jFuKh2

????? ???????? ??? ?????????, ?????????? ? ??????????????
?? ?????? <gennadi@gennadi.ru>, ?????? ???, ??? ???????
???? ????????? ????????? ? ?????????.

---
???????????? ?????? ???????? ????????
Dr.Web(R) Daemon for Unix (?????????? ? Daniloff's Labs)
 http://www.drweb.ru, http://www.DialogNauka.ru)>
Dear User,

the message with following attributes has not been delivered,
because contains an infected object.

Sender = gennadi@gmx.net (may be forged)
Recipients = gennadi@gennadi.ru

Antivirus filter report:
--- Dr.Web report ---
Following virus(es) has been found:
Known virus(es):
EICAR Test File (NOT a Virus!)

Dr.Web detailed report:
127.0.0.1 [31743] drweb.tmp.l3MWmE - archive MAIL
127.0.0.1 [31743] drweb.tmp.l3MWmE/[text:plain] infected with EICAR Test File (NOT a Virus!)

Dr.Web scanning statistic:
Evaluation key used !
Known viruses : 1

--- Dr.Web report ---

The original message was stored in archive record named:
drweb.quarantine.jFuKh2
In order to receive the original message, please send request to
<gennadi@gennadi.ru>, referring to the archive record
name given above.

---
Antivirus service provided by Dr.Web(R) Daemon for Unix
 http://www.drweb.ru, http://www.dials.ru/english)>


???????!
_________________
gennadi@gennadi.dyn.ee  http://gennadi.dyn.ee/modules.php?name=Forums&file=viewtopic&t=11





 agathis.newmail.ru. sendmail-sasl ? cyrus-imapd
 ?????????????? SMTP: ??????? sendmail + SASL
 ???????????????? Postfix
 ????????? ??????? ???????????? Postfix + ClamAV + procmail + Spamassassin


Внимание! Читая пророчества на этом сайте помните что достоверность трудно проверить и все может во времени изменяться
"О дне же том, или часе, никто не знает, ни Ангелы небесные, ни Сын, но только Отец (Мк. 13, 32)"