aboutsummaryrefslogtreecommitdiffstats
path: root/mail/p3scan
diff options
context:
space:
mode:
Diffstat (limited to 'mail/p3scan')
-rw-r--r--mail/p3scan/Makefile60
-rw-r--r--mail/p3scan/distinfo2
-rw-r--r--mail/p3scan/files/p3scan.in37
-rw-r--r--mail/p3scan/files/patch-Makefile58
-rw-r--r--mail/p3scan/files/patch-getline_ssl.c18
-rw-r--r--mail/p3scan/files/patch-getlinep3.c11
-rw-r--r--mail/p3scan/files/patch-p3scan.c96
-rw-r--r--mail/p3scan/files/patch-p3scan.conf10
-rw-r--r--mail/p3scan/files/patch-p3scan.h30
-rw-r--r--mail/p3scan/files/patch-parsefile.c14
-rw-r--r--mail/p3scan/files/patch-ripmime__build_ripOLE9
-rw-r--r--mail/p3scan/files/patch-ripmime__build_tnef7
-rw-r--r--mail/p3scan/files/patch-ripmime__tnef__Makefile13
-rw-r--r--mail/p3scan/files/patch-scanner_avpd.c16
-rw-r--r--mail/p3scan/files/patch-scanner_avpd_new.c18
-rw-r--r--mail/p3scan/files/patch-scanner_bash.c12
-rw-r--r--mail/p3scan/files/patch-scanner_basic.c14
-rw-r--r--mail/p3scan/files/patch-scanner_clamd.c38
-rw-r--r--mail/p3scan/files/patch-scanner_sample.c14
-rw-r--r--mail/p3scan/files/patch-scanner_trophie.c14
-rw-r--r--mail/p3scan/files/pkg-message.in23
-rw-r--r--mail/p3scan/pkg-descr11
-rw-r--r--mail/p3scan/pkg-install154
23 files changed, 0 insertions, 679 deletions
diff --git a/mail/p3scan/Makefile b/mail/p3scan/Makefile
deleted file mode 100644
index fac48251362..00000000000
--- a/mail/p3scan/Makefile
+++ /dev/null
@@ -1,60 +0,0 @@
-# Created by: Edwin Groothuis <edwin@mavetju.org>
-# $FreeBSD$
-
-PORTNAME= p3scan
-PORTVERSION= 2.3.2
-PORTREVISION= 6
-CATEGORIES= mail net
-MASTER_SITES= SF/${PORTNAME}/${PORTNAME}%20%28stable%29/${PORTNAME}-${PORTVERSION}
-
-MAINTAINER= ports@FreeBSD.org
-COMMENT= Transparent POP3-Proxy with virus-scanning capabilities
-
-LIB_DEPENDS= libpcre.so:${PORTSDIR}/devel/pcre
-
-PLIST_FILES= etc/p3scan/p3scan.conf.sample etc/p3scan/p3scan.mail.sample \
- sbin/p3scan
-PLIST_DIRS= etc/p3scan
-
-USE_GCC= any
-USES= gmake
-MAKE_ENV= _LDFLAGS="${LDFLAGS} -L${LOCALBASE}/lib" GMAKE=${MAKE_CMD}
-SCRIPTS_ENV= PKG_PREFIX=${PREFIX} NONEXISTENT=${NONEXISTENT} PASSWD=/etc/passwd
-PKGMESSAGE= ${WRKDIR}/pkg-message
-
-PORTDOCS= AUTHORS CHANGELOG LICENSE NEWS README
-MAN8= p3scan.8 p3scan_readme.8
-MANCOMPRESSED= yes
-
-USE_RC_SUBR= p3scan
-SUB_FILES= p3scan pkg-message
-
-NO_STAGE= yes
-.include <bsd.port.pre.mk>
-
-do-install:
-.if !exists(${PREFIX}/etc/p3scan)
- ${MKDIR} ${PREFIX}/etc/p3scan
-.endif
-.if !exists(/var/spool/p3scan)
- ${MKDIR} /var/spool/p3scan
-.endif
- ${CHOWN} mailnull:mail /var/spool/p3scan
- ${INSTALL_PROGRAM} ${WRKSRC}/p3scan ${PREFIX}/sbin/
- ${INSTALL_DATA} ${WRKSRC}/p3scan.conf ${PREFIX}/etc/p3scan/p3scan.conf.sample
- ${INSTALL_DATA} ${WRKSRC}/p3scan-en.mail ${PREFIX}/etc/p3scan/p3scan.mail.sample
-.for f in ${MAN8}
- ${INSTALL_MAN} ${WRKSRC}/${f}.gz ${MAN8PREFIX}/man/man8/
-.endfor
-.ifndef (NOPORTDOCS)
- ${MKDIR} ${DOCSDIR}
-.for f in ${PORTDOCS}
- ${INSTALL_DATA} ${WRKSRC}/${f} ${DOCSDIR}
-.endfor
-.endif
-
-post-install:
- @${SETENV} ${SCRIPTS_ENV} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL
- @${CAT} ${PKGMESSAGE}
-
-.include <bsd.port.post.mk>
diff --git a/mail/p3scan/distinfo b/mail/p3scan/distinfo
deleted file mode 100644
index c225c4874fd..00000000000
--- a/mail/p3scan/distinfo
+++ /dev/null
@@ -1,2 +0,0 @@
-SHA256 (p3scan-2.3.2.tar.gz) = 570bdf87132b23120339e247809dc2cf37c2735d504f4e1072528c04d940bb5f
-SIZE (p3scan-2.3.2.tar.gz) = 321684
diff --git a/mail/p3scan/files/p3scan.in b/mail/p3scan/files/p3scan.in
deleted file mode 100644
index 09e185ba21e..00000000000
--- a/mail/p3scan/files/p3scan.in
+++ /dev/null
@@ -1,37 +0,0 @@
-#!/bin/sh
-#
-# $FreeBSD$
-#
-# PROVIDE: p3scan
-# REQUIRE: DAEMON
-#
-# Add the following lines to /etc/rc.conf to enable p3scan:
-# p3scan_enable="YES"
-#
-# Optional:
-# p3scan_config="%%PREFIX%%/etc/p3scan/p3scan.conf
-#
-
-. /etc/rc.subr
-
-name=p3scan
-rcvar=p3scan_enable
-
-required_files=%%PREFIX%%/etc/p3scan/p3scan.conf
-
-# set defaults
-
-p3scan_enable=${p3scan_enable:-"NO"}
-p3scan_config=${p3scan_config:-"%%PREFIX%%/etc/p3scan/p3scan.conf"}
-
-load_rc_config $name
-run_rc_command "$1"
-
-start_cmd="p3scan_start"
-
-p3scan_start()
-{
- %%PREFIX%%/sbin/p3scan -f ${p3scan_config}
-}
-
-run_rc_command "$1"
diff --git a/mail/p3scan/files/patch-Makefile b/mail/p3scan/files/patch-Makefile
deleted file mode 100644
index 9ed27b79ef4..00000000000
--- a/mail/p3scan/files/patch-Makefile
+++ /dev/null
@@ -1,58 +0,0 @@
---- Makefile.orig Mon Dec 12 18:00:00 2005
-+++ Makefile Mon May 1 11:07:46 2006
-@@ -39,27 +39,27 @@
- LOGFAC="LOG_DAEMON"
- LOGSET=-DLOGOPT=${LOGOPT} -DLOGFAC=${LOGFAC}
- LANG=en
--CC=gcc
-+CC?=gcc
- SYSINS=install
- #CFLAGS=-Wall -O3 -march=i686 ${LOGSET}
--CFLAGS=-Wall -O2 $(LOGSET)
-+CFLAGS=-Wall -O2 $(LOGSET) -I${PREFIX}/include -I/usr/local/include
-
- #ifdef DEMIME :)
--LDFLAGS=-L. -lripmime -lpcre -lssl -lcrypto #-static
-+LDFLAGS=-L. -lripmime -lpcre -lssl -lcrypto ${_LDFLAGS} #-static
- #else
- #LDFLAGS=-L. -lpcre -lssl -lcrypto
- #endif :)
-
--PREFIX=/usr
-+PREFIX=/usr/local
- DESTDIR=
- #MANDIR=$(PREFIX)/share/man/man8
--MANDIR=$(PREFIX)/man/man8
-+MANDIR?=$(PREFIX)/man/man8
- piddir=/var/run/$(PROGS)
- datadir=/var/spool/$(PROGS)
- notify=/var/spool/$(PROGS)/notify
--userdir=/etc/$(PROGS)
--docdir=/usr/doc/$(DISTNAME)
--user=mail:mail
-+userdir=$(PREFIX)/etc/$(PROGS)
-+docdir=$(PREFIX)/share/doc/$(DISTNAME)
-+user=mailnull:mail
- # End user options
-
- OBJECTS=getlinep3.o getline_ssl.o parsefile.o p3scan.o \
-@@ -85,7 +85,7 @@
- dep depend .dep:
- @echo "creating depencies"
- rm -f .tmp.dep
-- @find -maxdepth 1 -name "*.c" -print0 | xargs -n 1 -0rt $(CC) -M $(CFLAGS) >>.tmp.dep
-+ @find . -maxdepth 1 -name "*.c" -print0 | xargs -n 1 -0rt $(CC) -M $(CFLAGS) >>.tmp.dep
- mv .tmp.dep .dep
-
- install: p3scan
-@@ -163,8 +163,8 @@
-
- fulltags:
- @#VIM Users know why! *g*
-- find -maxdepth 1 -name "*.c" -print0 | xargs -n 1 -0r $(CC) -M -H $(CFLAGS) 2>.totag >/dev/null
-- find -maxdepth 1 -name "*.c" -print0 | xargs -n 1 -0r echo >>.totag
-+ find . -maxdepth 1 -name "*.c" -print0 | xargs -n 1 -0r $(CC) -M -H $(CFLAGS) 2>.totag >/dev/null
-+ find . -maxdepth 1 -name "*.c" -print0 | xargs -n 1 -0r echo >>.totag
- cat .totag | sed "s/^[[:space:]]*//" | grep -v "^$(CC)" | sort | uniq >.totag
- ctags --c-types=+c+p+f+x -L .totag .
- rm -f .totag
diff --git a/mail/p3scan/files/patch-getline_ssl.c b/mail/p3scan/files/patch-getline_ssl.c
deleted file mode 100644
index 5555501aee4..00000000000
--- a/mail/p3scan/files/patch-getline_ssl.c
+++ /dev/null
@@ -1,18 +0,0 @@
---- getline_ssl.c.orig Mon May 1 00:18:22 2006
-+++ getline_ssl.c Mon May 1 00:18:25 2006
-@@ -38,7 +38,6 @@
- #include <stdio.h>
- #include <unistd.h>
- #include <string.h>
--#include <malloc.h>
- #include <stdarg.h>
- #include <fcntl.h>
- #include <sys/time.h>
-@@ -50,6 +49,7 @@
- #include <netdb.h>
- #include <stdlib.h>
- #include <sys/wait.h>
-+#include <stdlib.h>
-
- #include "getline_ssl.h"
-
diff --git a/mail/p3scan/files/patch-getlinep3.c b/mail/p3scan/files/patch-getlinep3.c
deleted file mode 100644
index 0e41f640503..00000000000
--- a/mail/p3scan/files/patch-getlinep3.c
+++ /dev/null
@@ -1,11 +0,0 @@
---- getlinep3.c.orig Mon May 1 00:39:10 2006
-+++ getlinep3.c Mon May 1 00:39:28 2006
-@@ -37,7 +37,7 @@
- #include <stdio.h>
- #include <unistd.h>
- #include <string.h>
--#include <malloc.h>
-+#include <stdlib.h>
- #include <stdarg.h>
- #include <fcntl.h>
- #include <sys/time.h>
diff --git a/mail/p3scan/files/patch-p3scan.c b/mail/p3scan/files/patch-p3scan.c
deleted file mode 100644
index 9831f7f7c26..00000000000
--- a/mail/p3scan/files/patch-p3scan.c
+++ /dev/null
@@ -1,96 +0,0 @@
---- p3scan.c.orig Tue Dec 13 02:00:00 2005
-+++ p3scan.c Wed Nov 1 11:44:03 2006
-@@ -41,36 +41,37 @@
- TODO: Wanted: white-list support
- TODO: Wanted: no iptables support
- */
--#include <stdio.h>
--#include <stdlib.h>
--#include <string.h>
--#include <arpa/inet.h>
--#include <netinet/in.h>
--#include <netinet/ip.h>
--#include <sys/socket.h>
- #include <sys/types.h>
-+#include <sys/socket.h>
-+#include <sys/wait.h>
-+#include <sys/time.h>
-+#include <sys/param.h>
-+#include <sys/signal.h>
- #include <sys/stat.h>
-+#include <sys/statvfs.h>
-+#include <netinet/in.h>
-+#include <netinet/in_systm.h>
-+#include <netinet/ip.h>
-+#include <arpa/inet.h>
- #include <fcntl.h>
- #include <unistd.h>
- #include <stdarg.h>
--#include <sys/signal.h>
--#include <sys/wait.h>
- #include <pwd.h>
- #include <time.h>
--#include <sys/time.h>
- #include <syslog.h>
--#include <sys/param.h>
- #include <ctype.h>
--#include <linux/netfilter_ipv4.h>
--#include <malloc.h>
-+#include <stdio.h>
-+#include <stdlib.h>
-+#include <string.h>
- #include <getopt.h>
- #include <netdb.h>
- #include <libgen.h>
- #include <errno.h>
- #include <dirent.h>
--#include <sys/statvfs.h>
- #include <assert.h>
- #include <sys/select.h>
-+#include <sys/ucred.h>
-+#include <sys/mount.h>
-
- #include "p3scan.h"
- #include "getline_ssl.h"
-@@ -182,8 +183,8 @@
- do_log(LOG_NOTICE, "ERR: Exiting now...\n");
- fprintf(stderr, "%s\n", puffer);
- if (strlen(NONULL(config->emergency))){
-- snprintf(puffer,4096,"echo '%s' | %s -s 'P3Scan Terminating!' %s", config->emergency, config->mail, config->emergcon);
-- do_log(LOG_DEBUG,"echo '%s' | %s -s 'P3Scan Terminating!' %s", config->emergency, config->mail, config->emergcon);
-+ snprintf(puffer,4096,"echo \"%s\" | %s -s 'P3Scan Terminating' %s", config->emergency, config->mail, config->emergcon);
-+ do_log(LOG_DEBUG,"echo \"%s\" | %s -s 'P3Scan Terminating' %s", config->emergency, config->mail, config->emergcon);
- if (system(puffer)) fprintf(stderr,"ERR: Calling do_log!");
- }
- /* Tell main p3scan to abort */
-@@ -1640,8 +1641,9 @@
- }
- } else {
- if (htonl(INADDR_ANY) == config->targetaddr.sin_addr.s_addr) {
-- if (getsockopt(p->client_fd, SOL_IP, SO_ORIGINAL_DST, &p->server_addr, &p->socksize)){
-- do_log(LOG_CRIT, "ERR: No IP-Conntrack-data (getsockopt failed)");
-+ // if (getsockopt(p->client_fd, SOL_IP, SO_ORIGINAL_DST, &p->server_addr, &p->socksize)){
-+ // do_log(LOG_CRIT, "ERR: No IP-Conntrack-data (getsockopt failed)");
-+ if (getsockname(p->client_fd, (struct sockaddr*)&p->server_addr, &p->socksize)){
- return 1;
- }
- /* try to avoid loop */
-@@ -2882,7 +2884,7 @@
- char * responsemsg;
- int virusdirlen=0;
- char chownit[100];
--#define CHOWNCMD "/bin/chown"
-+#define CHOWNCMD "/usr/sbin/chown"
- int len=0;
- int ret=0;
- FILE * chowncmd;
-@@ -2920,7 +2922,8 @@
- fclose(fp);
- }else do_log(LOG_CRIT, "ERR: Can't write PID to %s", PID_FILE);
- len=strlen(CHOWNCMD)+1+strlen(config->runasuser)+1+strlen(config->runasuser)+1+strlen(config->pidfile)+1;
-- snprintf(chownit, len, "%s %s:%s %s", CHOWNCMD, config->runasuser, config->runasuser, config->pidfile);
-+ do_log(LOG_DEBUG, "%s %s:%s %s=%i",CHOWNCMD, config->runasuser, config->runasuser, config->pidfile, len);
-+ snprintf(chownit, len, "%s %s:%s %s", CHOWNCMD, config->runasuser, config->runasuser, config->pidfile);
- if ((chowncmd=popen(chownit, "r"))==NULL){
- do_log(LOG_ALERT, "ERR: Can't '%s' !!!", chowncmd);
- return SCANNER_RET_ERR;
diff --git a/mail/p3scan/files/patch-p3scan.conf b/mail/p3scan/files/patch-p3scan.conf
deleted file mode 100644
index 949f2b97802..00000000000
--- a/mail/p3scan/files/patch-p3scan.conf
+++ /dev/null
@@ -1,10 +0,0 @@
---- p3scan.conf.orig Wed Nov 1 12:15:38 2006
-+++ p3scan.conf Wed Nov 1 12:15:53 2006
-@@ -130,6 +130,7 @@
- # default: mail
- #
- # user = mail
-+user = mailnull
-
- #
- # Notify Directory
diff --git a/mail/p3scan/files/patch-p3scan.h b/mail/p3scan/files/patch-p3scan.h
deleted file mode 100644
index 75275b9c873..00000000000
--- a/mail/p3scan/files/patch-p3scan.h
+++ /dev/null
@@ -1,30 +0,0 @@
---- p3scan.h.orig Mon May 1 00:33:38 2006
-+++ p3scan.h Mon May 1 00:36:01 2006
-@@ -110,21 +110,21 @@
- #define VIRUS_SCANNER_VIRUSCODE 1
- #define PID_FILE "/var/run/p3scan/p3scan.pid"
- #define SYSLOG_NAME "p3scan"
--#define CONFIGFILE "/etc/p3scan/p3scan.conf"
--#define VIRUS_TEMPLATE "/etc/p3scan/p3scan.mail"
-+#define CONFIGFILE "/usr/local/etc/p3scan/p3scan.conf"
-+#define VIRUS_TEMPLATE "/usr/local/etc/p3scan/p3scan.mail"
- #define DEBUG 0
- #define QUIET 0
- #define OVERWRITE NULL
- #define CHECKSPAM 0
--#define SPAMCHECK "/usr/bin/spamc"
-+#define SPAMCHECK "/usr/local/bin/spamc"
- #define MINSPACE 10000
- #define DELIT 0
- #define SUBJECT "[Virus] found in a mail to you:"
- #define NOTIFY "Per instruction, the message has been deleted."
- #define SMTPRSET "Virus detected! P3scan rejected message!"
--#define XMAIL "/bin/mail"
--#define FOOTER "/etc/p3scan/p3scan.footer"
--#define EXTRA "/etc/p3scan/p3scan.extra"
-+#define XMAIL "/usr/bin/mail"
-+#define FOOTER "/usr/local/etc/p3scan/p3scan.footer"
-+#define EXTRA "/usr/local/etc/p3scan/p3scan.extra"
- #define EMERGCON "root@localhost postmaster@localhost"
- /* Defaut maximum mail size for scanning. ZERO for no limit! */
- #define MAX_SIZE_SCAN 0
diff --git a/mail/p3scan/files/patch-parsefile.c b/mail/p3scan/files/patch-parsefile.c
deleted file mode 100644
index 04ba68728c4..00000000000
--- a/mail/p3scan/files/patch-parsefile.c
+++ /dev/null
@@ -1,14 +0,0 @@
---- parsefile.c.orig Mon May 1 00:37:13 2006
-+++ parsefile.c Mon May 1 00:37:47 2006
-@@ -69,9 +69,10 @@
- #include <stdio.h>
- #include <stdlib.h>
- #include <fcntl.h>
--#include <malloc.h>
-+#include <stdlib.h>
- #include <string.h>
- #include <sys/stat.h>
-+#include <netinet/in.h>
- #include "parsefile.h"
- #include "getlinep3.h"
- #include "p3scan.h"
diff --git a/mail/p3scan/files/patch-ripmime__build_ripOLE b/mail/p3scan/files/patch-ripmime__build_ripOLE
deleted file mode 100644
index 5389503a6ae..00000000000
--- a/mail/p3scan/files/patch-ripmime__build_ripOLE
+++ /dev/null
@@ -1,9 +0,0 @@
---- ripmime/build_ripOLE.orig Wed Jan 5 20:53:04 2005
-+++ ripmime/build_ripOLE Tue Jul 26 12:48:42 2005
-@@ -1,4 +1,4 @@
- #!/bin/sh
- cd ripOLE
--make clean
--make
-+${GMAKE} clean
-+${GMAKE}
diff --git a/mail/p3scan/files/patch-ripmime__build_tnef b/mail/p3scan/files/patch-ripmime__build_tnef
deleted file mode 100644
index 103d4235fe6..00000000000
--- a/mail/p3scan/files/patch-ripmime__build_tnef
+++ /dev/null
@@ -1,7 +0,0 @@
---- ripmime/build_tnef.orig Wed Jan 5 20:53:04 2005
-+++ ripmime/build_tnef Tue Jul 26 12:48:14 2005
-@@ -1,3 +1,3 @@
- #!/bin/sh
- cd tnef
--make
-+${GMAKE}
diff --git a/mail/p3scan/files/patch-ripmime__tnef__Makefile b/mail/p3scan/files/patch-ripmime__tnef__Makefile
deleted file mode 100644
index cd1d0d3800b..00000000000
--- a/mail/p3scan/files/patch-ripmime__tnef__Makefile
+++ /dev/null
@@ -1,13 +0,0 @@
---- ripmime/tnef/Makefile.orig Tue Jul 26 14:31:25 2005
-+++ ripmime/tnef/Makefile Tue Jul 26 14:32:30 2005
-@@ -4,8 +4,8 @@
- # The main definitions are for 32/16 bits and for byte order, the
- # default is big endian. You can do -D__TNEF_BYTE_ORDER 1234 for little
- # endian
--PLATFORM=-D___TNEF_BYTE_ORDER=4321
--CFLAGS=-Wall -g -O2 -I.
-+PLATFORM=-D___TNEF_BYTE_ORDER=_BYTE_ORDER -include /usr/include/machine/endian.h
-+CFLAGS+=-Wall -g -O2 -I.
-
- default: config.h tnef.h tnef.c
- $(CC) $(CFLAGS) $(PLATFORM) -c tnef.c
diff --git a/mail/p3scan/files/patch-scanner_avpd.c b/mail/p3scan/files/patch-scanner_avpd.c
deleted file mode 100644
index 3069fedbdb4..00000000000
--- a/mail/p3scan/files/patch-scanner_avpd.c
+++ /dev/null
@@ -1,16 +0,0 @@
---- scanner_avpd.c.orig Wed Jan 5 20:53:04 2005
-+++ scanner_avpd.c Tue Jul 26 12:44:34 2005
-@@ -39,12 +39,12 @@
- #include <time.h>
- #include <sys/time.h>
- #include <errno.h>
--#include <malloc.h>
- #include <sys/un.h>
- #include <sys/socket.h>
- #include <stdarg.h>
- #include <dirent.h>
- #include <ctype.h>
-+#include <netinet/in.h>
-
- #include "p3scan.h"
-
diff --git a/mail/p3scan/files/patch-scanner_avpd_new.c b/mail/p3scan/files/patch-scanner_avpd_new.c
deleted file mode 100644
index 2e450b399c2..00000000000
--- a/mail/p3scan/files/patch-scanner_avpd_new.c
+++ /dev/null
@@ -1,18 +0,0 @@
---- scanner_avpd_new.c.orig Mon May 1 00:52:11 2006
-+++ scanner_avpd_new.c Mon May 1 00:53:46 2006
-@@ -44,7 +44,6 @@
- #include <time.h>
- #include <sys/time.h>
- #include <errno.h>
--#include <malloc.h>
- #include <sys/un.h>
- #include <sys/socket.h>
- #include <stdarg.h>
-@@ -52,6 +51,7 @@
- #include <ctype.h>
- #include <sys/select.h>
- #include <fcntl.h>
-+#include <netinet/in.h>
-
- #include "p3scan.h"
-
diff --git a/mail/p3scan/files/patch-scanner_bash.c b/mail/p3scan/files/patch-scanner_bash.c
deleted file mode 100644
index 1fcf0928e00..00000000000
--- a/mail/p3scan/files/patch-scanner_bash.c
+++ /dev/null
@@ -1,12 +0,0 @@
---- scanner_bash.c.orig Mon May 1 00:54:39 2006
-+++ scanner_bash.c Mon May 1 00:54:55 2006
-@@ -39,8 +39,8 @@
- #include <sys/wait.h>
- #include <sys/stat.h>
- #include <errno.h>
--#include <malloc.h>
- #include <pcre.h>
-+#include <netinet/in.h>
-
- #include "p3scan.h"
- #include "parsefile.h"
diff --git a/mail/p3scan/files/patch-scanner_basic.c b/mail/p3scan/files/patch-scanner_basic.c
deleted file mode 100644
index 177c0b2d609..00000000000
--- a/mail/p3scan/files/patch-scanner_basic.c
+++ /dev/null
@@ -1,14 +0,0 @@
---- scanner_basic.c.orig Thu Jan 6 04:53:04 2005
-+++ scanner_basic.c Fri Jul 29 10:26:09 2005
-@@ -33,9 +33,10 @@
- #include <stdio.h>
- #include <string.h>
- #include <sys/wait.h>
-+#include <netinet/in.h>
- #include <sys/stat.h>
- #include <errno.h>
--#include <malloc.h>
-+#include <stdlib.h>
- #include <pcre.h>
-
- #include "p3scan.h"
diff --git a/mail/p3scan/files/patch-scanner_clamd.c b/mail/p3scan/files/patch-scanner_clamd.c
deleted file mode 100644
index e2299b3fd94..00000000000
--- a/mail/p3scan/files/patch-scanner_clamd.c
+++ /dev/null
@@ -1,38 +0,0 @@
---- scanner_clamd.c.orig Mon May 1 10:54:52 2006
-+++ scanner_clamd.c Mon May 1 10:55:00 2006
-@@ -99,7 +99,10 @@
- loc2 = tmp-config->virusscanner+1;
- len=strlen(config->virusscanner);
- config->clamdport=substr(config->virusscanner,loc2,len);
-- config->clamdserver=strndup(config->virusscanner,loc); //TODO: 6 bytes in 1 blocks are definitely lost in loss record 1 of 2
-+// config->clamdserver=strndup(config->virusscanner,loc); //TODO: 6 bytes in 1 blocks are definitely lost in loss record 1 of 2
-+config->clamdserver=malloc(loc+1);
-+config->clamdserver=strncpy(config->clamdserver, config->virusscanner, loc);
-+config->clamdserver[1] = 0;
- do_log(LOG_DEBUG, "Reset ClamdServer to: %s Port: %s",config->clamdserver, config->clamdport);
- }
- bzero(&clamd_pri, sizeof(clamd_pri));
-@@ -262,7 +265,10 @@
- char *tmp=NULL;
-
- if (strlen(NONULL(config->virusscanner))<1){
-- tmp=strndup(DEFAULT_SERVER,strlen(DEFAULT_SERVER));
-+ //tmp=strndup(DEFAULT_SERVER,strlen(DEFAULT_SERVER));
-+tmp=malloc(strlen(DEFAULT_SERVER)+1);
-+tmp=strncpy(tmp, DEFAULT_SERVER, loc);
-+config->clamdserver[1] = 0;
- strncat(tmp,":",1);
- strncat(tmp,DEFAULT_PORT,4);
- config->virusscanner=tmp;
-@@ -274,7 +280,10 @@
- loc2 = tmp-config->virusscanner+1;
- len=strlen(config->virusscanner);
- config->clamdport=substr(config->virusscanner,loc2,len);
-- config->clamdserver=strndup(config->virusscanner,loc); //TODO: 6 bytes in 1 blocks are definitely lost in loss record 1 of 2
-+ //config->clamdserver=strndup(config->virusscanner,loc); //TODO: 6 bytes in 1 blocks are definitely lost in loss record 1 of 2
-+config->clamdserver=malloc(loc+1);
-+config->clamdserver=strncpy(config->clamdserver, config->virusscanner, loc);
-+config->clamdserver[1] = 0;
- do_log(LOG_DEBUG, "Clamd init. Server: %s Port: %s",config->clamdserver, config->clamdport);
- }else{
- do_log(LOG_CRIT, "Clamd init unable to locate separator: %s",config->virusscanner);
diff --git a/mail/p3scan/files/patch-scanner_sample.c b/mail/p3scan/files/patch-scanner_sample.c
deleted file mode 100644
index f9fa827ad82..00000000000
--- a/mail/p3scan/files/patch-scanner_sample.c
+++ /dev/null
@@ -1,14 +0,0 @@
---- scanner_sample.c.orig Fri Jul 29 10:08:05 2005
-+++ scanner_sample.c Fri Jul 29 10:08:37 2005
-@@ -31,10 +31,10 @@
- */
-
- #include <stdio.h>
--#include <malloc.h>
- #include <sys/un.h>
- #include <sys/socket.h>
-
-+#include <stdlib.h>
-
- /* we need p3scan.h */
- #include "p3scan.h"
diff --git a/mail/p3scan/files/patch-scanner_trophie.c b/mail/p3scan/files/patch-scanner_trophie.c
deleted file mode 100644
index 4dc46810de7..00000000000
--- a/mail/p3scan/files/patch-scanner_trophie.c
+++ /dev/null
@@ -1,14 +0,0 @@
---- scanner_trophie.c.orig Wed Jan 5 20:53:04 2005
-+++ scanner_trophie.c Tue Jul 26 12:44:51 2005
-@@ -37,11 +37,11 @@
- #include <sys/wait.h>
- #include <sys/stat.h>
- #include <errno.h>
--#include <malloc.h>
- #include <sys/un.h>
- #include <sys/socket.h>
- #include <stdarg.h>
- #include <ctype.h>
-+#include <netinet/in.h>
-
- #include "p3scan.h"
diff --git a/mail/p3scan/files/pkg-message.in b/mail/p3scan/files/pkg-message.in
deleted file mode 100644
index 928d45e4de5..00000000000
--- a/mail/p3scan/files/pkg-message.in
+++ /dev/null
@@ -1,23 +0,0 @@
-**********************************************************************
-
-By default, P3Scan is configured to work with McAfee UVSCAN.
-Please copy %%PREFIX%%/etc/p3scan/p3scan.conf.sample to p3scan.conf and modify
-%%PREFIX%%/etc/p3scan/p3scan.conf and/or %%PREFIX%%/etc/rc.d/p3scan.sh to
-fit your environment.
-
-Don't forget to copy %%PREFIX%%/etc/p3scan/p3scan.mail.sample to p3scan.mail
-and edit your own template for virus notifications.
-
-By the way, you need to enable IPFIREWALL and IPFIREWALL_FORWARD options
-in kernel, and add the forwarding rule into your IPFW table,
-
-# ipfw add fwd 192.168.0.254,8110 tcp from 192.168.0.0/24 to any pop3
-
-while 192.168.0.254 is the IP of your internal interface, 8110 is the
-default port of P3scan, and 192.168.0.0/24 is the IP range of your LAN.
-
-
-Don't forget chown -R <clamavuser> /var/run/p3scan /var/spool/p3scan
-<clamavuser> must be same as in running clamd.
-
-**********************************************************************
diff --git a/mail/p3scan/pkg-descr b/mail/p3scan/pkg-descr
deleted file mode 100644
index 2c114ef0978..00000000000
--- a/mail/p3scan/pkg-descr
+++ /dev/null
@@ -1,11 +0,0 @@
-P3Scan is a transparent POP3-Proxy with virus-scanning capabilities.
-This means that all your POP3-Clients in the Network can't fetch mails
-from the internet without that P3Scan have scanned it. If a virus has
-been found the mail is replaced with a notification and the original
-(infeceted) version is stored on the harddisc. Transparent means, that
-neither the client nor any of the used POP3-servers has to be configured.
-
-This port is based on mail/pop3vscan, but the development for that
-port seems to have ceased.
-
-WWW: http://p3scan.sourceforge.net/
diff --git a/mail/p3scan/pkg-install b/mail/p3scan/pkg-install
deleted file mode 100644
index 42b1eb302f6..00000000000
--- a/mail/p3scan/pkg-install
+++ /dev/null
@@ -1,154 +0,0 @@
-#!/bin/sh
-
-chmods_done=" "
-
-ask() {
- local question default answer
-
- question=$1
- default=$2
- if [ -z "${PACKAGE_BUILDING}" ]; then
- read -p "${question} [${default}]? " answer
- fi
- if [ x${answer} = x ]; then
- answer=${default}
- fi
- echo ${answer}
-}
-
-yesno() {
- local dflt question answer
-
- question=$1
- dflt=$2
- while :; do
- answer=$(ask "${question}" "${dflt}")
- case "${answer}" in
- [Yy]*) return 0;;
- [Nn]*) return 1;;
- esac
- echo "Please answer yes or no."
- done
-}
-
-make_account() {
- local u g gcos homeopt home
-
- u=$1
- g=$2
- gcos=$3
- homeopt=${4:+"-d $4"}
-
- if pw group show "${g}" >/dev/null 2>&1; then
- echo "You already have a group \"${g}\", so I will use it."
- else
- echo "You need a group \"${g}\"."
- if which -s pw && yesno "Would you like me to create it" y; then
- pw groupadd ${g} || exit
- echo "Done."
- else
- echo "Please create it, and try again."
- if ! grep -q "^${u}:" ${PASSWD}; then
- echo "While you're at it, please create a user \"${u}\" too,"
- echo "with a default group of \"${g}\"."
- fi
- exit 1
- fi
- fi
-
- if pw user show "${u}" >/dev/null 2>&1; then
- echo "You already have a user \"${u}\", so I will use it."
- else
- echo "You need a user \"${u}\"."
- if which -s pw && yesno "Would you like me to create it" y; then
- pw useradd ${u} -g ${g} -h - ${homeopt} \
- -s ${NONEXISTENT} -c "${gcos}" || exit
- echo "Done."
- else
- echo "Please create it, and try again."
- exit 1
- fi
- fi
-
- if [ x"$homeopt" = x ]; then
- eval home=~${u}
- if [ ! -d "${home}" ]; then
- if yesno \
- "Would you like me to create ${u}'s home directory (${home})" y
- then
- (umask 77 && \
- mkdir -p ${home}) || exit
- chown -R ${u}:${g} ${home} || exit
- else
- echo "Please create it, and try again."
- exit 1
- fi
- fi
- fi
-}
-
-case $2 in
-
-POST-INSTALL)
- if which -s pw && which -s lockf; then
- :
- else
- cat <<EOF
-
-This system looks like a pre-2.2 version of FreeBSD. I see that it
-is missing the "lockf" and/or "pw" utilities. I need these utilities.
-Please get them and install them, and try again. You can get the
-sources from:
-
- ftp://ftp.freebsd.org/pub/FreeBSD/FreeBSD-current/src/usr.bin/lockf.tar.gz
- ftp://ftp.freebsd.org/pub/FreeBSD/FreeBSD-current/src/usr.sbin/pw.tar.gz
-
-EOF
- exit 1
- fi
-
- user=mailnull
- group=mail
- spooldir=/var/spool/p3scan
- childrendir=/var/spool/p3scan/children
- notifydir=/var/spool/p3scannotify
- piddir=/var/run/p3scan/
- etcdir=${PREFIX:-$PKG_PREFIX}/etc
-
- echo ""
- make_account ${user} ${group} "P3Scan Daemon" ${spooldir}
-
- if [ ! -d ${spooldir} ]; then
- echo "Creating \"${spooldir}\"."
- mkdir -p ${spooldir}
- fi
- echo "Fixing ownerships and modes in \"${spooldir}\"."
- chown -R ${user}:${group} ${spooldir}
- chmod -R go= ${spooldir}
-
- if [ ! -d ${childrendir} ]; then
- echo "Creating \"${childrendir}\"."
- mkdir -p ${childrendir}
- fi
- echo "Fixing ownerships and modes in \"${childrendir}\"."
- chown -R ${user}:${group} ${childrendir}
- chmod -R go= ${childrendir}
-
- if [ ! -d ${notifydir} ]; then
- echo "Creating \"${notifydir}\"."
- mkdir -p ${notifydir}
- fi
- echo "Fixing ownerships and modes in \"${notifydir}\"."
- chown -R ${user}:${group} ${notifydir}
- chmod -R go= ${notifydir}
-
- if [ ! -d ${piddir} ]; then
- echo "Creating \"${piddir}\"."
- mkdir -p ${piddir}
- fi
- echo "Fixing ownerships and modes in \"${piddir}\"."
- chown -R ${user}:${group} ${piddir}
- chmod -R go= ${piddir}
-
- ;;
-esac