# $Id: ezmlm-web.spec,v 1.1 2016/04/22 09:24:36 unnilennium Exp $ # Authority: gordonr # Name: Gordon Rowell Summary: Web interface to ezmlm configuration %define name ezmlm-web Name: %{name} %define version 3.3.1 %define release 6 Version: %{version} Release: %{release}%{?dist} License: BSD-style Group: Networking/Daemons URL: https://systemausfall.org/toolforge/ezmlm-web/ Source: https://systemausfall.org/toolforge/ezmlm-web/download/ezmlm-web-3.3.1.tar.gz Patch0: ezmlm-web-3.3.1-smeintegration.patch Patch1: ezmlm-web-3.3.1-cgi.patch Patch2: ezmlm-web-3.3.1-modiffor722.patch BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot Requires: ezmlm-idx-std Requires: httpd Requires: qmail Requires: perl Requires: perl-Ezmlm Requires: perl-MailTools BuildRequires: gcc BuildRequires: e-smith-devtools BuildRequires: perl-Ezmlm BuildRequires: perl-devel %description The need for ezmlm-web arose from the fact that we host many student societies on our system. These societies usually have a virtual host for web and email, which is administered by a computer rep from the society. These computer reps often have little or no knowledge of Unix and so we needed a user friendly system that would let the create and maintain mailing lists (such as members@foo.soc.ru.ac.za, committee@foo.soc.ru.ac.za, etc). Since I am never keen to re-invent the wheel, I had a look at Steve Peterson's script (http://virtation.com/qmail/ml-sub), which allows people to subscribe and unsubscribe from mailing lists using a form->email gateway. This is fine for putting on a web page saying "here come and join our mailing list", but doesn't really allow you to administrate a list. Security of mailing lists was a concern, as we really didn't want unauthorised people to be able to alter some users list. Ezmlm-web itself implements no security checks (apart from un-tainting input) and so relies on the web server to do this (re-inventing the wheel again :). We use an Apache webserver, so one can control access to a directory using a .htaccess file or in the access.conf file. ApacheWeek have a good article on doing this at http://www.apacheweek.com/features/userauth. I also give examples later in this document. This version of ezmlm-web (2.0) is based to a large extent on previous versions that I have developed. It has however been totally re-written to make use of the Mail::Ezmlm perl module I wrote. At the same time it was updated and extended to include the new features of ezmlm-idx. It includes many new features that have been suggested to me over the last few months, and hopefully is now useful to a much larger group of people. %changelog * Fri Apr 22 2016 Jean-Philipe Pialasse 3.3.1-6.sme - fix to build against SME 9 centos 6 [SME: 8439] - new path for bins /usr/local/bin * Thu Apr 21 2016 Jean-Philipe Pialasse 3.3.1-5.sme - remove non available options (always on) in ezmlm-idx 7.2.2 [SME: 9470] - remove setting user access to web, as unecessary in SME - patch ezmlm-web-3.3.1-modiffor722.patch * Wed Apr 20 2016 Jean-Philipe Pialasse 3.3.1-4.sme - small fix to save some config with 7.2.2 idx [SME: 9470] * Mon Apr 18 2016 Jean-Philipe Pialasse 3.3.1-1.sme - update to 3.3.1 [SME: 7588] * Sun Apr 29 2007 Shad L. Lords - Clean up spec so package can be built by koji/plague * Thu Dec 07 2006 Shad L. Lords - Update to new release naming. No functional changes. - Make Packager generic * Tue Oct 25 2005 Gordon Rowell 2.3-01sme02 - Retarget previous patches against 2.3 - Change ezmlm-cgi location - Access local help icon - Hide delete button if -c provided * Tue Oct 25 2005 Gordon Rowell 2.3-01sme01 - Update to 2.3 - ezmlm-web has moved to a new home * Wed Nov 28 2001 Gordon Rowell - [2.1-04] - Create ezmlm user (uid/gid 80) in %pre if it doesn't already exist * Wed Oct 24 2001 Gordon Rowell - [2.1-03] - Allow the web server to execute the CGI script * Wed Oct 24 2001 Gordon Rowell - [2.1-02] - Remove [Delete] button if $opt_c is set - $opt_c "no list creation" now also means "no list deletion" * Wed Oct 24 2001 Gordon Rowell - [2.1-01] - Initial packaging - Modified ezmlm-web.cgi path to /usr/bin - Modified $HELP_ICON_URL for RedHat Apache patch %prep %setup -n %{name}-%{version} %patch0 -p1 %patch1 -p1 %patch2 -p1 %build mkdir build perl Makefile.PL DESTDIR=build REALINSTALLBIN=/usr/local/bin/ezmlm-web make make install %install rm -rf $RPM_BUILD_ROOT (cd build ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT) /sbin/e-smith/genfilelist $RPM_BUILD_ROOT \ > %{name}-%{version}-%{release}-filelist #| sed -e '/ezmlm-web.cgi.1p/d' \ #> %{name}-%{version}-%{release}-filelist # creating the cgi index to the suid wrapper cp -a $RPM_BUILD_ROOT/usr/local/bin/ezmlm-web.wrapper $RPM_BUILD_ROOT/usr/local/share/ezmlm-web/www-data/index.cgi %clean rm -rf $RPM_BUILD_ROOT %pre if [ -d /home/e-smith ] then EZMLMHOME=/home/e-smith/files/ezmlm else EZMLMHOME=/home/ezmlm fi grep '^ezmlm:' /etc/passwd > /dev/null || \ /usr/sbin/useradd -c "ezmlm" -u 80 -m -d $EZMLMHOME -s /bin/false ezmlm %post %preun %postun %files -f %{name}-%{version}-%{release}-filelist %defattr(-,root,root) %attr(104755,ezmlm,ezmlm) /usr/local/share/ezmlm-web/www-data/index.cgi #%doc /usr/share/man/man1/ezmlm-web.cgi.1p