Changeset 3951

Show
Ignore:
Timestamp:
01/16/08 08:20:06 (11 months ago)
Author:
faide
Message:

Fixed cherFixed CP request header inspection in the identity inspection.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • tags/1.0.3.4/turbogears/identity/conditions.py

    r2845 r3951  
    167167def _remoteHost(): 
    168168    try: 
    169         ips= cherrypy.request.headers.get( "X-Forwarded-For", 
    170                                              cherrypy.request.remote_host ) 
     169        ips= cherrypy.request.headers.get( 
     170                "X-Forwarded-For", cherrypy.request.headers.get('Remote-Addr')) 
     171 
    171172        return ips.split(",")[-1].strip() 
    172173    except: 
     174 
    173175        return "" 
    174176