Skip site navigation (1)Skip section navigation (2)
Date:      22 Oct 2004 09:46:33 -0300
From:      Renato Botelho <renato@galle.com.br>
To:        FreeBSD-gnats-submit@FreeBSD.org
Cc:        freebsd@simplerezo.com
Subject:   ports/73001: [PATCH] mail/qmail-scanner: Fix spamd/spamc unix sockets detection
Message-ID:  <20041022124633.59109.qmail@srv1.galle.com.br>
Resent-Message-ID: <200410221250.i9MCoRxL034504@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         73001
>Category:       ports
>Synopsis:       [PATCH] mail/qmail-scanner: Fix spamd/spamc unix sockets detection
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Fri Oct 22 12:50:27 GMT 2004
>Closed-Date:
>Last-Modified:
>Originator:     Renato Botelho
>Release:        FreeBSD 5.2.1-RELEASE-p8 i386
>Organization:
Galle Folheados
>Environment:
System: FreeBSD srv1.galle.com.br 5.2.1-RELEASE-p8 FreeBSD 5.2.1-RELEASE-p8 #27: Wed May 26 10:21:14 BRT 2004
>Description:
When you are running spamd/spamc with unix sockets, Q-S configure script donīt detect the socket right.

Port maintainer (freebsd@simplerezo.com) is cc'd.

Generated with FreeBSD Port Tools 0.63
>How-To-Repeat:
>Fix:

--- qmail-scanner-1.24.patch begins here ---
diff -ruN --exclude=CVS /var/jail/data/usr/ports/mail/qmail-scanner.orig/files/patch-configure /var/jail/data/usr/ports/mail/qmail-scanner/files/patch-configure
--- /var/jail/data/usr/ports/mail/qmail-scanner.orig/files/patch-configure	Fri Oct 22 08:45:25 2004
+++ /var/jail/data/usr/ports/mail/qmail-scanner/files/patch-configure	Fri Oct 22 09:38:58 2004
@@ -1,5 +1,5 @@
---- configure.orig	Tue Oct 19 02:26:55 2004
-+++ configure	Fri Oct 22 01:36:34 2004
+--- ./configure.orig	Mon Oct 18 21:26:55 2004
++++ ./configure	Fri Oct 22 09:36:22 2004
 @@ -1,13 +1,6 @@
  #!/bin/sh
  #
@@ -78,7 +78,20 @@
    --scanners <list of installed content scanners>
  				    Defaults to "auto" - will use
  				    whatever scanners are found on system.
-@@ -1005,9 +1017,14 @@
+@@ -910,10 +922,11 @@
+ 	    #Test to see if spamc is calling Unix sockets instead of TCP
+ 	    SPAMD_SOCKET=`ps -ef 2>/dev/null|egrep 'spamd.*socket'|grep -v grep|sed -e 's/^.*socketpath=//'|awk '{print $1}'`
+ 	    if [ "$SPAMD_SOCKET" = "" ]; then
+-		SPAMD_SOCKET=`ps aux 2>/dev/null|egrep 'spamd.*socket'|grep -v grep|sed -e 's/^.*socketpath=//'|awk '{print $1}'`
++		SPAMD_SOCKET=`ps auxww 2>/dev/null|egrep 'spamd.*socket'|grep -v grep|sed -e 's/^.*socketpath=//'|awk '{print $1}'`
+ 	    fi
+ 	    if [ "$SPAMD_SOCKET" != "" -a -S "$SPAMD_SOCKET" ]; then
+ 		SPAMC_BINARY="$SPAMC_BINARY -U $SPAMD_SOCKET"
++		SA_HN=" -U $SPAMD_SOCKET"
+ 	    fi
+             DD="`$SPAMC_BINARY < ./contrib/spamc-nice.eml`"
+             if [ "`echo $DD|grep '^From '`" != "" ]; then
+@@ -1005,9 +1018,14 @@
  
  MAILDOMAIN=${MAILDOMAIN:-$FQDN}
  LOCAL_DOMAINS_ARRAY=${LOCAL_DOMAINS_ARRAY:-$MAILDOMAIN}
@@ -95,7 +108,7 @@
  if [ "$MANUAL_INSTALL" = "1" ]; then
      CMDLINE="$CMDLINE --no-QQ-check $MANUAL_INSTALL"
  fi
-@@ -1381,7 +1398,7 @@
+@@ -1381,7 +1399,7 @@
      fi
  fi
  
@@ -104,7 +117,7 @@
  
  SCANNER_ARRAY=`echo $SCANNER_ARRAY|sed 's/^,//g'`
  
-@@ -1461,7 +1478,13 @@
+@@ -1461,7 +1479,13 @@
      fi
      echo "archiving $ASTRING into $AS_QQ/$ARCHIVEDIR/"
  fi
@@ -119,7 +132,7 @@
  echo "local-domains=$LOCAL_DOMAINS_ARRAY"
  echo "silent-viruses=$FIND_SILENT_VIRUSES_ARRAY"
  echo "scanners=$SCANNER_ARRAY"
-@@ -1623,10 +1646,12 @@
+@@ -1623,10 +1647,12 @@
  s?SPAMC_BINARY?$SPAMC_BINARY?g;
  s?SPAMC_OPTIONS?$SPAMC_OPTIONS?g;
  s?SPAMC_SUBJECT?$SPAMC_SUBJECT?g;
--- qmail-scanner-1.24.patch ends here ---

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20041022124633.59109.qmail>