diff MoinMoin/request/__init__.py @ 2369:ccf996479233

fix a suid bug: force switched-to user valid
author Johannes Berg <johannes AT sipsolutions DOT net>
date Thu, 12 Jul 2007 11:41:35 +0200
parents 39d11cf4af6c
children 609ef7393a14
line wrap: on
line diff
--- a/MoinMoin/request/__init__.py	Thu Jul 12 11:41:09 2007 +0200
+++ b/MoinMoin/request/__init__.py	Thu Jul 12 11:41:35 2007 +0200
@@ -240,7 +240,9 @@
                 self._setuid_real_user = self.user
                 uid = self.session['setuid']
                 self.user = user.User(self, uid, auth_method='setuid')
-                self.user.disabled = False
+                # set valid to True so superusers can even switch
+                # to disable accounts
+                self.user.valid = True
 
             if self.action != 'xmlrpc':
                 if not self.forbidden and self.isForbidden():