From d29c22b21a895ff82ee5430a3a4ccd622a9e5599 Mon Sep 17 00:00:00 2001 From: lars Date: Thu, 4 May 2006 03:46:55 +0000 Subject: [PATCH] manpage of ezmlm-web.cgi updated and added to Makefile.PL fixed debian packaging warnings fixed configuration file in debian package added manpage for ezmlm-web.wrapper renamed INSTALL.clearsilver to README.clearsilver (to avoid debian packaging warnings) --- INSTALL | 2 +- Makefile.PL | 3 +- INSTALL.clearsilver => README.clearsilver | 2 + debian/control | 2 +- debian/docs | 2 +- debian/ezmlm-web.manpages | 2 + debian/patches/00list | 1 + debian/patches/01_paths_in_config_file.dpatch | 24 ++++++ debian/rules | 3 + ezmlm-web.cgi | 79 ++++++++++++------- man/ezmlm-web.wrapper.1 | 21 +++++ suid-wrapper/Makefile | 4 +- suid-wrapper/ezmlm-web-make-suid | 2 +- suid-wrapper/index.h | 2 +- 14 files changed, 113 insertions(+), 36 deletions(-) rename INSTALL.clearsilver => README.clearsilver (93%) create mode 100644 debian/patches/00list create mode 100755 debian/patches/01_paths_in_config_file.dpatch create mode 100644 man/ezmlm-web.wrapper.1 diff --git a/INSTALL b/INSTALL index f969675..661e3ef 100644 --- a/INSTALL +++ b/INSTALL @@ -22,7 +22,7 @@ OVERVIEW: modules. Additionally (since v3.0) you have to install clearsilver (a templating - engine). See INSTALL.clearsilver for details. + engine). See README.clearsilver for details. 1. Choose a distribution form diff --git a/Makefile.PL b/Makefile.PL index 91371f1..ecad243 100644 --- a/Makefile.PL +++ b/Makefile.PL @@ -20,6 +20,7 @@ WriteMakefile( 'File::Copy' => 2.02, 'File::Path' => 1.07, 'Text::ParseWords' => 3.0 }, + 'MAN1PODS' => { 'ezmlm-web.cgi' => 'blib/man1/ezmlm-web.cgi.1p' }, 'dist' => { COMPRESS => 'gzip', SUFFIX => 'gz' } ); @@ -76,7 +77,7 @@ install_cgi: make_real_bin install_suid_wrapper: build_suid_wrapper make_real_bin \$(NOECHO) echo "WARNING: \$(REALINSTALLBIN)" install -c -m 0755 suid-wrapper/index.cgi \$(DESTDIR)\$(REALINSTALLBIN)/ezmlm-web.wrapper - install -c -m 0755 suid-wrapper/ezmlm-web-make-suid \$(DESTDIR)\$(REALINSTALLBIN)/ + install -c -m 0755 suid-wrapper/ezmlm-web-make-suid.configured \$(DESTDIR)\$(REALINSTALLBIN)/ezmlm-web-make-suid install:: real_install_bin_\$(INSTALLDIRS) install_share_\$(INSTALLDIRS) install_share_site:: DESTINSTALLSHARE := \$(DESTDIR)\$(PREFIX)/local/share diff --git a/INSTALL.clearsilver b/README.clearsilver similarity index 93% rename from INSTALL.clearsilver rename to README.clearsilver index 484bfe0..bbf9831 100644 --- a/INSTALL.clearsilver +++ b/README.clearsilver @@ -27,6 +27,8 @@ you should replace the existing SITEPREFIX line in perl/Makefile with the follow SITEPREFIX = $(PREFIX) (without the leading white space) +This issue should be fixed in clearsilver 0.10.3. + 5) make install diff --git a/debian/control b/debian/control index 097968b..5e5f677 100644 --- a/debian/control +++ b/debian/control @@ -2,7 +2,7 @@ Source: ezmlm-web Section: admin Priority: extra Maintainer: Lars Kruse -Build-Depends: debhelper (>>3.0.0), gcc, dpatch +Build-Depends: debhelper (>>3.0.0), gcc (>= 2.95), dpatch Standards-Version: 3.6.2 Package: ezmlm-web diff --git a/debian/docs b/debian/docs index 6856169..b823047 100644 --- a/debian/docs +++ b/debian/docs @@ -1,5 +1,5 @@ changelog -INSTALL.clearsilver +README.clearsilver README README.gnupg UPGRADING diff --git a/debian/ezmlm-web.manpages b/debian/ezmlm-web.manpages index 223b7c5..a4948fb 100644 --- a/debian/ezmlm-web.manpages +++ b/debian/ezmlm-web.manpages @@ -1 +1,3 @@ man/ezmlm-web-make-suid.1 +man/ezmlm-web.wrapper.1 +blib/man1/ezmlm-web.cgi.1p diff --git a/debian/patches/00list b/debian/patches/00list new file mode 100644 index 0000000..4beffc2 --- /dev/null +++ b/debian/patches/00list @@ -0,0 +1 @@ +01_paths_in_config_file diff --git a/debian/patches/01_paths_in_config_file.dpatch b/debian/patches/01_paths_in_config_file.dpatch new file mode 100755 index 0000000..88abd3f --- /dev/null +++ b/debian/patches/01_paths_in_config_file.dpatch @@ -0,0 +1,24 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 01_paths_in_config_file.dpatch by +## +## All lines beginning with `## DP:' are a description of the patch. +## DP: Change the default paths in the ezmlmwebrc config file + +@DPATCH@ + +--- ezmlm-web-3.2/examples/ezmlmwebrc.dist.orig 2006-05-04 05:23:54.000000000 +0200 ++++ ezmlm-web-3.2/examples/ezmlmwebrc.dist 2006-05-04 05:24:06.000000000 +0200 +@@ -26,11 +26,11 @@ + + # Where are the language files + # usually something like /usr/local/share/ezmlm-web/lang +-$LANGUAGE_DIR = "/usr/local/share/ezmlm-web/lang"; ++$LANGUAGE_DIR = "/usr/share/ezmlm-web/lang"; + + # Where are the template files + # usually something like /usr/local/share/ezmlm-web/template +-$TEMPLATE_DIR = "/usr/local/share/ezmlm-web/template"; ++$TEMPLATE_DIR = "/usr/share/ezmlm-web/template"; + + # Safe list deletion? + # 0 = move list to $LIST_DIR/_deleted_lists -> recoverable :) diff --git a/debian/rules b/debian/rules index a2e468b..17bd6d8 100755 --- a/debian/rules +++ b/debian/rules @@ -12,6 +12,9 @@ # This is the debhelper compatibility version to use. export DH_COMPAT=4 +# necessary for dpatch +.NOTPARALLEL: + configure: configure-stamp configure-stamp: patch diff --git a/ezmlm-web.cgi b/ezmlm-web.cgi index a835815..863b5d0 100755 --- a/ezmlm-web.cgi +++ b/ezmlm-web.cgi @@ -1,6 +1,7 @@ #!/usr/bin/perl #=========================================================================== # ezmlm-web.cgi - version 3.2 +# $Id$ # ========================================================================== # All user configuration happens in the config file ``ezmlmwebrc'' # POD documentation is at the end of this file @@ -1379,14 +1380,12 @@ sub gnupg_export_key() for ($i = 0; $i < @all_keys; $i++) { $name = $all_keys[$i]{name} if ($keyid == $all_keys[$i]{id}); } - warn "vorher: $name"; if ($name) { $name =~ s/\W+/_/g; $name .= '.asc'; } else { $name = "public_key.asc"; } - warn "nachher: $name"; my $key_armor; if ($key_armor = $list->export_key($keyid)) { @@ -1824,7 +1823,7 @@ sub fatal_error() { } # ------------------------------------------------------------------------ -# End of ezmlm-web.cgi v2.3 +# End of ezmlm-web.cgi # ------------------------------------------------------------------------ __END__ @@ -1840,11 +1839,15 @@ ezmlm-web [B<-c>] [B<-C> EFE] [B<-d> EF =over 4 -=item B<-C> Specify an alternate configuration file given as F -If not specified, ezmlm-web checks first in the users home directory, then in -F and then the current directory +=item B<-C> -=item B<-d> Specify an alternate directory where lists live. This is now +Specify an alternate configuration file given as F +If not specified, ezmlm-web checks first in the users home directory, then the +current directory (filename: .ezmlmwebrc) and then F. + +=item B<-d> + +Specify an alternate directory where lists live. This is now depreciated in favour of using a custom ezmlmwebrc, but is left for backward compatibility. @@ -1852,39 +1855,59 @@ compatibility. =head1 SUID WRAPPER -C<#include stdio.h> - -C - C - C -C<}> +Create a suid binary wrapper for every (virtual) mailing list account: + ezmlm-web-make-suid john ~john/public_html/cgi-bin/ezmlm-web =head1 DOCUMENTATION/CONFIGURATION - Please refer to the example ezmlmwebrc which is well commented, and - to the README file in this distribution. +Please refer to the example ezmlmwebrc which is well commented, and +to the README file in this distribution. + +=head1 ENCRYPTED MAILING LISTS + +Please refer to README.gnupg for details on how to manage encrypted +mailing lists with ezmlm-web. =head1 FILES -F<~/.ezmlmwebrc> -F -F<./ezmlmwebrc> +=over -=head1 AUTHOR +=item F<./.ezmlmwebrc> - Guy Antony Halse - Lars Kruse +=item F<~/.ezmlmwebrc> + +=item F + +=back + +=head1 AUTHORS + +=over + +=item Guy Antony Halse + +=item Lars Kruse + +=back =head1 BUGS - None known yet. Please report bugs to the author. +None known yet. Please report bugs to the author. =head1 S - ezmlm(5), ezmlm-cgi(1), Mail::Ezmlm(3) - - https://systemausfall.org/toolforge/ezmlm-web - http://rucus.ru.ac.za/~guy/ezmlm/ - http://www.ezmlm.org/ - http://www.qmail.org/ +L, L, L, L + +=over + +=item L + +=item L + +=item L + +=item L + +=back + diff --git a/man/ezmlm-web.wrapper.1 b/man/ezmlm-web.wrapper.1 new file mode 100644 index 0000000..ef728e4 --- /dev/null +++ b/man/ezmlm-web.wrapper.1 @@ -0,0 +1,21 @@ +.TH ezmlm-web.wrapper 1 "May 02006" "ezmlm-web" "suid wrapper" +.SH NAME +ezmlm-web.wrapper \- pre-compiled (binary) template for suid wrappers around ezmlm-web +.SH DESCRIPTION +.PP +This pre-compiled (binary) wrapper for ezmlm-web can be used as a template for +user-specific suid binary wrappers. + +To create a user-specific suid binary wrapper, you may use one of the following +methods: + 1.) run ezmlm-web-make-suid + 2.) copy/chmod/chown the wrapper file manually +.SH AUTHOR +Written by Lars Kruse +.SH "REPORTING BUGS" +Report bugs to +.SH SEE ALSO +ezmlm-web-make-suid(1) +.SH COPYRIGHT +Copyright \(co 02006 Lars Kruse + diff --git a/suid-wrapper/Makefile b/suid-wrapper/Makefile index 030e5ac..9d1c12a 100644 --- a/suid-wrapper/Makefile +++ b/suid-wrapper/Makefile @@ -7,9 +7,9 @@ build: $(NOECHO) echo "#define EZMLM_WEB_CGI \"$(REALINSTALLBIN)/ezmlm-web.cgi\"" >index.h $(CC) -o index.cgi index.c - sed -i 's#^EZMLM_WEB_SUID_WRAPPER=.*$$#EZMLM_WEB_SUID_WRAPPER=$(REALINSTALLBIN)/ezmlm-web.wrapper#' ezmlm-web-make-suid + sed 's#^EZMLM_WEB_SUID_WRAPPER=.*$$#EZMLM_WEB_SUID_WRAPPER=$(REALINSTALLBIN)/ezmlm-web.wrapper#' ezmlm-web-make-suid >ezmlm-web-make-suid.configured clean: - -rm index.cgi + -rm index.cgi ezmlm-web-make-suid.configured $(NOECHO) echo "#define EZMLM_WEB_CGI \"/usr/bin/ezmlm-web.cgi\"" >index.h diff --git a/suid-wrapper/ezmlm-web-make-suid b/suid-wrapper/ezmlm-web-make-suid index a7cf378..799e8c3 100755 --- a/suid-wrapper/ezmlm-web-make-suid +++ b/suid-wrapper/ezmlm-web-make-suid @@ -9,7 +9,7 @@ set -eu -EZMLM_WEB_SUID_WRAPPER=test/bin/ezmlm-web.wrapper +EZMLM_WEB_SUID_WRAPPER=/usr/local/bin/ezmlm-web.wrapper [ $(id -u) -ne 0 ] && [ $# -ne 1 ] && echo "Syntax (for non-root): $(basename $0) DESTINATION_FILE" >&2 && exit 1 [ $(id -u) -eq 0 ] && [ $# -gt 2 -o $# -lt 1 ] && echo "Syntax (for root): $(basename $0) [USERNAME] DESTINATION_FILE" >&2 && exit 1 diff --git a/suid-wrapper/index.h b/suid-wrapper/index.h index 722f248..0cde14c 100644 --- a/suid-wrapper/index.h +++ b/suid-wrapper/index.h @@ -1 +1 @@ -#define EZMLM_WEB_CGI "test/bin/ezmlm-web.cgi" +#define EZMLM_WEB_CGI "/usr/bin/ezmlm-web.cgi"