Commit 92e5e611 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

only quote a path part in request string.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@22631 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 7a37b870
......@@ -57,6 +57,12 @@ def log (self, bytes):
else:
name = t[0]
# Originally, an unquoted request string was logged, but
# it only confuses log analysis programs! Note that Apache
# HTTP Server never unquote URIs in the access log.
t = self.request.split(' ')
quoted_request = '%s %s %s' % (t[0], quote(' '.join(t[1:-1])), t[-1])
self.channel.server.logger.log (
# <patch>
addr,
......@@ -64,11 +70,8 @@ def log (self, bytes):
'- %s [%s] "%s" %d %d "%s" "%s"\n' % (
name,
self.log_date_string (time.time()),
# Originally, an unquoted request string was logged, but
# it only confuses log analysis programs! Note that Apache
# HTTP Server never unquote URIs in the access log.
# <patch>
quote(self.request),
quoted_request,
# </patch>
self.reply_code,
bytes,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment