I'm told that, here at Georgia Tech, we are running our Plone's Zope
2.10 behind "pound", and that we need some way to signal it about
which requests are coming in through "http" and which came through
"https", so that all of the links generated by Plone can start with
the right protocol.  So at the moment, users who type an "https" URL
so that they can edit documents and enjoy some privacy immediately get
kicked back to the "http" protocol the first time they click on a

For an earlier version of our site, back on an earlier version of Zope
and Plone, we edited Zope so that it detected an "HTTPS" header, if
one was present, and allowed the value:

   HTTPS: on

to change the protocol variable from HTTP to HTTPS.  Then we told
pound to provide that header when an "https" request was made, and to
delete the header otherwise, and everything worked fine.

Would there be any chance of getting this change into Zope trunk
today, or is it too specific a need to be worth adding to the code
just for us folks using "pound" at Georgia Tech?

The patch, in the form in which we first wrote it back at the
beginning of 2007, is attached for the curious.  Thanks for any feedback!

--- /usr/local/zope-2.9.5/lib/python/ZPublisher/HTTPRequest.py  2006-10-02 11:53:33.000000000 -0400
+++ /usr/local/zope-2.9.5/lib/python/ZPublisher/HTTPRequest.py  2007-01-03 18:20:35.000000000 -0500
@@ -294,6 +294,10 @@
             if have_env('HTTPS') and (
                 environ['HTTPS'] == "on" or environ['HTTPS'] == "ON"):
                 protocol = 'https'
+            elif have_env('HTTP_HTTPS') and (
+                environ['HTTP_HTTPS'] == "on" or
+                environ['HTTP_HTTPS'] == "ON"):
+                protocol = 'https'
             elif (have_env('SERVER_PORT_SECURE') and
                 environ['SERVER_PORT_SECURE'] == "1"):
                 protocol = 'https'
Brandon Craig Rhodes   [EMAIL PROTECTED]   http://rhodesmill.org/brandon
Zope-Dev maillist  -  Zope-Dev@zope.org
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope )

Reply via email to