I have documented workaround for mod_wsgi for older versions of Django where HTTPS was detected incorrectly. See:
http://code.google.com/p/modwsgi/wiki/IntegrationWithDjango Specifically, use a little wrapper: import django.core.handlers.wsgi _application = django.core.handlers.wsgi.WSGIHandler() def application(environ, start_response): if environ['wsgi.url_scheme'] == 'https': environ['HTTPS'] = 'on' return _application(environ, start_response) My mistake for not documenting this earlier in mod_wsgi documentation. :-) Graham On Oct 31, 10:58 am, "Jeremy Dunck" <[EMAIL PROTECTED]> wrote: > On 10/30/07, Graham Dumpleton <[EMAIL PROTECTED]> wrote: > > > > > > > On Oct 31, 10:23 am, "Jeremy Dunck" <[EMAIL PROTECTED]> wrote: > ... > > > This is the current logic: > > > return 'HTTPS' in self._req.subprocess_env and > > > self._req.subprocess_env['HTTPS'] == 'on' > > > Hmmm, using req.is_https() was put back in trunk, if it fails, because > > it didn't exist, it would fallback to looking for HTTPS in > > req.subprocess_env. > > > 44 def is_secure(self): > > 45 try: > > 46 return self._req.is_https() > > 47 except AttributeError: > > 48 # mod_python < 3.2.10 doesn't have req.is_https(). > > 49 return self._req.subprocess_env.get('HTTPS', > > '').lower() in ('on', '1') > > > The changes were: > > > http://code.djangoproject.com/changeset/6359#file0 > > > Presume you aren't using trunk then. > > Interesting, and correct, we're on 6023. I'll look for a new > stable-ish rev to jump to. :) --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---