VRFY: advertise in EHLO response, if there is an ACL defined
[exim.git] / src / src / smtp_in.c
index 890c7c5173cf5746094837744fa4011deff6c836..04cbbe4656b4b8c5215978c71d8f98213ee161f9 100644 (file)
@@ -3903,19 +3903,20 @@ while (done <= 0)
         dsn_advertised = TRUE;
         }
 
-      /* Advertise ETRN if there's an ACL checking whether a host is
-      permitted to issue it; a check is made when any host actually tries. */
+      /* Advertise ETRN/VRFY/EXPN if there's are ACL checking whether a host is
+      permitted to issue them; a check is made when any host actually tries. */
 
-      if (acl_smtp_etrn != NULL)
+      if (acl_smtp_etrn)
         {
         s = string_catn(s, &size, &ptr, smtp_code, 3);
         s = string_catn(s, &size, &ptr, US"-ETRN\r\n", 7);
         }
-
-      /* Advertise EXPN if there's an ACL checking whether a host is
-      permitted to issue it; a check is made when any host actually tries. */
-
-      if (acl_smtp_expn != NULL)
+      if (acl_smtp_vrfy)
+        {
+        s = string_catn(s, &size, &ptr, smtp_code, 3);
+        s = string_catn(s, &size, &ptr, US"-VRFY\r\n", 7);
+        }
+      if (acl_smtp_expn)
         {
         s = string_catn(s, &size, &ptr, smtp_code, 3);
         s = string_catn(s, &size, &ptr, US"-EXPN\r\n", 7);