From 728a5b3f000f892e52ecea98fcc8f0c5d7275b7b Mon Sep 17 00:00:00 2001 From: Emmanuel Lacour Date: Sat, 13 Oct 2007 14:38:11 +0000 Subject: [PATCH] [svn-inject] Applying Debian modifications to trunk --- debian/changelog | 40 +++++++++++ debian/conf/500mod_suphp.info | 5 ++ debian/conf/suphp.conf | 6 ++ debian/conf/suphp.load | 1 + debian/control | 31 ++++++++ debian/libapache-mod-suphp.copyright | 70 ++++++++++++++++++ debian/libapache-mod-suphp.dirs | 1 + debian/libapache-mod-suphp.docs | 2 + debian/libapache-mod-suphp.install | 2 + debian/libapache-mod-suphp.postinst | 52 ++++++++++++++ debian/libapache-mod-suphp.prerm | 46 ++++++++++++ debian/libapache2-mod-suphp.copyright | 67 +++++++++++++++++ debian/libapache2-mod-suphp.dirs | 2 + debian/libapache2-mod-suphp.docs | 2 + debian/libapache2-mod-suphp.install | 3 + debian/libapache2-mod-suphp.postinst | 63 ++++++++++++++++ debian/libapache2-mod-suphp.prerm | 51 +++++++++++++ debian/rules | 107 +++++++++++++++++++++++++++ debian/suphp-common.copyright | 26 +++++++ debian/suphp-common.dirs | 4 ++ debian/suphp-common.install | 1 + debian/suphp-common.lintian-override | 1 + debian/suphp-common.logrotate | 8 +++ debian/suphp-common.manpage.sgml | 113 +++++++++++++++++++++++++++++ debian/suphp-common.postrm | 39 ++++++++++ src/apache/Makefile | 39 ---------- src/config.h | 131 ---------------------------------- 27 files changed, 743 insertions(+), 170 deletions(-) create mode 100644 debian/changelog create mode 100644 debian/conf/500mod_suphp.info create mode 100644 debian/conf/suphp.conf create mode 100644 debian/conf/suphp.load create mode 100644 debian/control create mode 100644 debian/libapache-mod-suphp.copyright create mode 100644 debian/libapache-mod-suphp.dirs create mode 100644 debian/libapache-mod-suphp.docs create mode 100644 debian/libapache-mod-suphp.install create mode 100644 debian/libapache-mod-suphp.postinst create mode 100644 debian/libapache-mod-suphp.prerm create mode 100644 debian/libapache2-mod-suphp.copyright create mode 100644 debian/libapache2-mod-suphp.dirs create mode 100644 debian/libapache2-mod-suphp.docs create mode 100644 debian/libapache2-mod-suphp.install create mode 100644 debian/libapache2-mod-suphp.postinst create mode 100644 debian/libapache2-mod-suphp.prerm create mode 100755 debian/rules create mode 100644 debian/suphp-common.copyright create mode 100644 debian/suphp-common.dirs create mode 100644 debian/suphp-common.install create mode 100644 debian/suphp-common.lintian-override create mode 100644 debian/suphp-common.logrotate create mode 100644 debian/suphp-common.manpage.sgml create mode 100644 debian/suphp-common.postrm delete mode 100644 src/apache/Makefile delete mode 100644 src/config.h diff --git a/debian/changelog b/debian/changelog new file mode 100644 index 0000000..32f8e3a --- /dev/null +++ b/debian/changelog @@ -0,0 +1,40 @@ +suphp (0.5.2-3) unstable; urgency=low + + * rules: rename INSTALL files to README + * control: suppress leading spaces at beginning of description + * add lintian-override for suid binary + * remove debconf for issuing broken apache2 config warning + * rules: remove Makefile and config.(status|log|h) in clean target + * suphp-common.copyright: make difference between "license" and "copyright" + * suphp-common.postrm: cleanup logs on purge + + + -- Emmanuel Lacour Tue, 12 Oct 2004 10:40:47 +0200 + +suphp (0.5.2-2) unstable; urgency=low + + * Move /usr/sbin/suphp to /usr/lib/suphp/suphp as this binary isn't for + command line use + * Added man page for suphp command + * Add postinst/prerm script do libapache*-mod-suphp + + -- Emmanuel Lacour Mon, 20 Sep 2004 21:59:24 +0200 + +suphp (0.5.2-1) unstable; urgency=low + + * New upstream release + + -- Emmanuel Lacour Wed, 14 Jul 2004 01:25:55 +0200 + +suphp (0.5.1-1) unstable; urgency=low + + * New upstream release + + -- Emmanuel Lacour Sun, 29 Feb 2004 20:28:17 +0100 + +suphp (0.3-1) unstable; urgency=low + + * Initial Release. + + -- Emmanuel Lacour Fri, 19 Sep 2003 15:25:44 +0200 + diff --git a/debian/conf/500mod_suphp.info b/debian/conf/500mod_suphp.info new file mode 100644 index 0000000..14a96b5 --- /dev/null +++ b/debian/conf/500mod_suphp.info @@ -0,0 +1,5 @@ +Loadmodule: suphp_module /usr/lib/apache/1.3/mod_suphp.so +Directives: + suPHP_Engine + suPHP_ConfigPath +Description: Apache module to run php scripts with the owner permissions diff --git a/debian/conf/suphp.conf b/debian/conf/suphp.conf new file mode 100644 index 0000000..108de96 --- /dev/null +++ b/debian/conf/suphp.conf @@ -0,0 +1,6 @@ + + AddHandler x-httpd-php .php .php3 .php4 .phtml + suPHP_Engine on +# # Use a specific php config file (a dir which contains a php.ini file) +# suPHP_ConfigPath /etc/php4/cgi/suphp/ + diff --git a/debian/conf/suphp.load b/debian/conf/suphp.load new file mode 100644 index 0000000..f3fe067 --- /dev/null +++ b/debian/conf/suphp.load @@ -0,0 +1 @@ +LoadModule suphp_module /usr/lib/apache2/modules/mod_suphp.so diff --git a/debian/control b/debian/control new file mode 100644 index 0000000..dba9500 --- /dev/null +++ b/debian/control @@ -0,0 +1,31 @@ +Source: suphp +Section: admin +Priority: optional +Maintainer: Emmanuel Lacour +Build-Depends: debhelper (>> 3.0.0), apache-dev (>= 1.3.20), apache2-prefork-dev (>= 2.0.0), apache2-mpm-prefork (>= 2.0.0), docbook-to-man +Standards-Version: 3.6.1 + +Package: suphp-common +Architecture: any +Depends: ${shlibs:Depends}, php4-cgi, libapache-mod-suphp (= ${Source-Version}) | libapache2-mod-suphp (= ${Source-Version}) +Description: Common files for mod suphp + Suphp consists of an Apache module (mod_suphp for either apache 1.3.x or + apache 2.x) and a setuid root binary (suphp) that is called by the Apache + module to change the uid of the process executing the PHP interpreter to the + owner of the php script. + +Package: libapache-mod-suphp +Architecture: any +Depends: ${shlibs:Depends}, suphp-common (= ${Source-Version}), apache-common (>= 1.3.20) +Description: Apache module to run php scripts with the owner permissions + With the use of the suphp setuid root binary (from suphp-common package), + this Apache module change the uid of the process executing the PHP + interpreter to the owner of the php script + +Package: libapache2-mod-suphp +Architecture: any +Depends: ${shlibs:Depends}, suphp-common (= ${Source-Version}), apache2-common (>= 2.0.0) +Description: Apache2 module to run php scripts with the owner permissions + With the use of the suphp setuid root binary (from suphp-common package), + this Apache2 module change the uid of the process executing the PHP + interpreter to the owner of the php script diff --git a/debian/libapache-mod-suphp.copyright b/debian/libapache-mod-suphp.copyright new file mode 100644 index 0000000..863f38e --- /dev/null +++ b/debian/libapache-mod-suphp.copyright @@ -0,0 +1,70 @@ +This package was debianized by Emmanuel Lacour on +Fri, 19 Sep 2003 15:25:44 +0200. + +It was downloaded from http://www.suphp.org/download/ + +Upstream Author: Sebastian Marsching + +Copyright: + +/* ==================================================================== + * The Apache Software License, Version 1.1 + * + * Copyright (c) 2000 The Apache Software Foundation. All rights + * reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * + * 3. The end-user documentation included with the redistribution, + * if any, must include the following acknowledgment: + * "This product includes software developed by the + * Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, + * if and wherever such third-party acknowledgments normally appear. + * + * 4. The names "Apache" and "Apache Software Foundation" must + * not be used to endorse or promote products derived from this + * software without prior written permission. For written + * permission, please contact apache@apache.org. + * + * 5. Products derived from this software may not be called "Apache", + * nor may "Apache" appear in their name, without prior written + * permission of the Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * ==================================================================== + * + * This software consists of voluntary contributions made by many + * individuals on behalf of the Apache Software Foundation. For more + * information on the Apache Software Foundation, please see + * . + * + * Portions of this software are based upon public domain software + * originally written at the National Center for Supercomputing Applications, + * University of Illinois, Urbana-Champaign. + */ + +"This product includes software developed by the + Apache Software Foundation (http://www.apache.org/)." + diff --git a/debian/libapache-mod-suphp.dirs b/debian/libapache-mod-suphp.dirs new file mode 100644 index 0000000..554b50e --- /dev/null +++ b/debian/libapache-mod-suphp.dirs @@ -0,0 +1 @@ +usr/lib/apache/1.3 diff --git a/debian/libapache-mod-suphp.docs b/debian/libapache-mod-suphp.docs new file mode 100644 index 0000000..d9291c5 --- /dev/null +++ b/debian/libapache-mod-suphp.docs @@ -0,0 +1,2 @@ +doc/en/apache/INSTALL +doc/en/apache/CONFIG diff --git a/debian/libapache-mod-suphp.install b/debian/libapache-mod-suphp.install new file mode 100644 index 0000000..a3155f6 --- /dev/null +++ b/debian/libapache-mod-suphp.install @@ -0,0 +1,2 @@ +src/apache/mod_suphp.so usr/lib/apache/1.3/ +debian/conf/500mod_suphp.info usr/lib/apache/1.3/ diff --git a/debian/libapache-mod-suphp.postinst b/debian/libapache-mod-suphp.postinst new file mode 100644 index 0000000..bffad91 --- /dev/null +++ b/debian/libapache-mod-suphp.postinst @@ -0,0 +1,52 @@ +#! /bin/sh +# postinst script for libapache-mod-suphp +# +# see: dh_installdeb(1) + +set -e + +# summary of how this script can be called: +# * `configure' +# * `abort-upgrade' +# * `abort-remove' `in-favour' +# +# * `abort-deconfigure' `in-favour' +# `removing' +# +# for details, see http://www.debian.org/doc/debian-policy/ or +# the debian-policy package +# + +case "$1" in + configure) + if [ -n "$2" ]; then + # we're upgrading. don't ask again + exit 0 + fi + if [ -x /usr/sbin/apache-modconf ]; then + for i in apache apache-perl apache-ssl; do + if [ -e /etc/$i/httpd.conf ]; then + apache-modconf $i enable mod_suphp + fi + done + fi + ;; + + abort-upgrade|abort-remove|abort-deconfigure) + + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 + + diff --git a/debian/libapache-mod-suphp.prerm b/debian/libapache-mod-suphp.prerm new file mode 100644 index 0000000..0fac5c4 --- /dev/null +++ b/debian/libapache-mod-suphp.prerm @@ -0,0 +1,46 @@ +#! /bin/sh +# prerm script for libapache-mod-suphp +# +# see: dh_installdeb(1) + +set -e + +# summary of how this script can be called: +# * `remove' +# * `upgrade' +# * `failed-upgrade' +# * `remove' `in-favour' +# * `deconfigure' `in-favour' +# `removing' +# +# for details, see http://www.debian.org/doc/debian-policy/ or +# the debian-policy package + + +case "$1" in + remove) + if [ -x /usr/sbin/apache-modconf ]; then + for i in apache apache-perl apache-ssl; do + if [ -e /etc/$i/httpd.conf ]; then + apache-modconf $i disable mod_suphp quiet + fi + done + fi + + ;; + upgrade|failed-upgrade|deconfigure) + ;; + *) + echo "prerm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 + + diff --git a/debian/libapache2-mod-suphp.copyright b/debian/libapache2-mod-suphp.copyright new file mode 100644 index 0000000..0e3d051 --- /dev/null +++ b/debian/libapache2-mod-suphp.copyright @@ -0,0 +1,67 @@ +This package was debianized by Emmanuel Lacour on +Fri, 19 Sep 2003 15:25:44 +0200. + +It was downloaded from http://www.suphp.org/download/ + +Upstream Author: Sebastian Marsching + +Copyright: + +/* ==================================================================== + * The Apache Software License, Version 1.1 + * + * Copyright (c) 2000 The Apache Software Foundation. All rights + * reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * + * 3. The end-user documentation included with the redistribution, + * if any, must include the following acknowledgment: + * "This product includes software developed by the + * Apache Software Foundation (http://www.apache.org/)." + * Alternately, this acknowledgment may appear in the software itself, + * if and wherever such third-party acknowledgments normally appear. + * + * 4. The names "Apache" and "Apache Software Foundation" must + * not be used to endorse or promote products derived from this + * software without prior written permission. For written + * permission, please contact apache@apache.org. + * + * 5. Products derived from this software may not be called "Apache", + * nor may "Apache" appear in their name, without prior written + * permission of the Apache Software Foundation. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF + * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * ==================================================================== + * + * This software consists of voluntary contributions made by many + * individuals on behalf of the Apache Software Foundation. For more + * information on the Apache Software Foundation, please see + * . + * + * Portions of this software are based upon public domain software + * originally written at the National Center for Supercomputing Applications, + * University of Illinois, Urbana-Champaign. + */ + diff --git a/debian/libapache2-mod-suphp.dirs b/debian/libapache2-mod-suphp.dirs new file mode 100644 index 0000000..4675a48 --- /dev/null +++ b/debian/libapache2-mod-suphp.dirs @@ -0,0 +1,2 @@ +usr/lib/apache2/modules/ +etc/apache2/mods-available/ diff --git a/debian/libapache2-mod-suphp.docs b/debian/libapache2-mod-suphp.docs new file mode 100644 index 0000000..d9291c5 --- /dev/null +++ b/debian/libapache2-mod-suphp.docs @@ -0,0 +1,2 @@ +doc/en/apache/INSTALL +doc/en/apache/CONFIG diff --git a/debian/libapache2-mod-suphp.install b/debian/libapache2-mod-suphp.install new file mode 100644 index 0000000..999fb0d --- /dev/null +++ b/debian/libapache2-mod-suphp.install @@ -0,0 +1,3 @@ +src/apache2/.libs/mod_suphp.so usr/lib/apache2/modules/ +debian/conf/suphp.load etc/apache2/mods-available/ +debian/conf/suphp.conf etc/apache2/mods-available/ diff --git a/debian/libapache2-mod-suphp.postinst b/debian/libapache2-mod-suphp.postinst new file mode 100644 index 0000000..1b5bad0 --- /dev/null +++ b/debian/libapache2-mod-suphp.postinst @@ -0,0 +1,63 @@ +#! /bin/sh +# postinst script for libapache-mod-suphp +# +# see: dh_installdeb(1) + +set -e + +# summary of how this script can be called: +# * `configure' +# * `abort-upgrade' +# * `abort-remove' `in-favour' +# +# * `abort-deconfigure' `in-favour' +# `removing' +# +# for details, see http://www.debian.org/doc/debian-policy/ or +# the debian-policy package +# + +reload_apache() +{ + if apache2ctl configtest 2>/dev/null; then + invoke-rc.d apache2 force-reload || true + else + echo "Your apache2 configuration is broken, so we're not restarting it for you." + fi +} + + +case "$1" in + configure) + # Reload the module on upgrade if enabled + if [ -n "$2" ]; then + if [ -e /etc/apache2/mods-enabled/suphp.load ]; then + reload_apache + fi + else + # Enable the module + if [ -e /etc/apache2/apache2.conf ]; then + a2enmod suphp >/dev/null || true + reload_apache + fi + fi + ;; + + abort-upgrade|abort-remove|abort-deconfigure) + + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 + + diff --git a/debian/libapache2-mod-suphp.prerm b/debian/libapache2-mod-suphp.prerm new file mode 100644 index 0000000..c4b0f51 --- /dev/null +++ b/debian/libapache2-mod-suphp.prerm @@ -0,0 +1,51 @@ +#! /bin/sh +# prerm script for libapache-mod-suphp +# +# see: dh_installdeb(1) + +set -e + +# summary of how this script can be called: +# * `remove' +# * `upgrade' +# * `failed-upgrade' +# * `remove' `in-favour' +# * `deconfigure' `in-favour' +# `removing' +# +# for details, see http://www.debian.org/doc/debian-policy/ or +# the debian-policy package + +reload_apache() +{ + if apache2ctl configtest 2>/dev/null; then + invoke-rc.d apache2 force-reload || true + else + echo "Your apache2 configuration is broken, so we're not restarting it for you." + fi +} + + +case "$1" in + remove) + if [ -e /etc/apache2/mods-enabled/suphp.load ]; then + a2dismod suphp >/dev/null || true + reload_apache + fi + ;; + upgrade|failed-upgrade|deconfigure) + ;; + *) + echo "prerm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 + + diff --git a/debian/rules b/debian/rules new file mode 100755 index 0000000..aa96cdd --- /dev/null +++ b/debian/rules @@ -0,0 +1,107 @@ +#!/usr/bin/make -f +# Sample debian/rules that uses debhelper. +# GNU copyright 1997 to 1999 by Joey Hess. + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +# This is the debhelper compatibility version to use. +export DH_COMPAT=3 + +# These are used for cross-compiling and for saving the configure script +# from having to guess our platform (since we know it already) +DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) +DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) + + +ifneq (,$(findstring debug,$(DEB_BUILD_OPTIONS))) + CFLAGS += -g +endif +ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS))) + INSTALL_PROGRAM += -s +endif + +configure-apache: + dh_testdir + ./configure --prefix=/usr \ + --with-apxs=/usr/bin/apxs \ + --with-apache-user=www-data \ + --with-php=/usr/lib/cgi-bin/php4 \ + --sbindir=/usr/lib/suphp \ + --with-logfile=/var/log/suphp/suphp.log + +configure-apache2: + dh_testdir + ./configure --prefix=/usr \ + --with-apxs=/usr/bin/apxs2 \ + --with-apache-user=www-data \ + --with-php=/usr/lib/cgi-bin/php4 \ + --sbindir=/usr/lib/suphp \ + --with-logfile=/var/log/suphp/suphp.log + + +build-apache: configure-apache + dh_testdir + $(MAKE) + +build-apache2: configure-apache2 + dh_testdir + $(MAKE) + +clean: + dh_testdir + dh_testroot + -$(MAKE) clean + rm -f config.log config.status src/config.h + find . -name Makefile | xargs rm -f + dh_clean + +install: build-apache build-apache2 + dh_testdir + dh_testroot + dh_clean -k + find -name ".svn" -type d | xargs rm -rf + dh_installdirs + dh_install + docbook-to-man debian/suphp-common.manpage.sgml > debian/suphp-common/usr/share/man/man8/suphp.8 + install -m 644 debian/suphp-common.lintian-override debian/suphp-common/usr/share/lintian/overrides/suphp-common + + +# Build architecture-independent files here. +binary-indep: install +# We have nothing to do by default. + +# Build architecture-dependent files here. +binary-arch: install + dh_testdir + dh_testroot + dh_installdebconf + dh_installdocs + mv debian/libapache-mod-suphp/usr/share/doc/libapache-mod-suphp/INSTALL debian/libapache-mod-suphp/usr/share/doc/libapache-mod-suphp/README + mv debian/libapache2-mod-suphp/usr/share/doc/libapache2-mod-suphp/INSTALL debian/libapache2-mod-suphp/usr/share/doc/libapache2-mod-suphp/README +# dh_installexamples +# dh_installmenu + dh_installlogrotate +# dh_installemacsen +# dh_installpam +# dh_installmime +# dh_installinit +# dh_installcron +# dh_installman +# dh_installinfo + dh_installchangelogs ChangeLog + dh_link + dh_strip + dh_compress + dh_fixperms + chmod u+s debian/suphp-common/usr/lib/suphp/suphp + dh_makeshlibs + dh_installdeb +# dh_perl + dh_shlibdeps + dh_gencontrol + dh_md5sums + dh_builddeb + +binary: binary-indep binary-arch +.PHONY: configure build clean binary-indep binary-arch binary install diff --git a/debian/suphp-common.copyright b/debian/suphp-common.copyright new file mode 100644 index 0000000..2ffac7c --- /dev/null +++ b/debian/suphp-common.copyright @@ -0,0 +1,26 @@ +This package was debianized by Emmanuel Lacour on +Fri, 19 Sep 2003 15:25:44 +0200. + +It was downloaded from http://www.suphp.org/download/ + +Upstream Author: Sebastian Marsching + +Copyright (c) 2004 Sebastian Marsching + +License: + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + +see /usr/share/common-licenses/GPL for all details. diff --git a/debian/suphp-common.dirs b/debian/suphp-common.dirs new file mode 100644 index 0000000..451b3f1 --- /dev/null +++ b/debian/suphp-common.dirs @@ -0,0 +1,4 @@ +usr/lib/suphp +var/log/suphp +usr/share/man/man8 +usr/share/lintian/overrides diff --git a/debian/suphp-common.install b/debian/suphp-common.install new file mode 100644 index 0000000..a0e1bba --- /dev/null +++ b/debian/suphp-common.install @@ -0,0 +1 @@ +src/suphp usr/lib/suphp/ diff --git a/debian/suphp-common.lintian-override b/debian/suphp-common.lintian-override new file mode 100644 index 0000000..d5f2134 --- /dev/null +++ b/debian/suphp-common.lintian-override @@ -0,0 +1 @@ +suphp-common: setuid-binary usr/lib/suphp/suphp 4755 root/root diff --git a/debian/suphp-common.logrotate b/debian/suphp-common.logrotate new file mode 100644 index 0000000..cae3a5f --- /dev/null +++ b/debian/suphp-common.logrotate @@ -0,0 +1,8 @@ +/var/log/suphp/*.log { + daily + missingok + compress + delaycompress + notifempty + create 640 root adm +} diff --git a/debian/suphp-common.manpage.sgml b/debian/suphp-common.manpage.sgml new file mode 100644 index 0000000..9f9f17a --- /dev/null +++ b/debian/suphp-common.manpage.sgml @@ -0,0 +1,113 @@ + manpage.1'. You may view + the manual page with: `docbook-to-man manpage.sgml | nroff -man | + less'. A typical entry in a Makefile or Makefile.am is: + +manpage.1: manpage.sgml + docbook-to-man $< > $@ + + + The docbook-to-man binary is found in the docbook-to-man package. + Please remember that if you create the nroff version in one of the + debian/rules file targets (such as build), you will need to include + docbook-to-man in your Build-Depends control field. + + --> + + + Emmanuel"> + Lacour"> + + September 20, 2004"> + + 8"> + elacour@home-dn.net"> + + suphp"> + + + Debian"> + GNU"> + GPL"> +]> + + + +
+ &dhemail; +
+ + &dhfirstname; + &dhsurname; + + + 2004 + &dhusername; + + &dhdate; +
+ + &dhucpackage; + + &dhsection; + + + &dhpackage; + + run php scripts with the owner permissions + + + + &dhpackage; + php script + + + + + + DESCRIPTION + + &dhpackage; is a suid root binary used by apache + mod_suphp to run php scripts with the owner permissions. It isn't intended + to be run manually and needs some environment variables to be set, such as + SCRIPT_FILENAME and DOCUMENT_ROOT. + + + + AUTHOR + + This manual page was written by &dhusername; &dhemail; for + the &debian; system (but may be used by others). Permission is + granted to copy, distribute and/or modify this document under + the terms of the &gnu; General Public License, Version 2 any + later version published by the Free Software Foundation. + + + On Debian systems, the complete text of the GNU General Public + License can be found in /usr/share/common-licenses/GPL. + + + +
+ + + + diff --git a/debian/suphp-common.postrm b/debian/suphp-common.postrm new file mode 100644 index 0000000..cc39bca --- /dev/null +++ b/debian/suphp-common.postrm @@ -0,0 +1,39 @@ +#! /bin/sh +# postrm script for suphp-common +# +# see: dh_installdeb(1) + +set -e + +# summary of how this script can be called: +# * `remove' +# * `purge' +# * `upgrade' +# * `failed-upgrade' +# * `abort-install' +# * `abort-install' +# * `abort-upgrade' +# * `disappear' overwrit>r> +# for details, see http://www.debian.org/doc/debian-policy/ or +# the debian-policy package + +case "$1" in + purge) + rm -f /var/log/suphp/suphp.log* + ;; + + remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) + + ;; + *) + echo "postrm called with unknown argument \`$1'" >&2 + exit 1 + +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 diff --git a/src/apache/Makefile b/src/apache/Makefile deleted file mode 100644 index bd0cd1a..0000000 --- a/src/apache/Makefile +++ /dev/null @@ -1,39 +0,0 @@ -SHELL = /bin/sh - -top_srcdir = ../.. -srcdir = . - -prefix = /usr/local -exec_prefix = ${prefix} -sbindir = ${exec_prefix}/sbin -CC = gcc -s -CFLAGS = -g -O2 -DEFS = -DHAVE_CONFIG_H -LDFLAGS = - -INSTALL = /bin/install -c -INSTALL_PROGRAM = ${INSTALL} -APXS = /notfound/ - -DESTDIR = - -MAKEDEFS = CC='$(CC)' DEFS='$(DEFS)' CFLAGS='$(CFLAGS)' \ - LDFLAGS='$(LDFLAGS)' prefix='$(prefix)' \ - sbindir='$(sbindir)' DESTDIR='$(DESTDIR)' \ - srcdir='$(srcdir)' - -RM = rm -f -INCLUDES = -I$(top_srcdir)/src -EXTRADEFS = -DPATH_TO_SUPHP=\\\"$(sbindir)/suphp\\\" - -all: suphp.mod - -suphp.mod: mod_suphp.c - $(APXS) -c $(DEFS) $(EXTRADEFS) $(INCLUDES) -Wc,"$(CFLAGS)" mod_suphp.c - -install: suphp.mod - $(APXS) -i -a mod_suphp.so - -clean: - $(RM) mod_suphp.so mod_suphp.o - diff --git a/src/config.h b/src/config.h deleted file mode 100644 index 8156ff8..0000000 --- a/src/config.h +++ /dev/null @@ -1,131 +0,0 @@ -/* src/config.h. Generated by configure. */ -/* src/config.h.in. Generated from configure.ac by autoheader. */ - -/* Define to 1 if you have the header file. */ -#define HAVE_FCNTL_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_INTTYPES_H 1 - -/* Define to 1 if `lstat' has the bug that it succeeds when given the - zero-length file name argument. */ -/* #undef HAVE_LSTAT_EMPTY_STRING_BUG */ - -/* Define to 1 if your system has a working `malloc' function. */ -#define HAVE_MALLOC 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_MEMORY_H 1 - -/* Define to 1 if you have the `setenv' function. */ -#define HAVE_SETENV 1 - -/* Define to 1 if `stat' has the bug that it succeeds when given the - zero-length file name argument. */ -/* #undef HAVE_STAT_EMPTY_STRING_BUG */ - -/* Define to 1 if you have the header file. */ -#define HAVE_STDINT_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_STDLIB_H 1 - -/* Define to 1 if you have the `strcasecmp' function. */ -#define HAVE_STRCASECMP 1 - -/* Define to 1 if you have the `strdup' function. */ -#define HAVE_STRDUP 1 - -/* Define to 1 if you have the `strftime' function. */ -#define HAVE_STRFTIME 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_STRINGS_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_STRING_H 1 - -/* Define to 1 if you have the `strrchr' function. */ -#define HAVE_STRRCHR 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_SYS_STAT_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_SYS_TYPES_H 1 - -/* Define to 1 if you have the header file. */ -#define HAVE_UNISTD_H 1 - -/* Define to 1 if `lstat' dereferences a symlink specified with a trailing - slash. */ -#define LSTAT_FOLLOWS_SLASHED_SYMLINK 1 - -/* Defines the username of the Apache user */ -#define OPT_APACHE_USER "wwwrun" - -/* Define if you want to disable the check, wether script resides in - DOCUMENT_ROOT */ -/* #undef OPT_DISABLE_CHECKPATH */ - -/* Defines path to logfile */ -#define OPT_LOGFILE "/var/log/httpd/suphp_log" - -/* Defines the min GID allowed to run scripts */ -#define OPT_MIN_GID 100 - -/* Defines the min UID allowed to run scripts */ -#define OPT_MIN_UID 100 - -/* Define if you want to proceed even if GID of the script is not listed in - /etc/group */ -/* #undef OPT_NO_GROUP */ - -/* Define if you want to proceed even if UID of the script is not listed in - /etc/passwd */ -/* #undef OPT_NO_PASSWD */ - -/* Defines path to PHP interpreter */ -#define OPT_PATH_TO_PHP "/usr/bin/php" - -/* Define if you want to set UID/GID to the user/group specified in the Apache - configuration */ -/* #undef OPT_USERGROUP_FORCE */ - -/* Define if you want to set UID/GID to the owner of the script */ -#define OPT_USERGROUP_OWNER 1 - -/* Define if you want to set UID/GID to the user/group specified in the Apache - configuration AND check if these settings match the UID/GID of the script - */ -/* #undef OPT_USERGROUP_PARANOID */ - -/* Define to the address where bug reports for this package should be sent. */ -#define PACKAGE_BUGREPORT "sebastian.marsching@suphp.org" - -/* Define to the full name of this package. */ -#define PACKAGE_NAME "suphp" - -/* Define to the full name and version of this package. */ -#define PACKAGE_STRING "suphp 0.5" - -/* Define to the one symbol short name of this package. */ -#define PACKAGE_TARNAME "suphp" - -/* Define to the version of this package. */ -#define PACKAGE_VERSION "0.5" - -/* Define to 1 if you have the ANSI C header files. */ -#define STDC_HEADERS 1 - -/* Define to 1 if your declares `struct tm'. */ -/* #undef TM_IN_SYS_TIME */ - -/* Define to empty if `const' does not conform to ANSI C. */ -/* #undef const */ - -/* Define to `int' if doesn't define. */ -/* #undef gid_t */ - -/* Define to `int' if doesn't define. */ -/* #undef uid_t */ -- 2.11.0