|
Post by petefinnigan on Aug 14, 2008 4:05:17 GMT -5
I discovered today that there are two bugs in the comment throttling code. The issue is in gm-comments.cgi in the function gm_commentthrottle. The first issue is that the IP check is not performed so everyone is throttled based on everyone elses comments. The second issue is around the time calculation. The last post if there is one is interogated and the hours are sought and multiplied by 60 and the minutes added. The current hours and minutes are calculated in the same way and then a check is performed: if( $currentMins < $commentMins ){ This fails because in my case the commentor was in Australia and he posted at a UK time of 12:45 am. I tried to post a new comment, i didnt have an existing comment so the non-existent IP check caused me to be comoared with the existing comment. This failed as I was at 08:?? UK time so the check says the difference is less than 1 minute because it was negative. This occured because I had a posted post a comment at 12:?? am in this case. My blog entry is www.petefinnigan.com/weblog/archives/00001198.htm#comments so you can see the issues. I had to turn off throttling for now. The IP check needs to be added and also the time check should convert time to 24 hour clock first and then do the compare. Thanks Pete
|
|
|
Post by coldstone on Aug 20, 2008 10:34:40 GMT -5
Good catch Pete. I should have these fixed for the next release.
|
|