On Monday, October 15, 2012 8:22:55 AM UTC+5:30, Graham Dumpleton wrote:
>
> The restriction on what mod_wsgi WSGIUserAuthScript does is because it
> is implementing an Apache authentication provider and not a full
> Apache handler. As such it isn't possible to override the status. That
> is because of how Apache authentication providers work and not
> mod_wsgi. The WSGIAccessScript is principally to do the equivalent of
> 'All from host' so all it can do is signal whether forbidden or not.
>
> Anyway, post your existing mod_python access handler and may be able
> to suggest something. If you were using an access handler to do
> authentication you were technically abusing Apache in ways you
> shouldn't. So not sure if will though have an answer.
>
I am not sure whether I am supposed to share the code. But definitely I can
tell what the code does.
def accesshandler(req):
return authenhandler(req)
def authenhandler(req):
do_house_keeping()
authenticated = do_cookie_auth(req) # This is done even without a user
entering username and password.
if authenticated == False:
pw = req.get_basic_auth_pw() # Here is were we are asking the
client for username and password.
I think from the above snippet it is very clear, what I am doing.
Thanks and Regards
Noorul
--
You received this message because you are subscribed to the Google Groups
"modwsgi" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/modwsgi/-/cHXUGciJpakJ.
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/modwsgi?hl=en.