Ticket #3225: middleware-meta.patch

File middleware-meta.patch, 891 bytes (added by Collin Grady <cgrady@…>, 18 years ago)
  • docs/middleware.txt

     
    106106
    107107**New in Django development version**
    108108
    109 Sets ``request['REMOTE_ADDR']`` based on ``request.['HTTP_X_FORWARDED_FOR']``,
    110 if the latter is set. This is useful if you're sitting behind a reverse proxy
    111 that causes each request's ``REMOTE_ADDR`` to be set to ``127.0.0.1``.
     109Sets ``request.META['REMOTE_ADDR']`` based on
     110``request.META['HTTP_X_FORWARDED_FOR']``, if the latter is set. This is useful
     111if you're sitting behind a reverse proxy that causes each request's
     112``REMOTE_ADDR`` to be set to ``127.0.0.1``.
    112113
    113114**Important note:** This does NOT validate ``HTTP_X_FORWARDED_FOR``. If you're
    114115not behind a reverse proxy that sets ``HTTP_X_FORWARDED_FOR`` automatically, do
Back to Top