Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 24 May 2007 13:29:24 +0200
From:      Robin Gruyters <r.gruyters@yirdis.nl>
To:        FreeBSD-gnats-submit@FreeBSD.org, freebsd-ports-bugs@FreeBSD.org
Subject:   Re: ports/112416: [MAINTAINER] security/prelude-manager: update to 0.9.8
Message-ID:  <20070524132924.reeuexneasgoggo0@server.yirdis.nl>
In-Reply-To: <200705041240.l44Ce9Zi097013@freefall.freebsd.org>
References:  <200705041240.l44Ce9Zi097013@freefall.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
This message is in MIME format and has been PGP signed.

--=_5gmbx4fo2qkg
Content-Type: multipart/mixed;
	boundary="=_74yrfpzinbc4"
Content-Transfer-Encoding: 7bit

This message is in MIME format.

--=_74yrfpzinbc4
Content-Type: text/plain;
	charset=ISO-8859-1;
	DelSp="Yes";
	format="flowed"
Content-Disposition: inline
Content-Transfer-Encoding: 7bit

Oops, fix small issue. I have included an updated patch.

Kind regards,

Robin Gruyters
Network and Security Engineer
Yirdis B.V.
I: http://yirdis.com
P: +31 (0)36 5300394
F: +31 (0)36 5489119



--=_74yrfpzinbc4
Content-Type: text/plain;
	charset=UTF-8;
	name="prelude-manager.patch"
Content-Disposition: attachment;
	filename="prelude-manager.patch"
Content-Transfer-Encoding: quoted-printable

=3D=3D=3D> Generating patch
=3D=3D=3D> Viewing diff with less
diff -ruN --exclude=3DCVS /usr/ports/security/prelude-manager/Makefile /data=
2/FreeBSD/custom_ports/security/prelude-manager/Makefile
--- /usr/ports/security/prelude-manager/Makefile=09Thu Mar 22 02:22:40 2007
+++ /data2/FreeBSD/custom_ports/security/prelude-manager/Makefile=09Thu May =
24 13:25:12 2007
@@ -5,7 +5,7 @@
 # $FreeBSD: ports/security/prelude-manager/Makefile,v 1.42 2007/03/21 07:49=
:43 clsung Exp $
=20
 PORTNAME=3D=09prelude-manager
-PORTVERSION=3D=090.9.7.2
+PORTVERSION=3D=090.9.8
 CATEGORIES=3D=09security
 MASTER_SITES=3D=09http://www.prelude-ids.org/download/releases/ \
 =09=09http://www.prelude-ids.org/download/releases/old/
@@ -13,7 +13,7 @@
 MAINTAINER=3D=09r.gruyters@yirdis.nl
 COMMENT=3D=09Prelude Network Intrusion Detection System central logging poi=
nt
=20
-LIB_DEPENDS+=3D=09prelude.11:${PORTSDIR}/security/libprelude \
+LIB_DEPENDS+=3D=09prelude.12:${PORTSDIR}/security/libprelude \
 =09=09gnutls.15:${PORTSDIR}/security/gnutls
=20
 USE_GMAKE=3D=09yes
@@ -24,8 +24,27 @@
 CONFIGURE_ARGS=3D=09=09--with-html-dir=3D${PREFIX}/share/doc \
 =09=09=09--localstatedir=3D/var
=20
+PRELUDEUSER?=3D=09prelude
+PRELUDEGROUP?=3D=09prelude
+PRELUDEDIR?=3D=09/nonexistent
+
+PRELUDEUID=3D=09281
+PRELUDEGID=3D=09${PRELUDEUID}
+
 .include <bsd.port.pre.mk>
=20
+PLIST_SUB=3D=09PRELUDEUSER=3D${PRELUDEUSER} \
+=09=09PRELUDEGROUP=3D${PRELUDEGROUP} \
+=09=09PRELUDEUID=3D${PRELUDEUID} \
+=09=09PRELUDEGID=3D${PRELUDEGID} \
+=09=09PRELUDEDIR=3D${PRELUDEDIR}
+
+SUB_FILES=3D=09pkg-install \
+=09=09pkg-deinstall
+
+SUB_LIST=3D=09PREFIX=3D${PREFIX} \
+=09=09${PLIST_SUB}
+
 .if defined(WITHOUT_XML)
 PLIST_SUB+=3D=09WITH_XML=3D"@comment "
 CONFIGURE_ARGS+=3D=09--disable-xmltest --without-xml
@@ -41,10 +60,20 @@
 PLIST_SUB+=3D=09WITH_PRELUDEDB=3D""
 .endif
=20
+pre-install:
+=09@${SH} ${PKGINSTALL} ${DISTNAME} PRE-INSTALL
+
 post-install:
 =09@if [ ! -f ${PREFIX}/etc/prelude-manager/prelude-manager.conf ]; then \
 =09   ${CP} -p ${PREFIX}/etc/prelude-manager/prelude-manager.conf-dist \
 =09      ${PREFIX}/etc/prelude-manager/prelude-manager.conf ; \
 =09fi
+
+=09@${CHMOD} 700 /var/spool/${PORTNAME} \
+=09   /var/spool/${PORTNAME}/failover \
+=09   /var/spool/${PORTNAME}/scheduler
+=09@${CHOWN} ${PRELUDEUSER}:${PRELUDEGROUP} /var/run/${PORTNAME} \
+=09   /var/spool/${PORTNAME} /var/spool/${PORTNAME}/failover \
+=09   /var/spool/${PORTNAME}/scheduler
=20
 .include <bsd.port.post.mk>
diff -ruN --exclude=3DCVS /usr/ports/security/prelude-manager/distinfo /data=
2/FreeBSD/custom_ports/security/prelude-manager/distinfo
--- /usr/ports/security/prelude-manager/distinfo=09Thu Mar 22 02:22:40 2007
+++ /data2/FreeBSD/custom_ports/security/prelude-manager/distinfo=09Fri May =
 4 13:49:38 2007
@@ -1,3 +1,3 @@
-MD5 (prelude-manager-0.9.7.2.tar.gz) =3D 7f32b6fb176d9f91d98f341928e0802e
-SHA256 (prelude-manager-0.9.7.2.tar.gz) =3D eed9903beb569b36ab46e81e8cc51eb=
dcf7a05322bafa456ee76da8f0ef369e7
-SIZE (prelude-manager-0.9.7.2.tar.gz) =3D 596874
+MD5 (prelude-manager-0.9.8.tar.gz) =3D be73ee46a7279200c5b9fcc4a2f9b7ad
+SHA256 (prelude-manager-0.9.8.tar.gz) =3D c5a41ba98ff05d4c75f237e7e8c01efb8=
c086362b0713736d4d3451a1c023f15
+SIZE (prelude-manager-0.9.8.tar.gz) =3D 617261
diff -ruN --exclude=3DCVS /usr/ports/security/prelude-manager/files/pkg-dein=
stall.in /data2/FreeBSD/custom_ports/security/prelude-manager/files/pkg-dein=
stall.in
--- /usr/ports/security/prelude-manager/files/pkg-deinstall.in=09Thu Jan  1 =
01:00:00 1970
+++ /data2/FreeBSD/custom_ports/security/prelude-manager/files/pkg-deinstall=
.in=09Thu May 24 13:02:22 2007
@@ -0,0 +1,22 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+PRELUDEDIR=3D%%PRELUDEDIR%%
+PRELUDEUSER=3D%%PRELUDEUSER%%
+PRELUDEGROUP=3D%%PRELUDEGROUP%%
+
+if [ "$2" =3D "POST-DEINSTALL" ]; then
+  if /usr/sbin/pw group show "${PRELUDEGROUP}" 2>&1 >/dev/null; then
+    echo "You should manually remove the \"${PRELUDEGROUP}\" group."
+  fi
+
+  if /usr/sbin/pw user show "${PRELUDEUSER}" 2>&1 >/dev/null; then
+    echo "You should manually remove the \"${PRELUDEUSER}\" user."
+  fi
+
+  if [ -e "${PRELUDEDIR}" ]; then
+    echo "You should manually remove the \"${PRELUDEDIR}\" directory."
+  fi
+fi
diff -ruN --exclude=3DCVS /usr/ports/security/prelude-manager/files/pkg-inst=
all.in /data2/FreeBSD/custom_ports/security/prelude-manager/files/pkg-instal=
l.in
--- /usr/ports/security/prelude-manager/files/pkg-install.in=09Thu Jan  1 01=
:00:00 1970
+++ /data2/FreeBSD/custom_ports/security/prelude-manager/files/pkg-install.i=
n=09Thu May 24 13:06:00 2007
@@ -0,0 +1,74 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+PRELUDEDIR=3D%%PRELUDEDIR%%
+PRELUDEUSER=3D%%PRELUDEUSER%%
+PRELUDEGROUP=3D%%PRELUDEGROUP%%
+PRELUDEUID=3D%%PRELUDEUID%%
+PRELUDEGID=3D%%PRELUDEGID%%
+
+ask() {
+  local question default answer
+
+  question=3D$1
+  default=3D$2
+  if [ -z "${PACKAGE_BUILDING}" ]; then
+    read -p "${question} [${default}]? " answer
+  fi
+  if [ "x${answer}" =3D "x" ]; then
+    answer=3D${default}
+  fi
+  echo ${answer}
+}
+
+yesno() {
+  local default question answer
+
+  question=3D$1
+  default=3D$2
+  while :; do
+    answer=3D$(ask "${question}" "${default}")
+    case "${answer}" in
+      [Yy][Ee][Ss]|[Yy])
+        return 0
+        ;;
+      [Nn][Oo]|[Nn])
+        return 1
+        ;;
+    esac
+    echo "Please answer yes or no."
+   done
+}
+
+if [ "$2" =3D "PRE-INSTALL" ]; then
+  if /usr/sbin/pw group show "${PRELUDEGROUP}" 2>&1 >/dev/null; then
+    echo "You already have a \"${PRELUDEGROUP}\" group, so I will use it."
+  else
+    echo "You need a \"${PRELUDEGROUP}\" group."
+    if yesno "Would you like me to create it" "YES"; then
+      /usr/sbin/pw groupadd "${PRELUDEGROUP}" -g "${PRELUDEGID}" -h - || \
+        /usr/sbin/pw groupadd "${PRELUDEGROUP}" -h - || exit
+      echo "Done."
+    else
+      echo "Please create the \"${PRELUDEGROUP}\" group manually and try ag=
ain."
+      exit 1
+    fi
+  fi
+
+  if /usr/sbin/pw user show "${PRELUDEUSER}" 2>&1 >/dev/null; then
+    echo "You already have a \"${PRELUDEUSER}\" user, so I will use it."
+  else
+    echo "You need a \"${PRELUDEUSER}\" user."
+    if yesno "Would you like me to create it" "YES"; then
+      /usr/sbin/pw useradd "${PRELUDEUSER}" -u "${PRELUDEUID}" -g "${PRELUD=
EGROUP}" -h - -d "${PRELUDEDIR}" \
+        -s /sbin/nologin -c "Prelude pseudo-user" || \
+        /usr/sbin/pw useradd "${PRELUDEUSER}" -g "${PRELUDEGROUP}" -h - -d =
"${PRELUDEDIR}" \
+        -s /sbin/nologin -c "Prelude pseudo-user" || exit
+    else
+      echo "Please create the \"${PRELUDEUSER}\" user manually and try agai=
n."
+      exit 1
+    fi
+  fi
+fi
diff -ruN --exclude=3DCVS /usr/ports/security/prelude-manager/pkg-plist /dat=
a2/FreeBSD/custom_ports/security/prelude-manager/pkg-plist
--- /usr/ports/security/prelude-manager/pkg-plist=09Thu Jan 18 02:22:04 2007
+++ /data2/FreeBSD/custom_ports/security/prelude-manager/pkg-plist=09Fri May=
  4 14:33:47 2007
@@ -1,4 +1,8 @@
 @comment $FreeBSD: ports/security/prelude-manager/pkg-plist,v 1.11 2007/01/=
16 19:04:22 bsam Exp $
+@exec mkdir -p /var/spool/prelude-manager/failover
+@exec mkdir -p /var/spool/prelude-manager/scheduler
+@exec chmod 700 /var/spool/prelude-manager /var/spool/prelude-manager/failo=
ver /var/spool/prelude-manager/scheduler
+@exec chown %%PRELUDEUSER%%:%%PRELUDEGROUP%% /var/run/prelude-manager /var/=
spool/prelude-manager /var/spool/prelude-manager/failover /var/spool/prelude=
-manager/scheduler
 bin/prelude-manager
 @unexec if cmp -s %D/etc/prelude-manager/prelude-manager.conf %D/etc/prelud=
e-manager/prelude-manager.conf-dist; then rm -f %D/etc/prelude-manager/prelu=
de-manager.conf; fi
 etc/prelude-manager/prelude-manager.conf-dist
@@ -6,6 +10,8 @@
 include/prelude-manager/prelude-manager.h
 lib/prelude-manager/filters/idmef-criteria.la
 lib/prelude-manager/filters/idmef-criteria.so
+lib/prelude-manager/filters/thresholding.so
+lib/prelude-manager/filters/thresholding.la
 lib/prelude-manager/decodes/normalize.so
 lib/prelude-manager/decodes/normalize.la
 %%WITH_PRELUDEDB%%lib/prelude-manager/reports/db.la
=3D=3D=3D> Done

--=_74yrfpzinbc4--

--=_5gmbx4fo2qkg
Content-Type: application/pgp-signature
Content-Description: PGP Digital Signature
Content-Disposition: inline
Content-Transfer-Encoding: 7bit

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.3 (FreeBSD)

iD8DBQBGVXcULh3hlgHmc7MRAoFSAJ4+b2RpD1KpSjfTgh+Kon+UUYheZACg2g34
NuXE9Vzrbs7WZon6mzlobgs=
=+5AY
-----END PGP SIGNATURE-----

--=_5gmbx4fo2qkg--



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