aboutsummaryrefslogtreecommitdiffstats
path: root/security/clamav
diff options
context:
space:
mode:
authoredwin <edwin@FreeBSD.org>2003-01-20 11:41:52 +0800
committeredwin <edwin@FreeBSD.org>2003-01-20 11:41:52 +0800
commit39d0d232cb48beaf69eb7de8dc256c06cc551844 (patch)
tree6dc859f46964ea10b2464798bbcf21fde732403d /security/clamav
parente7b8f403ad7388d52de80a9b8c54b0477c4ec46e (diff)
downloadfreebsd-ports-graphics-39d0d232cb48beaf69eb7de8dc256c06cc551844.tar.gz
freebsd-ports-graphics-39d0d232cb48beaf69eb7de8dc256c06cc551844.tar.zst
freebsd-ports-graphics-39d0d232cb48beaf69eb7de8dc256c06cc551844.zip
new port: security/clamav
Clam Antivirus is command line virus scanner using database from OpenAntiVirus. PR: ports/40602 Submitted by: TERAMOTO Masahiro <markun@onohara.to>
Diffstat (limited to 'security/clamav')
-rw-r--r--security/clamav/Makefile33
-rw-r--r--security/clamav/distinfo1
-rw-r--r--security/clamav/pkg-comment1
-rw-r--r--security/clamav/pkg-descr3
-rw-r--r--security/clamav/pkg-install30
-rw-r--r--security/clamav/pkg-plist5
6 files changed, 73 insertions, 0 deletions
diff --git a/security/clamav/Makefile b/security/clamav/Makefile
new file mode 100644
index 00000000000..0a49f0bd745
--- /dev/null
+++ b/security/clamav/Makefile
@@ -0,0 +1,33 @@
+# New ports collection makefile for: clamav
+# Date created: 15 July 2002
+# Whom: markun@onohara.to
+#
+# $FreeBSD$
+#
+
+PORTNAME= clamav
+PORTVERSION= 0.20
+CATEGORIES= security
+MASTER_SITES= http://clamav.elektrapro.com/stable/
+
+MAINTAINER= markun@onohara.to
+
+RUN_DEPENDS= lha:${PORTSDIR}/archivers/lha \
+ unarj:${PORTSDIR}/archivers/unarj \
+ unrar:${PORTSDIR}/archivers/unrar \
+ zoo:${PORTSDIR}/archivers/zoo \
+ arc:${PORTSDIR}/archivers/arc \
+ unzip:${PORTSDIR}/archivers/unzip
+
+USE_GMAKE= yes
+HAS_CONFIGURE= yes
+
+CONFIGURE_ARGS= --prefix=${PREFIX} --disable-clamav --disable-pthreads
+
+MAN1= clamscan.1 freshclam.1 sigtool.1
+
+pre-install:
+ @${ECHO} "==> Creating custom user to run clamav..."
+ ${SH} ${PKGINSTALL} ${PKGNAME} PRE-INSTALL
+
+.include <bsd.port.mk>
diff --git a/security/clamav/distinfo b/security/clamav/distinfo
new file mode 100644
index 00000000000..95bc892bb3c
--- /dev/null
+++ b/security/clamav/distinfo
@@ -0,0 +1 @@
+MD5 (clamav-0.20.tar.gz) = db747de22829b2d03baeb04d659d3d5b
diff --git a/security/clamav/pkg-comment b/security/clamav/pkg-comment
new file mode 100644
index 00000000000..0350f413050
--- /dev/null
+++ b/security/clamav/pkg-comment
@@ -0,0 +1 @@
+Command line virus scanner using database from OpenAntiVirus
diff --git a/security/clamav/pkg-descr b/security/clamav/pkg-descr
new file mode 100644
index 00000000000..45535e0c7d2
--- /dev/null
+++ b/security/clamav/pkg-descr
@@ -0,0 +1,3 @@
+Clam Antivirus is command line virus scanner using database from
+OpenAntiVirus. It detects over 1700 viruses, scans compressed files
+and supported by AMaViS.
diff --git a/security/clamav/pkg-install b/security/clamav/pkg-install
new file mode 100644
index 00000000000..448ffdc1f34
--- /dev/null
+++ b/security/clamav/pkg-install
@@ -0,0 +1,30 @@
+#!/bin/sh
+
+if [ "$2" != "PRE-INSTALL" ]; then
+ exit 0
+fi
+
+USER=clamav
+GROUP=clamav
+
+if ! pw groupshow "$GROUP" 2>/dev/null 1>&2; then
+ if pw groupadd $GROUP; then
+ echo "=> Added group \"$GROUP\"."
+ else
+ echo "=> Adding group \"$GROUP\" failed..."
+ exit 1
+ fi
+fi
+
+if ! pw usershow "$USER" 2>/dev/null 1>&2; then
+ if pw useradd $USER -g $GROUP -h - \
+ -s "/sbin/nologin" -d "/nonexistent" \
+ -c "Clam Antivirus"; \
+ then
+ echo "=> Added user \"$USER\"."
+ else
+ echo "=> Adding user \"$USER\" failed..."
+ exit 1
+ fi
+fi
+exit 0
diff --git a/security/clamav/pkg-plist b/security/clamav/pkg-plist
new file mode 100644
index 00000000000..2ea04388536
--- /dev/null
+++ b/security/clamav/pkg-plist
@@ -0,0 +1,5 @@
+bin/clamscan
+bin/freshclam
+bin/sigtool
+share/clamav/viruses.db
+@dirrm share/clamav