Mercurial > p > roundup > code
diff roundup/cgi/client.py @ 2724:7b1c440dba92
fix lookup of REMOTE_USER [SF#1002923]
| author | Richard Jones <richard@users.sourceforge.net> |
|---|---|
| date | Thu, 07 Oct 2004 23:13:11 +0000 |
| parents | edaa8ba86bd0 |
| children | 9605965569b0 |
line wrap: on
line diff
--- a/roundup/cgi/client.py Thu Oct 07 23:10:07 2004 +0000 +++ b/roundup/cgi/client.py Thu Oct 07 23:13:11 2004 +0000 @@ -1,4 +1,4 @@ -# $Id: client.py,v 1.187 2004-08-02 22:41:12 richard Exp $ +# $Id: client.py,v 1.188 2004-10-07 23:13:11 richard Exp $ """WWW request handler (also used in the stand-alone server). """ @@ -361,14 +361,12 @@ self.clean_sessions() sessions = self.db.getSessionManager() - user = 'anonymous' - # first up, try the REMOTE_USER var (from HTTP Basic Auth handled # by a front-end HTTP server) - try: - user = os.getenv('REMOTE_USER') - except KeyError: - pass + if self.env.has_key('REMOTE_USER'): + user = self.env['REMOTE_USER'] + else: + user = 'anonymous' # look up the user session cookie (may override the REMOTE_USER) cookie = self.cookie
