我有一个颠覆服务器(svnserve)在我的Ubuntu上安装。
在我的svnserve.conf我设置了SASLauthentication:
.... [sasl] ### This option specifies whether you want to use the Cyrus SASL ### library for authentication. Default is false. ### This section will be ignored if svnserve is not built with Cyrus ### SASL support; to check, run 'svnserve --version' and look for a line ### reading 'Cyrus SASL authentication is available.' use-sasl = true min-encryption = 0 max-encryption = 256
然后我为svnconfigurationsaslauthentication使用saslauthd。
/usr/lib/sasl2/svn.conf pwcheck_method: saslauthd mech_list: plain log_level: 5 saslauthd_path: /var/run/saslauthd/mux
我不记得sasl究竟该怎么知道这是SVNconfiguration的path,但是在尝试了一些基于研究的组合之后,这个似乎是唯一可行的。 (虽然,我仍然喜欢一些解释为什么)
接下来是saslauthdconfiguration:
/etc/saslauthd.conf ldap_servers: ldap://1.2.3.4:389 ldap_use_sasl: no ldap_search_base: CN=Users,DC=yayme,DC=com ldap_bind_dn: [email protected] ldap_bind_pw: PASSWORD ldap_mech: PLAIN ldap_auth_method: bind ldap_filter: SOME FILTER
所有这些设置,SVN客户端都能够正确authentication,当用户或密码无效时,authentication失败,所以我很确定从svnserve到LDAP服务器(Windows Server 2012 R2)的连接已经build立。
现在,当我正在查看日志时,我在/var/log/auth.log中继续查找以下内容
svn: DIGEST-MD5 common mech free svn: ldapdb_canonuser_plug_init() failed in sasl_canonuser_add_plugin(): invalid parameter supplied svn: _sasl_plugin_load failed on sasl_canonuser_init for plugin: ldapdb
另外在一些less见的情况下:
saslauthd[37614]: Authentication failed for me/yayme.com: Bind to ldap server failed (invalid user/password or insufficient access) (-7) saslauthd[37614]: do_auth : auth failure: [user=me] [service=svn] [realm=yayme.com] [mech=ldap] [reason=Unknown] saslauthd[37613]: ldap_simple_bind() failed -1 (Can't contact LDAP server). saslauthd[37613]: Retrying authentication
我很确定密码是正确的,并且LDAP服务器还没有closures,我没有遇到任何两台机器之间的networking连接问题。
我试图把握svnserve的过程,但并没有太多的成果。
但是,我注意到,运行ldapwhoami没有其他参数将返回相同的错误ldap_sasl_interactive_bind_s: Can't contact LDAP server (-1)这是合理的,因为我没有指定主机,我的猜测是,它试图连接到本地主机(详细模式显示initialize(<DEFAULT>)但不是连接string…)。
所以我想知道在某些情况下,运行一个命令,它使用saslauthd碰巧正在跳过LDAPconfiguration文件?
任何想法debugging这个是受欢迎的!