I 그러나 두 번째 서버가 메시지를 다시로드 할 때와 동일한 구성 및 에러를 수락하지 않는 다른 서버에 WSGI 인증 작업있다 : 여기 알 수없는 Authn 공급자 : wsgi ... 실패!
Syntax error on line 12 of /etc/apache2/sites-enabled/mydomain.com
Unknown Authn provider: wsgi
... fail
는 설정 파일의 중요한 부분이다 (행 12 WSGIAuthUserScript이고 ...)
<Location /adirectory/>
AuthType Basic
AuthName "Answer me these questions two"
AuthBasicProvider wsgi
WSGIAuthUserScript /home/auser/domains/mydomain.com/apache/auth_test.wsgi
Require valid-user
</location>
WSGIPassAuthorization On
그리고 auth_test.wsgi 파일 :
def check_password(environ, user, password):
if user == 'someusername':
if password == 'asecretpassword':
return True
return False
return None
모드-wsgi.conf 및 모드 - WSGI .load가 모두 사용 가능합니다. 물론/something/different가 있어야하지만, 나는 손실에 처해있다.
WSGIAuthUserScript를 메인 WSGI 응용 프로그램 (이미 호출되기 전에 처리되고있는 경우)에 보내지 않아도되는만큼 WSGIPassAuthorization을 사용할 필요가 없으므로 WSGIPassAuthorization이 필요하지 않습니다. –