用于django的spnego kerberos身份验证中间件
django-auth-spnego的Python项目详细描述
#django auth spnego
此项目为django项目提供spnego和kerberos身份验证。您可以使用apache
或i i s来实现这一点,并使用django的远程用户中间件进行身份验证,但我不使用那些web服务器
,其他服务器也不支持它。
有用的
[django auth ldap](https://bitbucket.org/illocution/django auth ldap)。
一些文档即将发布。
您可以更改此
,但在用户的
kerberos会话票证过期时,您必须确定如何销毁会话。
服务器安装需要在django项目的“setting s.py”中添加以下内容。
`认证中间件。例如:
`` python
中间件=[
'django.middleware.security.securitymiddleware',
'django.contrib.sessions.middleware.sessionmiddleware',
'django.middleware.common.commonmiddleware',
'django.middleware.csrf.csrfviewmiddleware',
'django.contrib.auth.middleware.authenticationmiddleware',
'authspnego.middleware.authspnegomidleware',
'django.contrib.messages.middleware.messagemiddleware',
'django.middleware.clickjacking.xframeoptionsmidleware',
]
```
将“ldap backend”添加到“身份验证后端”设置:
```python
身份验证后端=(
“django-auth-ldap.backend.ldapbackend”,
“django.contrib.auth.backend.modelbackend”,
```
添加特定于SPNEGO的设置。关键是要正确地获取这些值,否则这些值都不起作用:
`` python
spnego_realm='lab.azmoo.id.au'`您的广告域。这几乎总是资本化的。
spnego-hostname='你的app server.lab.azmoo.id.au''spnego-hostname='你的appserver.lab.azmoo.id.au''你的appserver的fqdn。
spnego-expire-login=600;设置为false,永不过期
``
最后,你需要配置[django auth-ldap](https://bitbbucket.org/illoution/django auth-ldap)Django auth-ldap(https://bitbbucket.org/illoution/django auth-ldap)Django-auth-ldap)。
是的[semver](http://semver.org/)用于版本控制。对于可用的版本,请参阅[在这个存储库上的标签](https://github.com/your/project/tags)。
<<
***马特马金**-*初始工作*[azmoo](https://github.com/azmoo)
这个项目是在麻省理理工(mit.com/azmoo)的许可下授权的,请参阅[license.md](license.md)文件,了解详情
*单点登录[gateone]的实现(https://liftoff.github.io/gateone/developer/sso.html)对于了解kerberos库应该如何使用非常有用。
*[django auth ldap](https://bitbucket.org/illocution/django-auth-ldap)为django auth端的事情节省了大量时间
此项目为django项目提供spnego和kerberos身份验证。您可以使用apache
或i i s来实现这一点,并使用django的远程用户中间件进行身份验证,但我不使用那些web服务器
,其他服务器也不支持它。
有用的
[django auth ldap](https://bitbucket.org/illocution/django auth ldap)。
一些文档即将发布。
您可以更改此
,但在用户的
kerberos会话票证过期时,您必须确定如何销毁会话。
服务器安装需要在django项目的“setting s.py”中添加以下内容。
`认证中间件。例如:
`` python
中间件=[
'django.middleware.security.securitymiddleware',
'django.contrib.sessions.middleware.sessionmiddleware',
'django.middleware.common.commonmiddleware',
'django.middleware.csrf.csrfviewmiddleware',
'django.contrib.auth.middleware.authenticationmiddleware',
'authspnego.middleware.authspnegomidleware',
'django.contrib.messages.middleware.messagemiddleware',
'django.middleware.clickjacking.xframeoptionsmidleware',
]
```
将“ldap backend”添加到“身份验证后端”设置:
```python
身份验证后端=(
“django-auth-ldap.backend.ldapbackend”,
“django.contrib.auth.backend.modelbackend”,
```
添加特定于SPNEGO的设置。关键是要正确地获取这些值,否则这些值都不起作用:
`` python
spnego_realm='lab.azmoo.id.au'`您的广告域。这几乎总是资本化的。
spnego-hostname='你的app server.lab.azmoo.id.au''spnego-hostname='你的appserver.lab.azmoo.id.au''你的appserver的fqdn。
spnego-expire-login=600;设置为false,永不过期
``
最后,你需要配置[django auth-ldap](https://bitbbucket.org/illoution/django auth-ldap)Django auth-ldap(https://bitbbucket.org/illoution/django auth-ldap)Django-auth-ldap)。
是的[semver](http://semver.org/)用于版本控制。对于可用的版本,请参阅[在这个存储库上的标签](https://github.com/your/project/tags)。
<<
***马特马金**-*初始工作*[azmoo](https://github.com/azmoo)
这个项目是在麻省理理工(mit.com/azmoo)的许可下授权的,请参阅[license.md](license.md)文件,了解详情
*单点登录[gateone]的实现(https://liftoff.github.io/gateone/developer/sso.html)对于了解kerberos库应该如何使用非常有用。
*[django auth ldap](https://bitbucket.org/illocution/django-auth-ldap)为django auth端的事情节省了大量时间