permanent links cause some error messages in log file

Found a bug? Tell us!!
Post Reply
deminy
Regular
Posts: 28
Joined: Mon Oct 10, 2005 6:17 am
Contact:

permanent links cause some error messages in log file

Post by deminy »

This may not be a bug.

Platform: Apache 1.3.37, PHP 4.4.4, MySQL 4.1.21, and S9y v1.2 beta 2.

A web-crawler visited my website and generated lots of following warning messages in log file.
PHP Warning: mktime() expects parameter 5 to be long, string given in /home/deminy/public_html/blog/index.php on line 160/161
As I checked, those error messages were generated when the web-crawler visiting following URLs:
I can't figure out where this URLs are generated by s9y, thus couldn't fix this problem by myself.

Here is part of my .htaccess file (this htaccess file hadn't been changed for a long time):
# BEGIN s9y
ErrorDocument 404 /blog/index.php
DirectoryIndex /blog/index.php

RewriteEngine On
RewriteBase /blog/
RewriteRule ^((archives/([0-9]+)-y\.html)/?) index.php?/$1 [NC,L,QSA]
RewriteRule ^(authors/([0-9]+)-y) index.php?/$1 [NC,L,QSA]
RewriteRule ^(feeds/categories/([0-9;]+)-y\.rss) index.php?/$1 [NC,L,QSA]
RewriteRule ^(feeds/authors/([0-9]+)-p\.rss) index.php?/$1 [NC,L,QSA]
RewriteRule ^(categories/([0-9;]+)-y) index.php?/$1 [NC,L,QSA]
RewriteRule ^archives([/A-Za-z0-9]+)\.html index.php?url=/archives/$1.html [NC,L,QSA]
RewriteRule ^([0-9]+)[_\-][0-9a-z_\-]*\.html index.php?url=$1-article.html [L,NC,QSA]
RewriteRule ^feeds/(.*) index.php?url=/feeds/$1 [L,QSA]
RewriteRule ^unsubscribe/(.*)/([0-9]+) index.php?url=/unsubscribe/$1/$2 [L,QSA]
RewriteRule ^approve/(.*)/(.*)/([0-9]+) index.php?url=approve/$1/$2/$3 [L,QSA]
RewriteRule ^delete/(.*)/(.*)/([0-9]+) index.php?url=delete/$1/$2/$3 [L,QSA]
RewriteRule ^(admin|entries)(/.+)? index.php?url=admin/ [L,QSA]
RewriteRule ^archive/? index.php?url=/archive [L,QSA]
RewriteRule ^(index|atom[0-9]*|rss|b2rss|b2rdf).(rss|rdf|rss2|xml) rss.php?file=$1&ext=$2
RewriteRule ^(plugin|plugin)/(.*) index.php?url=$1/$2 [L,QSA]
RewriteRule ^search/(.*) index.php?url=/search/$1 [L,QSA]
RewriteRule ^comments/(.*) index.php?url=/comments/$1 [L,QSA]
RewriteRule ^(serendipity\.css|serendipity_admin\.css) index.php?url=/$1 [L,QSA]
RewriteRule ^index\.(html?|php.+) index.php?url=index.html [L,QSA]
RewriteRule ^htmlarea/(.*) htmlarea/$1 [L,QSA]
RewriteRule (.*\.html?) index.php?url=/$1 [L,QSA]
...
Thanks.
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: permanent links cause some error messages in log file

Post by garvinhicking »

Hi!

The URL seems to have gotten into the way because of "#cXXX" urls, those are created to a comment. It seems the web-crawler seems to parse those URLs wrong.

I just committed a fix to SVN that will now reject those invalid URLs and create the appropriate timestamp, thanks a lot!

Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Post Reply