changeset 4333:b52a579db72d

fix crash in antispam code
author Thomas Waldmann <tw AT waldmann-edv DOT de>
date Sat, 27 Sep 2008 00:24:43 +0200
parents e6b29581866d
children 7add275cf4de
files MoinMoin/security/antispam.py
diffstat 1 files changed, 2 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/MoinMoin/security/antispam.py	Fri Sep 26 23:37:55 2008 +0200
+++ b/MoinMoin/security/antispam.py	Sat Sep 27 00:24:43 2008 +0200
@@ -78,8 +78,7 @@
             master = xmlrpclib.ServerProxy(master_url)
             try:
                 # Get BadContent info
-                master.putClientInfo('ANTISPAM-CHECK',
-                                     request.http_host+request.script_name)
+                master.putClientInfo('ANTISPAM-CHECK', request.url)
                 response = master.getPageInfo(pagename)
 
                 # It seems that response is always a dict
@@ -101,7 +100,7 @@
                 if mydate < masterdate:
                     # Get new copy and save
                     logging.info("Fetching page from %s..." % master_url)
-                    master.putClientInfo('ANTISPAM-FETCH', request.http_host + request.script_name)
+                    master.putClientInfo('ANTISPAM-FETCH', request.url)
                     response = master.getPage(pagename)
                     if isinstance(response, dict) and 'faultCode' in response:
                         raise WikirpcError("failed to get BadContent data", response)