[Moin-devel] Simple patch for attach file over SSL
Joo-won Jung
sanori at sanori.net
Wed Sep 4 05:08:02 EDT 2002
Hello,
Since Apache with mod_ssl does not give SSL_* environment variable to
CGI, MoinMoin.webapi.isSSL() gives wrong result. That causes that
TWikiDraw pictures does not appear if MoinMoin is over SSL/TLS (https).
So, I added HTTPS variable check routine, and it works.
Index: webapi/cgiMoin.py
===================================================================
RCS file: /cvsroot/moin/MoinMoin/webapi/cgiMoin.py,v
retrieving revision 1.16
diff -c -r1.16 cgiMoin.py
*** webapi/cgiMoin.py 17 Jul 2002 22:11:10 -0000 1.16
--- webapi/cgiMoin.py 4 Sep 2002 11:47:12 -0000
***************
*** 21,26 ****
--- 21,27 ----
def isSSL():
""" Return true if we are on a SSL (https) connection. """
return os.environ.get('SSL_PROTOCOL', '') != '' or \
+ os.environ.get('HTTPS', '') != '' or \
os.environ.get('SSL_PROTOCOL_VERSION', '') != ''
Hope this helps
-Sanori
More information about the Moin-devel
mailing list