On Mon, 22 Apr 2002, Richard A. DeVenezia wrote: > I am trying to analyze some standard Apache log files generated on a Linux > system. > > For some reason, some of the request URL's contain an embedded carriage > return. > They cause a C: message from analog when configured for DEBUG ON. > > Here is a hex dump of one such line, note the \r after macros > > 0: 37343930-3a36362e-3130382e-3136312e-32343720 7490:66.108.161.247 > 14: 2d202d20-5b31362f-4170722f-32303032-3a31353a - - [16/Apr/2002:15: > 28: 30393a30-33202d30-3530305d-20224745-54202f64 09:03 -0500] "GET /d > 3c: 6f776e6c-6f616473-2f736173-2f6d6163-726f73 d ownloads/sas/macros. > ^^ ^ > 50: 20485454-502f312e-30222033-30312032-35302022 HTTP/1.0" 301 250 " > 64: 2d222022-4d6f7a69-6c6c612f-332e3020-28636f6d -" "Mozilla/3.0 (com > 78: 70617469-626c6529-22 a patible)". > > > Is there a setting I have not yet found that will > - strip problem characters > or > - remove specified characters > or > - transform each log file input line according to some regexp > ? > > Is there some in Apache configuration setting that would prevent such log > entries from being made ? >
Basically, there's not much hope. Apache will put into the logfile whatever the client sent. If the client sends \r's, or other bad charaters, there's not much you can do about it. If it's only happening on a few lines, I wouldn't worry about it. If it's common, you could think about writing a pre-processor (it's a one-liner in Perl), but it's probably not worth the bother. -- Stephen Turner, Cambridge, UK http://homepage.ntlworld.com/adelie/stephen/ "This is Henman's 8th Wimbledon, and he's only lost 7 matches." BBC, 2/Jul/01 +------------------------------------------------------------------------ | This is the analog-help mailing list. To unsubscribe from this | mailing list, go to | http://lists.isite.net/listgate/analog-help/unsubscribe.html | | List archives are available at | http://www.mail-archive.com/[email protected]/ | http://lists.isite.net/listgate/analog-help/archives/ | http://www.tallylist.com/archives/index.cfm/mlist.7 +------------------------------------------------------------------------
