summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--net-im/ejabberd/ChangeLog15
-rw-r--r--net-im/ejabberd/Manifest19
-rw-r--r--net-im/ejabberd/ejabberd-2.1.3.ebuild213
-rw-r--r--net-im/ejabberd/files/ejabberd-3.confd5
-rw-r--r--net-im/ejabberd/files/ejabberd-3.initd22
-rw-r--r--net-im/ejabberd/metadata.xml16
6 files changed, 269 insertions, 21 deletions
diff --git a/net-im/ejabberd/ChangeLog b/net-im/ejabberd/ChangeLog
index b41624e9c01a..e9fe086e96d8 100644
--- a/net-im/ejabberd/ChangeLog
+++ b/net-im/ejabberd/ChangeLog
@@ -1,6 +1,17 @@
# ChangeLog for net-im/ejabberd
-# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-im/ejabberd/ChangeLog,v 1.69 2009/12/30 11:35:42 fauli Exp $
+# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/net-im/ejabberd/ChangeLog,v 1.70 2010/05/26 20:25:25 pva Exp $
+
+*ejabberd-2.1.3 (26 May 2010)
+
+ 26 May 2010; Peter Volkov <pva@gentoo.org> +files/2.1.1-mod_statsdx.patch,
+ +ejabberd-2.1.3.ebuild, +files/ejabberd-3.confd, +files/ejabberd-3.initd:
+ Version bump, #281366 thank Vadim Efimov for report and jamatik for
+ preliminary testing (that helped greately)! Fixes conflict with GSecurity
+ TPE bug 202616, thank Andrian Nord for report. Init script rewriten, fixes
+ bugs #210234, #279613 and #306593, thank Luca Barbato, Roy Marples,
+ Luke-Jr and Livid. Fixed ssl related build issue, bug 288414 by Michał
+ Masłowski. Fixes DoS, security bug 308047, thank Stefan Behte for report.
30 Dec 2009; Christian Faulhammer <fauli@gentoo.org>
-files/1.1.4-missing-declaration.patch, -ejabberd-1.1.4-r1.ebuild,
diff --git a/net-im/ejabberd/Manifest b/net-im/ejabberd/Manifest
index fd2f39877618..11d45fb1cb5b 100644
--- a/net-im/ejabberd/Manifest
+++ b/net-im/ejabberd/Manifest
@@ -1,21 +1,16 @@
------BEGIN PGP SIGNED MESSAGE-----
-Hash: SHA1
-
AUX ejabberd-2.0.5-erlang-13.patch 16877 RMD160 4b8924f5b37de85823dec539523e7800c394bc7c SHA1 663ffc03f29613d695589c199222bc0382a24c76 SHA256 3d5cb7c163647580e1776a4e31ca3f8e03b1b411288b8273c861d17db5fa1e4a
AUX ejabberd-2.confd 834 RMD160 7beb5337d15b33d4b1d802edb03995cddb73e162 SHA1 53e754dcbd03edb27f9982f51323e355dafd1f73 SHA256 c48f5cb90c409bde333d5d7a6159995bbf02e265c9d06528c1ec35b764ca9f21
AUX ejabberd-2.initd 1126 RMD160 8c696768e686efdc9865446ce5a3fbb2ae7302f6 SHA1 27c6b2fd8e1ff6b74d83688d9d68e8721aa0580e SHA256 9b6f076c452a8db149b689db12082fade95e1975a76e52a67a942220ee99aa2f
+AUX ejabberd-3.confd 161 RMD160 3b2c2b2a871c42c75e854a3c592c0d399a5dd387 SHA1 01e72bda178e7bf26a66321c4330bbcc1607e540 SHA256 0296d3d281a321cd7380772c1d89a94e4a86f85b7f43bf9dc1af74935c2e6386
+AUX ejabberd-3.initd 466 RMD160 278c0d7962540aa630e879803957551201e2ce0c SHA1 f81b2ae57bb45c0fac566e2d57f16a60c977871c SHA256 19fdfeecc402bd0d3144fb7e422594822c77eeb6a844183e99264d2aacf46d79
AUX ejabberd-wrapper-2.template 1243 RMD160 989700850578dd86fe6cefeb465a1c84ba49df48 SHA1 115d10f04dd92ca090e853013dde3e5ffa3d6904 SHA256 1d3abfbb1b4dd79ba9fed74a5c86c97af70dc11927d8fa109a1486999d5f7a96
AUX ejabberdctl-wrapper-3.template 908 RMD160 c5378d8e089ae1c180b7be76639a99d5cad16f11 SHA1 4ee6996c492360c4e44a05e011fb228eecff56b9 SHA256 c3c377ae8b00143e21ab4ccff7cffe539f6a6b95336aa5636cb8d6bba49c9592
AUX self-cert-v2.sh 1017 RMD160 3beb0f05e8cc3041abd2f689d31d410bc7d5088d SHA1 1f07299b2e49541dcbf5c2b81b26280bbf0b6aeb SHA256 34b2c9cb36c424ffd1117bd20b67d0f4a05168b0bc6237e287c2dcabd0e27972
AUX ssl.cnf 1042 RMD160 47d2542942fb21f4be1e827d47eb4e0468e73910 SHA1 7347bae5a195ad158881fe5313f55ee41e85cb81 SHA256 ed066f7720fd9f4c2d57ffb2ebcbc4b2810d2b7ca22b67ec8c1dc1227baaa635
+DIST 2.1.1-mod_statsdx.patch.bz2 13041 RMD160 9cc6d71ff2a2d58b0e377a3facb564d22d46af25 SHA1 4ef326eff97283530ee137613c009fe132312644 SHA256 a290217d7fd2c338d9ddba73e25ee052a3735d7168aafd24750de113f43ebc5f
DIST ejabberd-2.0.5.tar.gz 1796737 RMD160 5ec0210b3995004c708180a66a096e0b9be5f1ba SHA1 e5b8c4b742fdcc439da9458f94f530604abdfdd5 SHA256 37ef90e2afa2b73a620bf71a096df48d5fde8f1cd669fac83d8c143a1295198c
+DIST ejabberd-2.1.3.tar.gz 2243874 RMD160 c57672928e30f71ec66636dd5e76adb802f17b03 SHA1 77fdf18c0bb3b25cf9045e0c833ba4d82f180469 SHA256 602c6e4e742c4cab8594e9f049f08d0bf2125fa84af491e0ceb6d6f2f3854ef6
EBUILD ejabberd-2.0.5-r3.ebuild 4901 RMD160 1f7a17a51e3310a0619ed37d3defb34380d637f4 SHA1 608359d5a2a4889326b9afa43883104653689134 SHA256 02bf31c731eb7f72ace9fa5092421b2dd96700ca82d7eccc034aaa256c2b04fd
-MISC ChangeLog 14847 RMD160 b86fe6d04adfb6a30f79d3c040bb322f9bf12c7e SHA1 2a16c9e80a8cce50b14cad9bf586410e4f2b5f69 SHA256 5b280da534aa9bfe1e90ea46592a0d7eb6be098d0162a4868529b1bf4a6a6041
-MISC metadata.xml 619 RMD160 ca6e7f018d370ce36a3b93eb960254537260949c SHA1 404f3d0d31036ed1cfeb8aeee2264559c1d1c8d9 SHA256 843e1bbd5fdc082763e71322094170cde5b90d0f5d9320011c4b9872cd6589f4
------BEGIN PGP SIGNATURE-----
-Version: GnuPG v2.0.11 (GNU/Linux)
-
-iEYEARECAAYFAks7OycACgkQNQqtfCuFneNzXACeJZZb8dyUW9A1Sdg73ovrwDoz
-J/4Ani4NkGGZLX4Smrhn8+CG4N/YJcP2
-=wMEv
------END PGP SIGNATURE-----
+EBUILD ejabberd-2.1.3.ebuild 7928 RMD160 4bce6a02c2a21096b04c62f696b7392ace36c666 SHA1 0eb231fa97ce822d8c9900c49f910efeb01dfa53 SHA256 565edc97eb6f5e7aa1b1bbfa16d95b5a6c93d2475c9e4c616ec2465a6ee78395
+MISC ChangeLog 15474 RMD160 3ca57b8864bb1c6b00e697e285f3a8abcd3ea9a1 SHA1 e0331595d2b1164dd57d84e111f3fcd8654b0027 SHA256 56a0b4ee76c7a92cf91734d33b1026ea7630110ee42205efadfe2fd3dba00051
+MISC metadata.xml 875 RMD160 ac2ab791694cf3feae91eb66053273fce29367b1 SHA1 7e5be5bd376801e9b0fbeaa08d8ca720f44b5c5b SHA256 2d8cf45269a75ebf3b07dbd06f74caef0bd2caf33a9dcf22466db6a6960115ef
diff --git a/net-im/ejabberd/ejabberd-2.1.3.ebuild b/net-im/ejabberd/ejabberd-2.1.3.ebuild
new file mode 100644
index 000000000000..f8f03fc99269
--- /dev/null
+++ b/net-im/ejabberd/ejabberd-2.1.3.ebuild
@@ -0,0 +1,213 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-im/ejabberd/ejabberd-2.1.3.ebuild,v 1.1 2010/05/26 20:25:25 pva Exp $
+
+EAPI=3
+
+inherit eutils multilib pam ssl-cert
+
+DESCRIPTION="The Erlang Jabber Daemon"
+HOMEPAGE="http://www.ejabberd.im/"
+SRC_URI="http://www.process-one.net/downloads/${PN}/${PV}/${P}.tar.gz
+ mod_statsdx? ( mirror://gentoo/2.1.1-mod_statsdx.patch.bz2 )"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~ia64 ~ppc ~x86"
+EJABBERD_MODULES="mod_irc mod_muc mod_proxy65 mod_pubsub mod_statsdx"
+IUSE="captcha debug ldap odbc pam ssl +web zlib ${EJABBERD_MODULES}"
+
+DEPEND=">=net-im/jabber-base-0.01
+ >=dev-libs/expat-1.95
+ >=dev-lang/erlang-12.2.5[ssl?]
+ odbc? ( dev-db/unixODBC )
+ ldap? ( =net-nds/openldap-2* )
+ ssl? ( >=dev-libs/openssl-0.9.8e )
+ captcha? ( media-gfx/imagemagick[truetype,png] )
+ zlib? ( sys-libs/zlib )"
+#>=sys-apps/shadow-4.1.4.2-r2 - fixes bug in su that made ejabberdctl unworkable.
+RDEPEND="${DEPEND}
+ >=sys-apps/shadow-4.1.4.2-r2"
+
+PROVIDE="virtual/jabber-server"
+
+S=${WORKDIR}/${P}/src
+
+# pathes in net-im/jabber-base
+JABBER_ETC="${EPREFIX}/etc/jabber"
+#JABBER_RUN="/var/run/jabber"
+JABBER_SPOOL="${EPREFIX}/var/spool/jabber"
+JABBER_LOG="${EPREFIX}/var/log/jabber"
+JABBER_DOC="${EPREFIX}/usr/share/doc/${PF}"
+
+src_prepare() {
+ if use mod_statsdx; then
+ ewarn "mod_statsdx is not a part of upstream tarball but is a third-party module"
+ ewarn "taken from here: http://www.ejabberd.im/mod_stats2file"
+ epatch "${WORKDIR}/2.1.1-mod_statsdx.patch"
+ fi
+
+ # don't install release notes (we'll do this manually)
+ sed '/install .* [.][.]\/doc\/[*][.]txt $(DOCDIR)/d' -i Makefile.in || die
+ # Set correct pathes
+ sed -e "/^EJABBERDDIR[[:space:]]*=/{s:ejabberd:${PF}:}" \
+ -e "/^ETCDIR[[:space:]]*=/{s:@sysconfdir@/ejabberd:${JABBER_ETC}:}" \
+ -e "/^LOGDIR[[:space:]]*=/{s:@localstatedir@/log/ejabberd:${JABBER_LOG}:}" \
+ -e "/^SPOOLDIR[[:space:]]*=/{s:@localstatedir@/lib/ejabberd:${JABBER_SPOOL}:}" \
+ -i Makefile.in || die
+ sed -e "/EJABBERDDIR=/{s:ejabberd:${PF}:}" \
+ -e "s|\(ETCDIR=\)@SYSCONFDIR@.*|\1${JABBER_ETC}|" \
+ -e "s|\(LOGS_DIR=\)@LOCALSTATEDIR@.*|\1${JABBER_LOG}|" \
+ -e "s|\(SPOOLDIR=\)@LOCALSTATEDIR@.*|\1${JABBER_SPOOL}|" \
+ -i ejabberdctl.template || die
+
+ # Set shell, so it'll work even in case jabber user have no shell
+ # This is gentoo specific I guess since other distributions may have
+ # ejabberd user with reall shell, while we share this user among different
+ # jabberd implementations.
+ sed '/^HOME/aSHELL=/bin/sh' -i ejabberdctl.template || die
+ sed '/^export HOME/aexport SHELL' -i ejabberdctl.template || die
+
+ #sed -e "s:/share/doc/ejabberd/:${JABBER_DOC}:" -i web/ejabberd_web_admin.erl
+
+ # fix up the ssl cert paths in ejabberd.cfg to use our cert
+ sed -e "s:/path/to/ssl.pem:/etc/ssl/ejabberd/server.pem:g" \
+ -i ejabberd.cfg.example || die "Failed sed ejabberd.cfg.example"
+
+ # correct path to captcha script in default ejabberd.cfg
+ sed -e 's|\({captcha_cmd,[[:space:]]*"\).\+"}|\1/usr/'$(get_libdir)'/erlang/lib/'${P}'/priv/bin/captcha.sh"}|' \
+ -i ejabberd.cfg.example || die "Failed sed ejabberd.cfg.example"
+
+ # disable mod_irc
+ if ! use mod_irc; then
+ sed -i -e "s/{mod_irc,/%{mod_irc,/" \
+ -i ejabberd.cfg.example || die "Failed to disable mod_irc"
+ fi
+}
+
+src_configure() {
+ econf \
+ --docdir="${EPREFIX}/usr/share/doc/${PF}/html" \
+ --libdir="${EPREFIX}/usr/$(get_libdir)/erlang/lib/" \
+ $(use_enable mod_irc) \
+ $(use_enable ldap eldap) \
+ $(use_enable mod_muc) \
+ $(use_enable mod_proxy65) \
+ $(use_enable mod_pubsub) \
+ $(use_enable ssl tls) \
+ $(use_enable web) \
+ $(use_enable odbc) \
+ $(use_enable zlib ejabberd_zlib) \
+ $(use_enable pam) \
+ --enable-user=jabber
+}
+
+src_compile() {
+ emake $(use debug && echo debug=true ejabberd_debug=true) || die "compiling ejabberd core failed"
+}
+
+src_install() {
+ emake DESTDIR="${ED}" install || die "install failed"
+
+ # Pam helper module permissions
+ # http://www.process-one.net/docs/ejabberd/guide_en.html
+ if use pam; then
+ pamd_mimic_system xmpp auth account || die "Cannot create pam.d file"
+ fperms 4750 "/usr/$(get_libdir)/erlang/lib/${P}/priv/bin/epam" || die "Cannot adjust epam permissions"
+ fi
+
+ cd "${WORKDIR}/${P}/doc"
+ dodoc "release_notes_${PV%%_rc*}.txt" || die
+
+ #dodir /var/lib/ejabberd
+ newinitd "${FILESDIR}/${PN}-3.initd" ${PN} || die "Cannot install init.d script"
+ newconfd "${FILESDIR}/${PN}-3.confd" ${PN} || die "Cannot install conf.d file"
+}
+
+pkg_postinst() {
+ elog "For configuration instructions, please see"
+ elog "/usr/share/doc/${PF}/html/guide.html, or the online version at"
+ elog "http://www.process-one.net/en/ejabberd/docs/guide_en/"
+
+ if ! use web ; then
+ ewarn
+ ewarn "The web USE flag is off, this has disabled the web admin interface."
+ ewarn
+ fi
+
+ elog
+ elog '===================================================================='
+ elog 'Quick Start Guide:'
+ elog '1) Add output of `hostname -f` to /etc/jabber/ejabberd.cfg line 91'
+ elog ' {hosts, ["localhost", "thehost"]}.'
+ elog '2) Add an admin user to /etc/jabber/ejabberd.cfg line 360'
+ elog ' {acl, admin, {user, "theadmin", "thehost"}}.'
+ elog '3) Start the server'
+ elog ' # /etc/init.d/ejabberd start'
+ elog '4) Register the admin user'
+ elog ' # /usr/sbin/ejabberdctl register theadmin thehost thepassword'
+ elog '5) Log in with your favourite jabber client or using the web admin'
+
+ # Upgrading from ejabberd-2.0.x:
+ if grep -E '^[^#]*EJABBERD_NODE=' "${EROOT}/etc/conf.d/ejabberd" >/dev/null 2>&1; then
+ source "${EROOT}/etc/conf.d/ejabberd"
+ ewarn
+ ewarn "!!! WARNING !!! WARNING !!! WARNING !!! WARNING !!!"
+ ewarn "Starting with 2.1.x some pathes and configuration files were"
+ ewarn "changed to better reflect upstream intentions. Notable changes are:"
+ ewarn
+ ewarn "1. Everything (even init scripts) are now handled by ejabberdctl script."
+ ewarn "Thus main configuration file became /etc/jabberd/ejabberdctl.cfg"
+ ewarn "You must update ERLANG_NODE there with the value of EJABBERD_NODE"
+ ewarn "from /etc/conf.d/ejebberd or ejabberd will refuse to start."
+ ewarn
+ ewarn "2. SSL certificate is now generated with ssl-cert eclass and resides"
+ ewarn "at standard location: /etc/ssl/ejabberd/server.pem."
+ ewarn
+ ewarn "3. Cookie now resides at /var/spool/jabber/.erlang.cookie"
+ ewarn
+ ewarn "4. /var/log/jabber/sasl.log is now /var/log/jabber/erlang.log"
+ ewarn
+ ewarn "5. Crash dumps (if any) will be located at /var/log/jabber"
+
+ local i ctlcfg new_ctlcfg
+ i=0
+ ctlcfg=${EROOT}/etc/jabber/ejabberdctl.cfg
+ while :; do
+ new_ctlcfg=$(printf "${EROOT}/etc/jabber/._cfg%04d_ejabberdctl.cfg" ${i})
+ [[ ! -e ${new_ctlcfg} ]] && break
+ ctlcfg=${new_ctlcfg}
+ ((i++))
+ done
+
+ ewarn
+ ewarn "Updating ${ctlcfg} (debug: ${new_ctlcfg})"
+ sed -e "/#ERLANG_NODE=/aERLANG_NODE=$EJABBERD_NODE" "${ctlcfg}" > "${new_ctlcfg}" || die
+
+ if [[ -e ${EROOT}/var/run/jabber/.erlang.cookie ]]; then
+ ewarn "Moving .erlang.cookie..."
+ if [[ -e ${EROOT}/var/spool/jabber/.erlang.cookie ]]; then
+ mv -v "${EROOT}"/var/spool/jabber/.erlang.cookie{,bak}
+ fi
+ mv -v "${EROOT}"/var/{run/jabber,spool/jabber}/.erlang.cookie
+ fi
+ ewarn
+ ewarn "We'll try to handle upgrade automagically but, please, do your"
+ ewarn "own checks and do not forget to run 'etc-update'!"
+ ewarn "PLEASE! Run 'etc-update' now!"
+ fi
+
+ if use ssl; then
+ SSL_ORGANIZATION="${SSL_ORGANIZATION:-Ejabberd XMPP Server}"
+ install_cert /etc/ssl/ejabberd/server
+ if [[ -e ${EROOT}/etc/jabber/ssl.pem ]]; then
+ ewarn
+ ewarn "The location of SSL certificates has changed. If you are"
+ ewarn "upgrading from ${CATEGORY}/${PN}-2.0.5* or earlier you might"
+ ewarn "want to move your old certificates from /etc/jabber into"
+ ewarn "/etc/ssl/ejabberd/, update config files and"
+ ewarn "rm /etc/jabber/ssl.pem to avoid this message."
+ ewarn
+ fi
+ fi
+}
diff --git a/net-im/ejabberd/files/ejabberd-3.confd b/net-im/ejabberd/files/ejabberd-3.confd
new file mode 100644
index 000000000000..b1e984e4d7ab
--- /dev/null
+++ b/net-im/ejabberd/files/ejabberd-3.confd
@@ -0,0 +1,5 @@
+# Please configure everything at /etc/jabber/ejabberdctl.cfg
+# Put here only command line arguments for ejabberdctl (if any are required)
+
+#EJABBERDCTL_OPTS=""
+
diff --git a/net-im/ejabberd/files/ejabberd-3.initd b/net-im/ejabberd/files/ejabberd-3.initd
new file mode 100644
index 000000000000..857af1d653e4
--- /dev/null
+++ b/net-im/ejabberd/files/ejabberd-3.initd
@@ -0,0 +1,22 @@
+#!/sbin/runscript
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-im/ejabberd/files/ejabberd-3.initd,v 1.1 2010/05/26 20:25:25 pva Exp $
+
+depend() {
+ use dns
+ need net
+ provide jabber-server
+}
+
+start() {
+ ebegin "Starting ejabberd"
+ /usr/sbin/ejabberdctl ${EJABBERDCTL_OPT} start
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping ejabberd"
+ /usr/sbin/ejabberdctl stop
+ eend $?
+}
diff --git a/net-im/ejabberd/metadata.xml b/net-im/ejabberd/metadata.xml
index 8f470bd7e64f..48f6cfa8c659 100644
--- a/net-im/ejabberd/metadata.xml
+++ b/net-im/ejabberd/metadata.xml
@@ -1,16 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
-
<pkgmetadata>
<herd>net-im</herd>
<maintainer>
<email>caleb@gentoo.org</email>
</maintainer>
<longdescription> Free and Open Source distributed fault-tolerant Jabber server. It's mostly written in Erlang, and works on many platforms.</longdescription>
-<use>
- <flag name='mod_irc'>Irc support in ejabberd</flag>
- <flag name='mod_muc'>Multi user chat support in ejabberd</flag>
- <flag name='mod_pubsub'>Pubsub support in ejabberd</flag>
- <flag name='web'>Web support in ejabberd</flag>
-</use>
+ <use>
+ <flag name='mod_irc'>Build irc gateway </flag>
+ <flag name='mod_muc'>Build Multi User Chat module</flag>
+ <flag name='mod_pubsub'>Build Pubsub module</flag>
+ <flag name='web'>Enable web admin interface</flag>
+ <flag name="captcha">Support for CAPTCHA Forms (XEP-158)</flag>
+ <flag name="mod_proxy65">Support for SOCKS5 Bytestreams (XEP-0065)</flag>
+ <flag name="mod_statsdx">Measures several statistics, and provides a new section in ejabberd Web Admin to view them.</flag>
+ </use>
</pkgmetadata>