Skip to content

Commit 35909d9

Browse files
author
Richard Jones
committed
fix lookup of REMOTE_USER [SF#1002923]
1 parent 6e67176 commit 35909d9

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

CHANGES.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ Fixed:
4343
- use row locking in MySQL newid() (sf bug 1034211)
4444
- add sanity check for sort and group on same property (sf bug 1033477)
4545
- extend OTK and session table value cols to TEXT (sf bug 1031271)
46+
- fix lookup of REMOTE_USER (sf bug 1002923)
4647

4748

4849
2004-07-21 0.7.6

doc/index.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ Seb Brezel,
7474
Titus Brown,
7575
Godefroid Chapelle,
7676
Roch'e Compaan,
77+
Wil Cooley,
7778
Joe Cooper,
7879
Kelley Dagley,
7980
Paul F. Dubois,

roundup/cgi/client.py

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $Id: client.py,v 1.187 2004-08-02 22:41:12 richard Exp $
1+
# $Id: client.py,v 1.188 2004-10-07 23:13:11 richard Exp $
22

33
"""WWW request handler (also used in the stand-alone server).
44
"""
@@ -361,14 +361,12 @@ def determine_user(self):
361361
self.clean_sessions()
362362
sessions = self.db.getSessionManager()
363363

364-
user = 'anonymous'
365-
366364
# first up, try the REMOTE_USER var (from HTTP Basic Auth handled
367365
# by a front-end HTTP server)
368-
try:
369-
user = os.getenv('REMOTE_USER')
370-
except KeyError:
371-
pass
366+
if self.env.has_key('REMOTE_USER'):
367+
user = self.env['REMOTE_USER']
368+
else:
369+
user = 'anonymous'
372370

373371
# look up the user session cookie (may override the REMOTE_USER)
374372
cookie = self.cookie

0 commit comments

Comments
 (0)