aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Wilke <miwi@FreeBSD.org>2012-06-10 09:57:43 +0000
committerMartin Wilke <miwi@FreeBSD.org>2012-06-10 09:57:43 +0000
commit49dfe510bf7d0be79c97e4f7e6ae2cd907aa30bb (patch)
tree7739d23acc9795141403dbc16e7d112d4e4bfe22
parent8d8cf5eab81eca912cf2ead41e1220532dc4477b (diff)
downloadports-49dfe510bf7d0be79c97e4f7e6ae2cd907aa30bb.tar.gz
ports-49dfe510bf7d0be79c97e4f7e6ae2cd907aa30bb.zip
MUNGE (MUNGE Uid 'N' Gid Emporium) is an authentication service for creating and
validating credentials. It is designed to be highly scalable for use in an HPC cluster environment. It allows a process to authenticate the UID and GID of another local or remote process within a group of hosts having common users and groups. These hosts form a security realm that is defined by a shared cryptographic key. Clients within this security realm can create and validate credentials without the use of root privileges, reserved ports, or platform-specific methods. WWW: http://code.google.com/p/munge/ PR: ports/166386 Submitted by: Muhammad Moinur Rahman <5u623l20@gmail.com>
Notes
Notes: svn path=/head/; revision=298922
-rw-r--r--security/Makefile1
-rw-r--r--security/munge/Makefile43
-rw-r--r--security/munge/distinfo2
-rw-r--r--security/munge/files/munged.in45
-rw-r--r--security/munge/files/patch-configure11
-rw-r--r--security/munge/files/patch-src-etc-Makefile.in28
-rw-r--r--security/munge/pkg-descr10
-rw-r--r--security/munge/pkg-plist14
8 files changed, 154 insertions, 0 deletions
diff --git a/security/Makefile b/security/Makefile
index 5239c94010a5..0a00115cdffc 100644
--- a/security/Makefile
+++ b/security/Makefile
@@ -309,6 +309,7 @@
SUBDIR += mindterm-binary
SUBDIR += monkeysphere
SUBDIR += mosref
+ SUBDIR += munge
SUBDIR += mussh
SUBDIR += nacl
SUBDIR += nbaudit
diff --git a/security/munge/Makefile b/security/munge/Makefile
new file mode 100644
index 000000000000..ba970607f240
--- /dev/null
+++ b/security/munge/Makefile
@@ -0,0 +1,43 @@
+# New ports collection makefile for: munge
+# Date created: 2012-03-18
+# Whom: Muhammad Moinur Rahman <5u623l20@gmail.com>
+#
+# $FreeBSD$
+#
+
+PORTNAME= munge
+PORTVERSION= 0.5.10
+CATEGORIES= security
+MASTER_SITES= GOOGLE_CODE
+
+MAINTAINER= 5u623l20@gmail.com
+COMMENT= An authentication service for creating and validating credentials
+
+USE_BZIP2= yes
+GNU_CONFIGURE= yes
+USE_PERL5= yes
+USE_LDCONFIG= yes
+USE_RC_SUBR= munged
+
+MAN1= unmunge.1 \
+ munge.1 \
+ remunge.1
+MAN3= munge.3 \
+ munge_ctx_copy.3 \
+ munge_ctx_get.3 \
+ munge_ctx.3 \
+ munge_enum_int_to_str.3 \
+ munge_enum_is_valid.3 \
+ munge_enum_str_to_int.3 \
+ munge_enum.3
+MAN7= munge.7
+MAN8= munged.8
+MLINKS= munge.3 munge_strerror.3 \
+ munge.3 munge_encode.3 \
+ munge.3 munge_decode.3 \
+ munge_ctx.3 munge_ctx_create.3 \
+ munge_ctx.3 munge_ctx_destroy.3 \
+ munge_ctx.3 munge_ctx_set.3 \
+ munge_ctx.3 munge_ctx_strerror.3
+
+.include <bsd.port.mk>
diff --git a/security/munge/distinfo b/security/munge/distinfo
new file mode 100644
index 000000000000..1bf23891b683
--- /dev/null
+++ b/security/munge/distinfo
@@ -0,0 +1,2 @@
+SHA256 (munge-0.5.10.tar.bz2) = 00e0125c2895877b555872647b0a98d13838a54acda78614bb6c6e70daadabc6
+SIZE (munge-0.5.10.tar.bz2) = 424285
diff --git a/security/munge/files/munged.in b/security/munge/files/munged.in
new file mode 100644
index 000000000000..f97dc836d738
--- /dev/null
+++ b/security/munge/files/munged.in
@@ -0,0 +1,45 @@
+#!/bin/sh
+#
+#
+
+# PROVIDE: munged
+# REQUIRE: LOGIN
+# KEYWORD: shutdown
+
+#
+# Add the following line to /etc/rc.conf to enable mysql:
+# munged_enable (bool): Set to "NO" by default.
+# Set it to "YES" to enable munged.
+# munged_keyfile (str): Default to "/usr/local/etc/munge/munge.key"
+# Default munge key.
+# munged_pidfile (str): Custum PID file path and name.
+# Default to "/var/run/munged.pid".
+#
+
+. /etc/rc.subr
+
+name="munged"
+rcvar=munged_enable
+stop_cmd="munged_stop"
+
+load_rc_config $name
+
+: ${munged_enable="NO"}
+
+munged_user=root
+munged_keyfile="%%PREFIX%%/etc/munge/munge.key"
+pidfile="/var/run/munge/${name}.pid"
+command="%%PREFIX%%/sbin/${name}"
+command_args="--key-file=${munged_keyfile}"
+
+munged_stop()
+{
+ if [ -f "${pidfile}" ]; then
+ kill -9 `cat ${pidfile}`
+ sleep 1 # wait a little bit
+ rm -f /var/run/munge/*
+ fi
+
+}
+
+run_rc_command "$1"
diff --git a/security/munge/files/patch-configure b/security/munge/files/patch-configure
new file mode 100644
index 000000000000..32d4ea989d57
--- /dev/null
+++ b/security/munge/files/patch-configure
@@ -0,0 +1,11 @@
+--- configure.orig 2012-03-18 03:31:24.960241537 +0600
++++ configure 2012-03-18 03:31:41.879241019 +0600
+@@ -952,7 +952,7 @@
+ datadir='${datarootdir}'
+ sysconfdir='${prefix}/etc'
+ sharedstatedir='${prefix}/com'
+-localstatedir='${prefix}/var'
++localstatedir='/var'
+ includedir='${prefix}/include'
+ oldincludedir='/usr/include'
+ docdir='${datarootdir}/doc/${PACKAGE}'
diff --git a/security/munge/files/patch-src-etc-Makefile.in b/security/munge/files/patch-src-etc-Makefile.in
new file mode 100644
index 000000000000..007259942f9f
--- /dev/null
+++ b/security/munge/files/patch-src-etc-Makefile.in
@@ -0,0 +1,28 @@
+--- src/etc/Makefile.in.orig 2012-03-24 23:11:13.000000000 +0600
++++ src/etc/Makefile.in 2012-03-24 23:14:23.000000000 +0600
+@@ -431,24 +431,7 @@
+ -rm -f *~ \#* .\#* cscope*.out core core.* tags TAGS
+
+ install-data-local:
+- expr "`id`" : 'uid=0(' >/dev/null && OWNER="-o daemon" || OWNER=""; \
+- $(INSTALL) -m 0755 -d "$(DESTDIR)$(sysconfdir)/init.d"; \
+- new=""; test ! -f "$(DESTDIR)$(sysconfdir)/init.d/munge" \
+- || cmp "$(builddir)/munge.init" \
+- "$(DESTDIR)$(sysconfdir)/init.d/munge" \
+- 1>/dev/null 2>&1 || new=".new"; \
+- $(INSTALL) -m 0755 "$(builddir)/munge.init" \
+- "$(DESTDIR)$(sysconfdir)/init.d/munge$${new}"; \
+- test -d "/etc/sysconfig" && d="sysconfig" || d="default"; \
+- new=""; test ! -f "$(DESTDIR)$(sysconfdir)/$${d}/munge" \
+- || cmp "$(srcdir)/munge.sysconfig" \
+- "$(DESTDIR)$(sysconfdir)/$${d}/munge" \
+- 1>/dev/null 2>&1 || new=".new"; \
+- $(INSTALL) -m 0755 -d "$(DESTDIR)$(sysconfdir)/$${d}"; \
+- $(INSTALL) -m 0644 "$(srcdir)/munge.sysconfig" \
+- "$(DESTDIR)$(sysconfdir)/$${d}/munge$${new}"; \
+- $(INSTALL) $${OWNER} -m 0700 -d \
+- "$(DESTDIR)$(sysconfdir)/munge"; \
++ expr "`id`" : 'uid=0(' >/dev/null && OWNER="-o root" || OWNER=""; \
+ $(INSTALL) -m 0711 -d "$(DESTDIR)$(localstatedir)/lib"; \
+ $(INSTALL) $${OWNER} -m 0711 -d \
+ "$(DESTDIR)$(localstatedir)/lib/munge"; \
diff --git a/security/munge/pkg-descr b/security/munge/pkg-descr
new file mode 100644
index 000000000000..49f414001165
--- /dev/null
+++ b/security/munge/pkg-descr
@@ -0,0 +1,10 @@
+MUNGE (MUNGE Uid 'N' Gid Emporium) is an authentication service for creating and
+validating credentials. It is designed to be highly scalable for use in an HPC
+cluster environment. It allows a process to authenticate the UID and GID of
+another local or remote process within a group of hosts having common users and
+groups. These hosts form a security realm that is defined by a shared
+cryptographic key. Clients within this security realm can create and validate
+credentials without the use of root privileges, reserved ports, or
+platform-specific methods.
+
+WWW: http://code.google.com/p/munge/
diff --git a/security/munge/pkg-plist b/security/munge/pkg-plist
new file mode 100644
index 000000000000..babf9470da74
--- /dev/null
+++ b/security/munge/pkg-plist
@@ -0,0 +1,14 @@
+@stopdaemon munged
+include/munge.h
+bin/remunge
+bin/unmunge
+bin/munge
+lib/libmunge.la
+lib/libmunge.so.2
+lib/libmunge.a
+lib/libmunge.so
+sbin/munged
+@cwd /
+@exec rm /var/run/${PORTNAME}
+@exec rm /var/log/${PORTNAME}
+@exec rm /var/lib/${PORTNAME}