Description

When using mod_python, I can no longer redirect the logout request.

Steps to reproduce

Our internal authentication system works similar to http authentication, but the user must request a page from the authentication server in order to complete logout. I redirected logout via the following while under cgi

Example

   1 def weblogin(request, **kw):
   2     from MoinMoin.user import User
   3     user_obj = kw.get('user_obj')
   4     logout = kw.get('logout')
   5     u = None
   6     if logout:
   7         url = u'http://server/logout'
   8         request.http_redirect(url)
   9         return user_obj, True
  10     ...

Is this approach correct in the first place?

This worked under my initial setup using cgi, but breaks under mod_python. I can hijack the logout by modifying MoinMoin/theme/__init__.py , but I would like to keep all my code separate for obvious maintenance reasons.

Details

MoinMoin Release 1.5.7 [Revision release]

Apache 2.0.52-28.ent.centos4

Python Version 2.5 (r25:51908)

Apache/mod_python-3.2.10

CentOS-4 (RHEL4)

English

Discussion

I guess the problem is related to not calling request.finish(). This needs someone running mod_python to debug the request code.

Plan


CategoryMoinMoinBugFixed

MoinMoin: MoinMoinBugs/ModPythonBreaksCustomLogout (last edited 2008-03-18 17:23:23 by p5B055566)