0

我设置了一些 RADIUS 后端以允许通过 django 的“管理员”进行 AD 身份验证。Alltough我有一些字典的问题,我真的不知道我做错了什么。这是我得到的错误:

IOError at /admin/ Errno 2] 没有这样的文件或目录:'/home/pl/dictionary.compat'

我安装了 pyrad,所以它应该在那里,并且我有一个以下样式的“dict”文件(/home/pl/dict):

#
# Version $Id: dictionary,v 1.1.1.1 2002/10/11 12:25:39 wichert Exp $
.....
$INCLUDE dictionary.compat # compability issues
$INCLUDE dictionary.acc
$INCLUDE dictionary.ascend
$INCLUDE dictionary.bay
....

我在 RADIUS 后端使用的代码:

srv = Client(server=settings.RADIUS_SERVER,
      secret=settings.RADIUS_SECRET,
      dict=Dictionary("/home/pl/dict"))

有任何想法吗?

4

1 回答 1

0

The $INCLUDE directive in the configuration files is intended to add definitions from another dictionary file. Unless the extra dictionary files are found, the dictionary object cannot be created.

My advice is: - if you don't have the extra dictionary files: comment out/remove the $INCLUDE lines - if you have the extra dictionary files: copy them to the right location

于 2010-10-12T08:50:03.577 回答