I am interested in checking http:BL on user registration in addition to comment submission. I find this to be less invasive than every request I am receiving reports of legitimate users being blocked after being assigned an old poisoned IP. Alternatively maybe a configurable grey / black list threshold could be useful.

Anyway just eyeballing the code to see what is happening and I noticed this:

function httpbl_boot() {
  // Only continue when checks are enabled
  if (variable_get('httpbl_check', HTTPBL_CHECK_NONE) == HTTPBL_CHECK_NONE) {
    return;
  }

So I checked and if I choose HTTPBL_CHECK_COMMENTS in the settings, the above code means that a check is going to be made on hook_boot on every request regardless.

Here is a patch to fix it.

--- Base (BASE)
+++ Locally Modified (Based On LOCAL)
@@ -77,7 +77,7 @@
  */
 function httpbl_boot() {
   // Only continue when checks are enabled
-  if (variable_get('httpbl_check', HTTPBL_CHECK_NONE) == HTTPBL_CHECK_NONE) {
+  if (variable_get('httpbl_check', HTTPBL_CHECK_NONE) != HTTPBL_CHECK_ALL) {
     return;
   }

Comments

praseodym’s picture

Assigned: Unassigned » praseodym
Status: Needs review » Fixed

You're right! Fixed in commit 5a9e362.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.