什么是sasl errdetail认证

pam与sasl_百度文库
两大类热门资源免费畅读
续费一年阅读会员,立省24元!
评价文档:
15页免费4页免费3页免费2页免费20页免费3页免费6页免费10页免费4页免费3页免费
喜欢此文档的还喜欢1页免费18页1下载券2页免费4页免费59页免费
pam与sasl|简​单​介​绍​了​C​e​n​t​O​S​中​的​认​证​机​制​和​测​试​方​法​,​主​要​涉​及​了​P​A​M​和​S​A​S​L​的​配​置​和​联​合​使​用​方​法​。​最​后​简​单​介​绍​了​使​用​M​Y​S​Q​L​保​存​P​A​M​认​证​数​据​的​方​法​。
把文档贴到Blog、BBS或个人站等:
普通尺寸(450*500pix)
较大尺寸(630*500pix)
你可能喜欢postfix无法用户身份验证_linux吧_百度贴吧
&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&签到排名:今日本吧第个签到,本吧因你更精彩,明天继续来努力!
本吧签到人数:0成为超级会员,使用一键签到本月漏签0次!成为超级会员,赠送8张补签卡连续签到:天&&累计签到:天超级会员单次开通12个月以上,赠送连续签到卡3张
关注:84,119贴子:
postfix无法用户身份验证收藏
我的系统是centos6.3,安装了cyrus-sasl与postfix,发现25端口已经打开了,用户身份验证无法通过。新建一个用户sam,密码是123456,用/usr/local/sbin/testsaslauthd -u sam -p '123456' -s smtp成功,再用perl -MMIME::Base64 -e 'print encode_base64("sam");' 得到c2Ft;用perl -MMIME::Base64 -e 'print encode_base64("123456");' 得到MTIzNDU2。然后telnet localhost 25,输入auth login,用以上得到的加密用户密码验证,结果提示:503 5.5.1 Error: authentication not enabled,有的提示:authentication failed: no mechanism available,怎么回事?
如下图:sasl与postfix用rpm包安装,上述过程会提示:authentication not enabled的错误;如果这两个用源代码包安装,会出现:authentication failed: no mechanism available的提示。
没打开认证。。/mail.sh一个bash自己下回去研究一下
当然不是 下载那个看看源码你就知道怎么操作了
谢谢5楼的,我原因找到了,我cyrus-sasl是用rpm包安装的,我只安装了cyrus-sasl与cyrus-sasl-lib,没有安装cyrus-sasl-plain与cyrus-sasl-devel,我把没安装的安装上了。然后在/etc/postfix/main.cf上加入如下:smtpd_sasl_auth_enable = yessmtpd_recipient_restrictions = permit_mynetworks,permit_sasl_authenticated,reject_unauth_destination,reject_non_fqdn_recipientsmtpd_sasl_application_name = smtpd
重启sasl与postfix服务后,再次执行telnet localhost 25,输入auth login,接着输入加密后用户名与密码后,终于提示:235 2.7.0 Authentication successful,smtp认证成功。
outlook那边可以把信发出去了。
登录百度帐号我的游戏推荐游戏
后查看最近玩过的游戏
为兴趣而生,贴吧更懂你。或用机制DIGEST-MD5 asmack在Android登录异常SASL认证失败
我米尝试与XMPP服务器连接,但即时通讯越来越异常
登录异常SASL认证失败DIGEST-MD5
这段代码,可以任意一个代码
if (xmppConnection == null) {
ConnectionConfiguration config = new ConnectionConfiguration(
SERVER_HOST, SERVER_PORT, SERVICE_NAME);
xmppConnection = new XMPPConnection(config);
System.out.println("xmppConnection"+xmppConnection);
if (!xmppConnection.isConnected()) {
xmppConnection.connect();
System.out.println("Connecting");
System.out.println("facebook id get xmpp "+username);
if (!xmppConnection.isAuthenticated()) {
xmppConnection.login(username, "123");
System.out.println("User is authenticated ");
Presence presence = new Presence(Presence.Type.available);
xmppConnection.sendPacket(presence);
} catch (Exception e) {
System.out.println("Login exception "+e);
e.printStackTrace();
本文地址 :CodeGo.net/568512/
-------------------------------------------------------------------------------------------------------------------------
1. 在该配置中的Openfire它是
这也采用了XMPP域进行验证,不仅和密码。这就是为什么验证失败。
意味着你和密码必须是这样的:
abc111@(无论你的域名
密码:abcabc111
对于更详细的检查这次谈话。
我在下面在我这里,它的做工精细代码..
ConnectionConfiguration connConfig = new ConnectionConfiguration("HOST_IP", Integer.parseInt("PORT_NO"));
XMPPConnection connection = new XMPPConnection(connConfig);
connection.connect();
connection.login("USER_NAME", "PASSWORD);
// Set the status to available
Presence presence = new Presence(Presence.Type.available);
connection.sendPacket(presence);
xmppClient.setConnection(connection);
catch (XMPPException ex)
Log.w("XMPPClient", "[SettingsDialog] Failed to log in as " + username);
Log.w("XMPPClient", ex.toString());
xmppClient.setConnection(null);
catch (XMPPException ex)
Log.w("XMPPClient", "[SettingsDialog] Failed to connect to " + connection.getHost());
Log.w("XMPPClient", ex.toString());
xmppClient.setConnection(null);
而我也加入了smack.jar文件。
请检查下面的帖子,我觉得它可能会帮助你。
并获得在登录这个错误。查看以下链接获取更多信息..
本文标题 :用机制DIGEST-MD5 asmack在Android登录异常SASL认证失败
本文地址 :CodeGo.net/568512/
Copyright (C) 2014 CodeGo.net 沪ICP备号 联系电邮: (#=@)postfix/smtpd:SASL认证认败,请问是什么原因,多谢了,下面是LOG: - Postfix在中国 -
ExtMail 邮件服务器 邮件服务器,邮件系统,企业邮局系统,WebMail,linux邮件服务器,免费邮件服务器,邮件系统下载,PushMail,手机邮箱,Email Server - Powered by Discuz!
postfix/smtpd:SASL认证认败,请问是什么原因,多谢了,下面是LOG:
&&maillog:
Apr&&7 11:12:48 mail postfix/smtpd[4215]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Apr&&7 11:12:48 mail postfix/smtpd[4215]: connect from localhost.localdomain[127.0.0.1]
Apr&&7 11:13:12 mail postfix/smtpd[4215]: warning: localhost.localdomain[127.0.0.1]: SASL login authentication failed
/usr/local/lib/sasl2/smtpd.conf:
pwcheck_method:authdaemond
log_level:3
srp_mda:md5
password_format:crypt
mech_listLAIN LOGIN
authdaemond_path: /usr/local/var/spool/authdaemon/socket
/etc/postfix/main.cf:
#=====================BASE=========================
myhostname = mail.
mydomain =
myorigin = $myhostname
mydestination = $myhostname localhost localhost.$mydomain
mynetworks = 127.0.0.0/8
inet_interfaces = all
#=====================Vritual Mailbox settings=========================
virtual_mailbox_base = /var/mailbox
virtual_mailbox_maps = mysql:/etc/postfix/mysql/mysql_virtual_mailbox_maps.cf
virtual_mailbox_domains = mysql:/etc/postfix/mysql/mysql_virtual_domains_maps.cf
virtual_alias_domains = mysql:/etc/postfix/mysql/mysql_alias_domains_maps.cf
virtual_alias_maps = mysql:/etc/postfix/mysql/mysql_virtual_alias_maps.cf
virtual_uid_maps = static:1001
virtual_gid_maps = static:1001
virtual_transport = maildrop
maildrop_destination_recipient_limit = 1
maildrop_destination_concurrency_limit = 1
relay_domains = mysql:/etc/postfix/mysql/mysql_relay_domains_maps.cf
#====================QUOTA========================
message_size_limit =
virtual_mailbox_limit =
virtual_create_maildirsize = yes
virtual_mailbox_extended = yes
virtual_mailbox_limit_maps = mysql:/etc/postfix/mysql/mysql_virtual_mailbox_limit_maps.cf
virtual_mailbox_limit_override = yes
virtual_maildir_limit_message = Sorry, the user's maildir has overdrawn his diskspace quota, please try again later.
virtual_overquota_bounce = yes
#====================SASL========================
broken_sasl_auth_clients = yes
smtpd_recipient_restrictions =
&&permit_mynetworks,
&&permit_sasl_authenticated,
&&reject_invalid_hostname,
&&reject_non_fqdn_hostname,
&&reject_unknown_sender_domain,
&&reject_non_fqdn_sender,
&&reject_non_fqdn_recipient,
&&reject_unknown_recipient_domain,
&&reject_unauth_pipelining,
&&reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_security_options = noanonymous
smtpd_sasl_application_name = smtpd
smtpd_banner=$myhostname ESMTP &Version not Available&
/usr/lib/sasl2/smtpd.conf:
pwcheck_method: authdaemond
log_level: 3
srp_mda: md5
password_format: crypt
mech_list: PLAIN LOGIN
authdaemond_path: /usr/local/var/spool/authdaemon/socket
sql_engine: mysql
sql_hostnames: localhost
sql_user: postfix
sql_passwd: postfix
sql_database: postfix
sql_select: SELECT password FROM mailbox WHERE username='%u@%r' and domain='%r' and active='1'
我的系统及包的版本是:REDHAT9.0+mysql 5.0.15+apache 2.0.55+php 4.4.1+cyrus-sasl 2.1.21+postfix 2.2.5+postfixadmin 2.1.0+Courier-authlib 0.57+Courier-imap 4.0.6+Courier-maildrop 2.0.1
/etc/postfix/mysql/mysql_alias_domains_maps.cf
user = postfix
password = postfix
hosts = localhost
dbname = postfix
table = alias
select_field = goto
where_field = address
query = SELECT goto FROM alias WHERE address='%s'
/etc/postfix/mysql/mysql_relay_domains_maps.cf
user = postfix
password = postfix
hosts = localhost
dbname = postfix
query = SELECT domain FROM domain WHERE domain='%s' and backupmx = '1'
/etc/postfix/mysql/mysql_virtual_alias_maps.cf
user = postfix
password = postfix
hosts = localhost
dbname = postfix
query = SELECT goto FROM alias WHERE address='%s' AND active = 1
/etc/postfix/mysql/mysql_virtual_domains_maps.cf
user = postfix
password = postfix
hosts = localhost
dbname = postfix
query = SELECT domain FROM domain WHERE domain='%s'
#optional query to use when relaying for backup MX
#query = SELECT domain FROM domain WHERE domain='%s' and backupmx = '0' and active = '1'
/etc/postfix/mysql/mysql_virtual_mailbox_limit_maps.cf
user = postfix
password = postfix
hosts = localhost
dbname = postfix
query = SELECT quota FROM mailbox WHERE username='%s'
/etc/postfix/mysql/mysql_virtual_mailbox_maps.cf
user = postfix
password = postfix
hosts = localhost
dbname = postfix
query = SELECT maildir FROM mailbox WHERE username='%s' AND active = 1
authdaemond的配置及相关配置呢?
authdaemonrc?
/usr/local/etc/authlib/authdaemonrc:
authmodulelist=&authmysql&
/usr/local/etc/authlib/authmysqlrc
MYSQL_SERVER& &localhost
MYSQL_SOCKET& &/tmp/mysql.sock
MYSQL_DATABASE&&postfix
MYSQL_USERNAME&&postfix
MYSQL_PASSWORD&&postfix
MYSQL_USER_TABLE& && &mailbox
MYSQL_LOGIN_FIELD& &&&username
MYSQL_CRYPT_PWFIELD& & password
MYSQL_UID_FIELD '1001'
MYSQL_GID_FIELD '1001'
MYSQL_HOME_FIELD& && &'/var/mailbox/'
MYSQL_MAILDIR_FIELD& & maildir
MYSQL_NAME_FIELD& && &name
MYSQL_QUOTA_FIELD& &&&concat(quota,'S')
MYSQL_WHERE_CLAUSE& & active='1'
DEFAULT_DOMAIN&&mail.
下面是引用maoyh于 11:10发表的postfix/smtpd:SASL认证认败,请问是什么原因,多谢了,下面是LOG::
&&maillog:
Apr&&7 11:12:48 mail postfix/smtpd[4215]: warning: dict_nis_init: NIS domain name not set - NIS lookups disabled
Apr&&7 11:12:48 mail postfix/smtpd[4215]: connect from localhost.localdomain[127.0.0.1]
Apr&&7 11:13:12 mail postfix/smtpd[4215]: warning: localhost.localdomain[127.0.0.1]: SASL login authentication failed
pwcheck_method:authdaemond
log_level:3
srp_mda:md5
password_format:crypt
mech_listLAIN LOGIN
authdaemond_path: /usr/local/var/spool/authdaemon/socket
这里红色的内容,应该是authdaemon用不到的,但从楼上提供的日志,也看不出有关的错误。
试验一下打开authdaemonrc的DEBUG_LOGIN=2(记得重新启动authdamon)。
然后看看maillog在sasl出错时,有无authdaemon的出错提示。
高性能开源邮件系统- ExtMail Server
下面是maillog在SASL的出错,没有authdaemon出错:
Apr&&7 12:50:50 mail authdaemond: received auth request, service=smtp, authtype=login
Apr&&7 12:50:50 mail authdaemond: authmysql: trying this module
Apr&&7 12:50:50 mail authdaemond: SQL query: SELECT username, password, &&, '1001', '1001', '/var/mailbox/', maildir, concat(quota,'S'), name, && FROM mailbox WHERE username = && AND (active='1')
Apr&&7 12:50:50 mail authdaemond: zero rows returned
Apr&&7 12:50:50 mail authdaemond: no password available to compare
Apr&&7 12:50:50 mail authdaemond: authmysql: REJECT - try next module
Apr&&7 12:50:50 mail authdaemond: FAIL, all modules rejected
Apr&&7 12:50:50 mail postfix/smtpd[4392]: warning: localhost.localdomain[127.0.0.1]: SASL login authentication failed
Apr 7 12:50:50 mail authdaemond: zero rows returned
没这条记录
[root@mail root]# perl -MMIME::Base64 -e 'print encode_base64(&&);'
dGVzdC5nZm9yZ2UuZmdjLmNvbQ==
[root@mail root]# perl -MMIME::Base64 -e 'print encode_base64(&test&);'
[root@mail root]# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.localdomain (127.0.0.1).
Escape character is '^]'.
220 mail. ESMTP &Version not Available&
ehlo mail.
250-PIPELINING
250-AUTH LOGIN PLAIN
250-AUTH=LOGIN PLAIN
250 8BITMIME
auth login
334 VXNlcm5hbWU6
dGVzdC5nZm9yZ2UuZmdjLmNvbQ==
334 UGFzc3dvcmQ6
535 Error: authentication failed
421 mail. Error: timeout exceeded
Connection closed by foreign host.
我是这样测试的,为什么会出现username = && 这样的用户,搞不明白
有别名了吧
我没有做建别名哦,帮我看看,是哪里的原因?
现在邮件名字对了,但是认证还是错误,
Apr&&7 14:54:23 mail postfix/smtpd[3323]: connect from localhost.localdomain[127.0.0.1]
Apr&&7 14:54:53 mail authdaemond: received auth request, service=smtp, authtype=login
Apr&&7 14:54:53 mail authdaemond: authmysql: trying this module
Apr&&7 14:54:53 mail authdaemond: SQL query: SELECT username, password, &&, '1001', '1001', '/var/mailbox/', maildir, concat(quota,'S'), name, && FROM mailbox WHERE username = && AND (active='1')
Apr&&7 14:54:53 mail authdaemond: supplied password 'test' does not match encrypted password '$1$9dce4f5d$e1Is75XoKjcp/3n0PD1li/'
Apr&&7 14:54:53 mail authdaemond: authmysql: REJECT - try next module
Apr&&7 14:54:53 mail authdaemond: FAIL, all modules rejected
Apr&&7 14:54:53 mail postfix/smtpd[3323]: warning: localhost.localdomain[127.0.0.1]: SASL login authentication failed
Apr&&7 14:55:04 mail postfix/smtpd[3323]: disconnect from localhost.localdomain[127.0.0.1]
认证是过去了,我用OUTLOOK也可以登陆了,可以发邮件,但就是收不到,maillog也没有什么报错,还有就是我装了一个squirrelmail,在squirrelmail却不能登陆,提示:连接IMAP服务器出现错误:localhost。
111 : 拒绝连接
下面是引用maoyh于 15:54发表的:
认证是过去了,我用OUTLOOK也可以登陆了,可以发邮件,但就是收不到,maillog也没有什么报错,还有就是我装了一个squirrelmail,在squirrelmail却不能登陆,提示:连接IMAP服务器出现错误:localhost。
111 : 拒绝连接
imap服务器没启动吧。刚才楼上另一个帖子说pop3好,可是squirrel需要imap支持,不需要pop3的。
所以pop3好不代表imap没问题。
高性能开源邮件系统- ExtMail Server
[通过 QQ、MSN 分享给朋友]

我要回帖

更多关于 sasl errdetail 的文章

 

随机推荐