#10809: mod_wsgi authentication handler
---------------------------------------------+------------------------------
          Reporter:  baumer1122              |         Owner:  davidfischer
            Status:  assigned                |     Milestone:              
         Component:  Authentication          |       Version:  SVN         
        Resolution:                          |      Keywords:  mod_wsgi    
             Stage:  Design decision needed  |     Has_patch:  1           
        Needs_docs:  1                       |   Needs_tests:  0           
Needs_better_patch:  1                       |  
---------------------------------------------+------------------------------
Changes (by davidfischer):

  * owner:  nobody => davidfischer
  * status:  new => assigned

Comment:

 It sounds like you've thought this through. Still, I think that a mod_wsgi
 auth handler is a good idea. Considering your suggestions, I think an auth
 script should look something like this:
 {{{
 import sys
 sys.path.append(...)

 import os
 os.environ['DJANGO_SETTINGS_MODULE'] = 'mysite.settings'

 import django.contrib.auth.handlers.modwsgi

 def check_password(environ, user, password):
     return django.contrib.auth.handlers.modwsgi.check_password(environ,
 user, password)
 }}}

 In this way, there will always be an external auth script but at least
 users won't be repeating themselves as much.

 I like this solution a lot better than making sure that the system path is
 set properly and that the `DJANGO_SETTINGS_MODULE` environment variable is
 set in the OS level before starting Apache. That solution would also have
 problems with multiple Django projects authenticating against multiple
 auth databases running on the same Apache instance.

 I'll start working on a patch.

-- 
Ticket URL: <http://code.djangoproject.com/ticket/10809#comment:11>
Django <http://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to