【问题标题】:LDAP authentication is not working after upgrading to ReviewBoard 2.0升级到 ReviewBoard 2.0 后 LDAP 身份验证不起作用
【发布时间】:2014-08-12 17:34:54
【问题描述】:

从 1.7 升级到 ReviewBoard 2.0 后,LDAP 身份验证方法似乎完全消失了。消失的意思是它不再是后端了:

python-ldap 已安装:

>>> import ldap
>>> ldap.__version__
'2.4.15'

当我启动交互式 shell 时,LDAP 后端不在 AUTHENTICATION_BACKENDS 列表中:

>>> reviewboard.accounts.backends.get_backends()
[<reviewboard.accounts.backends.StandardAuthBackend object at 0x4259190>]
>>> from django.conf import settings
>>> settings.AUTHENTICATION_BACKENDS
(u'reviewboard.accounts.backends.StandardAuthBackend',)

【问题讨论】:

    标签: python ldap upgrade review-board


    【解决方案1】:

    最后,我使用 virtualenv 安装了 ReviewBoard。不知道为什么,但似乎新版本在 mod_wsgi 文件中没有这个时以某种方式省略了现有的后端:

    activate_this = '/venv/bin/activate_this.py'
    execfile(activate_this, dict(__file__=activate_this))
    

    站点配置也应该有这个(在 django admin 中:/admin/db/siteconfig/siteconfiguration/1/):

    "auth_backend": "ldap",
    

    希望这会有所帮助。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2021-07-20
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-08-30
      相关资源
      最近更新 更多