QQ登录

只需一步,快速开始

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 1022|回复: 1

我用sendmail+cyrus-imapd并用sasl认证

[复制链接]
发表于 2005-11-21 20:55:14 | 显示全部楼层 |阅读模式
我用sendmail+cyrus-imapd并用sasl认证发现能向外网发信不能收信,配置和现象如下:
1>>>>  sendmail的sendmail.mc配置文件我开了全域接听!
dnl DAEMON_OPTIONS(`Port=smtp,Addr=ailinux.3322.org, Name=MTA')dnl
LOCAL_DOMAIN(`localhost.localdomain')dnl
  其它的都为默认配置!
2>>>>  /etc/imapd.conf配置为:
configdirectory: /var/lib/imap
partition-default: /var/spool/imap
admins: cyrus
sievedir: /var/lib/imap/sieve
sendmail: /usr/sbin/sendmail
sasl_pwcheck_method: saslauthd
sasl_mech_list: DIGEST-MD5
tls_cert_file: /usr/share/ssl/certs/cyrus-imapd.pem
tls_key_file: /usr/share/ssl/certs/cyrus-imapd.pem
tls_ca_file: /usr/share/ssl/certs/ca-bundle.crt
我用了DIGEST-MD5认证!
[root@ailinux ~]# testsaslauthd -u cyrus -p password  //认证通过!
0: OK "Success."
[root@ailinux ~]#  
[root@ailinux ~]# cyradm -u cyrus ailinux.3322.org   //登入成功!
Password:
ailinux.3322.org> lm
INBOX (HasChildren)           user.ni (HasNoChildren)
INBOX.Sent (HasNoChildren)    user.test (HasNoChildren)
INBOX.Trash (HasNoChildren)   user.wo (HasNoChildren)
hongxiu (HasNoChildren)       user.xiumin (HasNoChildren)
user.hongxiu (HasNoChildren)  user.xumin (HasNoChildren)
ailinux.3322.org> quit
[root@ailinux ~]#
[root@ailinux ~]# imtest -m login -a cyrus ailinux.3322.org  // 用户测试也能成功
S: * OK ailinux.3322.org Cyrus IMAP4 v2.2.10-Invoca-RPM-2.2.10-1.RHEL4.1 server ready
C: C01 CAPABILITY
S: * CAPABILITY IMAP4 IMAP4rev1 ACL QUOTA LITERAL+ MAILBOX-REFERRALS NAMESPACE UIDPLUS ID NO_ATOMIC_RENAME UNSELECT CHILDREN MULTIAPPEND BINARY SORT THREAD=ORDEREDSUBJECT THREAD=REFERENCES ANNOTATEMORE IDLE STARTTLS AUTH=DIGEST-MD5 SASL-IR LISTEXT LIST-SUBSCRIBED X-NETSCAPE
S: C01 OK Completed
Please enter your password:
C: L01 LOGIN cyrus {6}
S: + go ahead
C: <omitted>
S: L01 OK User logged in
Authenticated.
Security strength factor: 0

当我用cyrus添加了个邮件用户和INBOX,也生成sasldb,sasldb2库后,认证失败了!
[root@ailinux ~]# imtest -m login -a newname ailinux.3322.org
S: * OK ailinux.3322.org Cyrus IMAP4 v2.2.10-Invoca-RPM-2.2.10-1.RHEL4.1 server ready
C: C01 CAPABILITY
S: * CAPABILITY IMAP4 IMAP4rev1 ACL QUOTA LITERAL+ MAILBOX-REFERRALS NAMESPACE UIDPLUS ID NO_ATOMIC_RENAME UNSELECT CHILDREN MULTIAPPEND BINARY SORT THREAD=ORDEREDSUBJECT THREAD=REFERENCES ANNOTATEMORE IDLE STARTTLS AUTH=DIGEST-MD5 SASL-IR LISTEXT LIST-SUBSCRIBED X-NETSCAPE
S: C01 OK Completed
Please enter your password:
C: L01 LOGIN hongxiu {6}
S: + go ahead
C: <omitted>
S: L01 NO Login failed: authentication failure
Authentication failed. generic failure
Security strength factor: 0
[root@ailinux ~]# testsaslauthd -u honhxiu -p passwd
0: NO "authentication failed"

在用kmail收信日志如下!
Nov 19 22:08:11 ailinux imap[4564]: accepted connection
Nov 19 22:08:11 ailinux master[4582]: about to exec /usr/lib/cyrus-imapd/imapd
Nov 19 22:08:11 ailinux imap[4564]: login: [221.200.213.251] cyrus plaintext User logged in
Nov 19 22:08:11 ailinux imap[4582]: executed
Nov 19 22:08:11 ailinux imap[4564]: skiplist: recovered /var/lib/imap/user/c/cyrus.seen (1 record, 424 bytes) in 0 seconds
Nov 19 22:08:11 ailinux imap[4564]: seen_db: user cyrus opened /var/lib/imap/user/c/cyrus.seen
Nov 19 22:08:11 ailinux imap[4564]: open: user cyrus opened INBOX
好象没什么问题,可是,外网发进来的信就是收不着!请大侠帮助或给点提示或有关cyrus-sasl认证配置的帮助!
谢谢了先!!
 楼主| 发表于 2005-11-21 20:56:47 | 显示全部楼层
还未解决!
请人伸出援手
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

GMT+8, 2024-11-3 02:17 , Processed in 0.059898 second(s), 16 queries .

© 2021 Powered by Discuz! X3.5.

快速回复 返回顶部 返回列表