FREEBSD上的使用POSTFIX的反垃圾反病毒邮件系统[6]

[入库:2005年9月21日] [更新:2007年3月24日]

本文简介:

# be used to do an UPDATE operation on database. In other words, it is
# used, when changing password.
#
# There are four variables, which you can use. Substitution will be made
# for them, so you can put entered username (local part) and domain name
# in the right place of your query. There variables are:
# $(local_part) , $(domain) , $(newpass) , $(newpass_crypt)
#
# If a $(domain) is empty (not given by the remote user) the default domain
# name is used in its place.
# $(newpass) contains plain password
# $(newpass_crypt) contains its crypted form
#
# MYSQL_CHPASS_CLAUSE UPDATE popbox \
#&nbsSTnsp;clarpw=''$(newpass)'''', \
#bppssword_hash''''(epass_crypt)'''' \
# WR&bp;local_art='''(local_part)'''' \
# N&bp;doain_nae'''$(domain)''''
#
编辑修改/usr/lib/courier-imap/etc/authdaemonrc 
version="authdaemond.mysql"
3)设置自启动
hawk# cd /usr/local/etc/rc.d
hawk# ln -s /usr/lib/courier-imap/libexec/imapd.rc imapd.sh
hawk# ln -s /usr/lib/courier-imap/libexec/pop3d.rc pop3d.sh
hawk# chmod 755 imapd.sh
hawk# chmod 755 pop3d.sh

现在开始测试:
1)设置用户:
hawk# mysql
mysql> use mail;
在数据库里你可以看到 
mysql> show tables;
+----------------+
| Tables_in_mail |
+----------------+
| aliases        |
| transport      |
| virtual_users  |
+----------------+ 
mysql> desc aliases;
+-------+--------------+------+-----+---------+-------+
| Field | Type         | Null | Key | Default | Extra |
+-------+--------------+------+-----+---------+-------+
| alias | varchar(255) |      | PRI |         |       |
| rcpt  | varchar(255) | YES  |     | NULL    |       |
+-------+--------------+------+-----+---------+-------+ 
mysql> insert lases values('ptase@h9.co'''','''chawk@the9.com'''');
mysql> insert lae values(''''satrfebd.net''''''''nak@freebsd.net'''');
mysql> select * from aliases;
+--------------------------+--------------------+ 
| alias                    | rcpt               | 
+--------------------------+--------------------+ 
| postmaster@the9.com | cnhawk@the9.com | 
| postmaster@freebsd.net   | cnhawk@freebse.net   | 
+--------------------------+--------------------+
mysql> desc transport;
+-----------+-----------+------+-----+---------+-------+
| Field     | Type      | Null | Key | Default | Extra |
+-----------+-----------+------+-----+---------+-------+
| domain    | char(128) |      | PRI |         |       |
| transport | char(128) |      |     |         |       |
+-----------+-----------+------+-----+---------+-------+
mysql> insert tnprt&nspvaus'''e.com''','''virtual:'''');
mysql> insert tnprt vaue(''fes.net''','''virtual:'''');
mysql> select * from transport;
+---------------+-----------+ 
| domain        | transport | 
+---------------+-----------+ 
| nankai.edu.cn | virtual:  | 

本文关键:FREEBSD上的使用POSTFIX的反垃圾反病毒邮件系统
  相关方案
Google
 

本站最佳浏览方式为 分辨率 1024x768 IE 6.0(或更高版本的 IE浏览器)

go top