Adding "smtp_helo_override" hook
authorpdontthink <pdontthink@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Mon, 30 Nov 2015 22:48:12 +0000 (22:48 +0000)
committerpdontthink <pdontthink@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Mon, 30 Nov 2015 22:48:12 +0000 (22:48 +0000)
git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@14527 7612ce4b-ef26-0410-bec9-ea0150e637f0

class/deliver/Deliver_SMTP.class.php

index b34063121551e3e5038cfb47f753b1985a142043..90c90c0052cae54cbd8d8dba44266223369570de 100644 (file)
@@ -154,6 +154,9 @@ class Deliver_SMTP extends Deliver {
         if (preg_match('/^\d+\.\d+\.\d+\.\d+$/', $helohost))
             $helohost = '[' . $helohost . ']';
 
+        $hook_result = do_hook('smtp_helo_override', $helohost);
+        if (!empty($hook_result)) $helohost = $hook_result;
+
         /* Lets introduce ourselves */
         fputs($stream, "EHLO $helohost\r\n");
         // Read ehlo response