diff --git a/network/library/serf/actions.py b/network/library/serf/actions.py new file mode 100644 index 0000000000..3190576e9c --- /dev/null +++ b/network/library/serf/actions.py @@ -0,0 +1,18 @@ +#!/usr/bin/python +# -*- coding: utf-8 -*- +# +# Licensed under the GNU General Public License, version 3. +# See the file http://www.gnu.org/licenses/gpl.txt + +from pisi.actionsapi import pisitools +from pisi.actionsapi import scons + +def build(): + scons.make("PREFIX=/usr/ LIBDIR=/usr/lib") + +def install(): + pisitools.insinto("/usr/include/serf-1/", "serf*.h") + pisitools.insinto("/usr/lib/", "libserf-1*") + pisitools.insinto("/usr/lib/pkgconfig/", "serf-1.pc") + + pisitools.dodoc("CHANGES", "LICENSE", "NOTICE", "README") \ No newline at end of file diff --git a/network/library/serf/pspec.xml b/network/library/serf/pspec.xml new file mode 100644 index 0000000000..15dada197d --- /dev/null +++ b/network/library/serf/pspec.xml @@ -0,0 +1,79 @@ + + + + + serf + https://code.google.com/p/serf/ + + Osman Erkan + osman.erkan@pisilinux.org + + Apachev2 + library + High-performance asynchronous HTTP client library. + The serf library is a high performance C-based HTTP client library built upon the Apache Portable Runtime (APR) library. + http://serf.googlecode.com/svn/src_releases/serf-1.3.8.tar.bz2 + + db-devel + zlib-devel + expat-devel + openssl-devel + apr-devel + apr-util-devel + scons + + + + + serf + + db + zlib + expat + openssl + apr + apr-util + openldap-client + + + /usr/lib + /usr/share/doc + + + + + serf-devel + Development files for serf + + serf + + + /usr/include + /usr/lib/pkgconfig + + + + + + 2015-09-02 + 1.3.8 + Version bump. + Ertuğrul Erata + ertugrulerata@gmail.com + + + 2014-05-30 + 1.3.3 + Rebuild. + Alihan Öztürk + alihan@pisilinux.org + + + 2013-12-24 + 1.3.3 + First release + Osman Erkan + osman.erkan@pisilinux.org + + + diff --git a/network/library/serf/translations.xml b/network/library/serf/translations.xml new file mode 100644 index 0000000000..d1ec00cb1d --- /dev/null +++ b/network/library/serf/translations.xml @@ -0,0 +1,13 @@ + + + + serf + High-performance asynchronous HTTP client library. + The serf library is a high performance C-based HTTP client library built upon the Apache Portable Runtime (APR) library. + + + + serf-devel + serf için geliştirme dosyaları + + \ No newline at end of file diff --git a/programming/scm/subversion/actions.py b/programming/scm/subversion/actions.py new file mode 100644 index 0000000000..6aa504cf0b --- /dev/null +++ b/programming/scm/subversion/actions.py @@ -0,0 +1,89 @@ +#!/usr/bin/python +# -*- coding: utf-8 -*- +# +# Licensed under the GNU General Public License, version 3. +# See the file http://www.gnu.org/licenses/gpl.txt + +from pisi.actionsapi import get +from pisi.actionsapi import autotools +from pisi.actionsapi import pisitools +from pisi.actionsapi import shelltools +from pisi.actionsapi import perlmodules + +def setup(): + # Respect the user LDFLAGS + shelltools.system("./autogen.sh") + + shelltools.export("EXTRA_LDFLAGS", get.LDFLAGS()) + + autotools.configure("--disable-static \ + --with-jdk=/usr/lib/jvm/java-7-openjdk \ + --enable-javahl \ + --with-apr=/usr \ + --with-apr-util=/usr \ + --with-apache=/usr/lib/apache2/ \ + --with-apxs \ + --with-serf=/usr \ + --with-sqlite=/usr \ + --with-zlib=/usr \ + --with-jikes=no \ + --without-berkeley-db \ + --disable-mod-activation") + + pisitools.dosed("libtool"," -shared ", " -Wl,--as-needed -shared ") + +def build(): + # svn + autotools.make() + + # python bindings + autotools.make("swig-py") + + # perl bindings (needed by git-svn*) + # Sometimes parallel build breaks perl bindings + autotools.make("-j1 swig-pl") + + # java bindings + autotools.make("-j1 javahl") + +def install(): + # install svn + autotools.rawInstall("DESTDIR=%s" % get.installDIR()) + + # install swig-py + autotools.rawInstall("DESTDIR=%s" % get.installDIR(), "install-swig-py") + + # install swig-pl + autotools.rawInstall("DESTDIR=%s" % get.installDIR(), "install-swig-pl") + + # install javahl + autotools.rawInstall("DESTDIR=%s" % get.installDIR(), "install-javahl") + + # Move py/c'into proper dir + pisitools.domove("/usr/lib/svn-python/svn", "/usr/lib/%s/site-packages" % get.curPYTHON()) + pisitools.domove("/usr/lib/svn-python/libsvn", "/usr/lib/%s/site-packages" % get.curPYTHON()) + pisitools.removeDir("/usr/lib/svn-python") + + # some helper tools + pisitools.insinto("/usr/bin", "tools/backup/hot-backup.py", "svn-hot-backup") + # FIXME: these tools are replaced by new ones + # pisitools.insinto("/usr/bin", "contrib/client-side/svn_load_dirs.pl", "svn-load-dirs") + # pisitools.insinto("/usr/bin", "contrib/client-side/svnmerge.py", "svnmerge") + # shelltools.chmod("%s/usr/bin/svnmerge" % get.installDIR(), 0755) + + # Install upstream bash completion script + pisitools.insinto("/etc/bash_completion.d", "tools/client-side/bash_completion", "subversion") + + # Documentation and etc. + #pisitools.insinto("/usr/share/doc/%s" % get.srcNAME(), "contrib") + pisitools.insinto("/usr/share/doc/%s" % get.srcNAME(), "tools/xslt") + pisitools.insinto("/var/www/localhost/htdocs", "tools/xslt/*") + + # Create virtual repository root + pisitools.dodir("/var/svn") + + pisitools.dodoc("README") + + # remove unnecessary files i.e. perllocal.pod, .packlist + perlmodules.removePacklist() + perlmodules.removePodfiles() diff --git a/programming/scm/subversion/comar/package.py b/programming/scm/subversion/comar/package.py new file mode 100644 index 0000000000..5e999a254c --- /dev/null +++ b/programming/scm/subversion/comar/package.py @@ -0,0 +1,12 @@ +#!/usr/bin/python + +import os + +def postInstall(fromVersion, fromRelease, toVersion, toRelease): + os.system("/bin/mkdir -p /var/svn/conf") + os.system("/usr/bin/svnadmin create /var/svn/repos") + + os.system("/bin/chmod -R 774 /var/svn/repos") + os.system("/bin/chmod 775 /var/svn/repos") + + os.system("/bin/chown -R svn:svn /var/svn") diff --git a/programming/scm/subversion/comar/service.py b/programming/scm/subversion/comar/service.py new file mode 100644 index 0000000000..605a5474e8 --- /dev/null +++ b/programming/scm/subversion/comar/service.py @@ -0,0 +1,25 @@ +from comar.service import * + +serviceType = "server" +serviceDesc = _({"en": "SVN Server", + "tr": "SVN Sunucusu"}) +serviceConf = "svnserve" + +PIDFILE = "/var/svn/svnserve.pid" + +# Note that "/etc/conf.d/svnserve" passes --root=/var/svn by default + +@synchronized +def start(): + startService(command="/usr/bin/svnserve", + args="--pid-file=%s %s" % (PIDFILE, config.get("SVNSERVE_OPTS")), + chuid="%s:%s" % (config.get("SVNSERVE_USER"), config.get("SVNSERVE_GROUP")), + donotify=True) + +@synchronized +def stop(): + stopService(pidfile=PIDFILE, + donotify=True) + +def status(): + return isServiceRunning(pidfile=PIDFILE) diff --git a/programming/scm/subversion/files/47_mod_dav_svn.conf b/programming/scm/subversion/files/47_mod_dav_svn.conf new file mode 100644 index 0000000000..66b6c1457a --- /dev/null +++ b/programming/scm/subversion/files/47_mod_dav_svn.conf @@ -0,0 +1,51 @@ +LoadModule dav_module modules/mod_dav.so +LoadModule dav_svn_module modules/mod_dav_svn.so +LoadModule authz_svn_module modules/mod_authz_svn.so + +# To serve all repositories under SVNParentPath with same configuration + +DAV svn +SVNParentPath /var/svn/repos +SVNIndexXSLT "/svnindex.xsl" +#AuthType Basic +#AuthName "Subversion repository" +#AuthUserFile /var/svn/conf/svnusers_default +#Require valid-user + + +# +# Example configuration to enable HTTP access for a directory +# containing Subversion repositories, "/var/www/svn". Each repository +# must be both: +# +# a) readable and writable by the 'apache' user, and +# +# b) labelled with the 'httpd_sys_content_t' context if using +# SELinux +# + +# +# To create a new repository "http://localhost/repos/stuff" using +# this configuration, run as root: +# +# # cd /var/www/svn +# # svnadmin create stuff +# # chown -R apache.apache stuff +# # chcon -R -t httpd_sys_content_t stuff +# + +# +# DAV svn +# SVNParentPath /var/www/svn +# +# # Limit write permission to list of valid users. +# +# # Require SSL connection for password protection. +# # SSLRequireSSL +# +# AuthType Basic +# AuthName "Authorization Realm" +# AuthUserFile /path/to/passwdfile +# Require valid-user +# +# diff --git a/programming/scm/subversion/files/dont_compile_pyc.patch b/programming/scm/subversion/files/dont_compile_pyc.patch new file mode 100644 index 0000000000..aac7322652 --- /dev/null +++ b/programming/scm/subversion/files/dont_compile_pyc.patch @@ -0,0 +1,14 @@ +diff -ur subversion-1.4.0.orig/Makefile.in subversion-1.4.0/Makefile.in +--- subversion-1.4.0.orig/Makefile.in 2006-11-06 16:36:17.000000000 +0200 ++++ subversion-1.4.0/Makefile.in 2006-11-06 16:50:14.000000000 +0200 +@@ -209,10 +209,6 @@ + $(INSTALL_DATA) "$$i" $(DESTDIR)$(swig_pydir); \ + done; \ + fi; \ +- $(PYTHON) -c 'import compileall; \ +- compileall.compile_dir("$(DESTDIR)$(swig_pydir)", 1, "$(swig_pydir)"); \ +- compileall.compile_dir("$(DESTDIR)$(swig_pydir_extra)", 1, \ +- "$(swig_pydir_extra)");' + + # The path to generated and complementary source files for the SWIG + # bindings. diff --git a/programming/scm/subversion/files/subversion-1.8.0-kwallet.patch b/programming/scm/subversion/files/subversion-1.8.0-kwallet.patch new file mode 100644 index 0000000000..1a95da30f6 --- /dev/null +++ b/programming/scm/subversion/files/subversion-1.8.0-kwallet.patch @@ -0,0 +1,27 @@ + +The first half of this is certainly upstream-worthy, but the second half is presumably +some Fedora-specific KDE packaging thing. It's not obvious how to get +kde4-config to report the directory which contains the .so files. + +--- subversion-1.8.0/build/ac-macros/kwallet.m4.kwallet ++++ subversion-1.8.0/build/ac-macros/kwallet.m4 +@@ -63,15 +63,15 @@ AC_DEFUN(SVN_LIB_KWALLET, + fi + done + qt_include_dirs="`$PKG_CONFIG --cflags-only-I QtCore QtDBus QtGui`" +- kde_dir="`$KDE4_CONFIG --prefix`" +- SVN_KWALLET_INCLUDES="$DBUS_CPPFLAGS $qt_include_dirs -I$kde_dir/include" ++ kde_include_dirs="-I`$KDE4_CONFIG --path include`" ++ SVN_KWALLET_INCLUDES="$DBUS_CPPFLAGS $qt_include_dirs $kde_include_dirs" + qt_libs_other_options="`$PKG_CONFIG --libs-only-other QtCore QtDBus QtGui`" + SVN_KWALLET_LIBS="$DBUS_LIBS -lQtCore -lQtDBus -lQtGui -lkdecore -lkdeui $qt_libs_other_options" + CXXFLAGS="$CXXFLAGS $SVN_KWALLET_INCLUDES" + LIBS="$LIBS $SVN_KWALLET_LIBS" + qt_lib_dirs="`$PKG_CONFIG --libs-only-L QtCore QtDBus QtGui`" + kde_lib_suffix="`$KDE4_CONFIG --libsuffix`" +- LDFLAGS="$old_LDFLAGS `SVN_REMOVE_STANDARD_LIB_DIRS($qt_lib_dirs -L$kde_dir/lib$kde_lib_suffix)`" ++ LDFLAGS="$old_LDFLAGS `SVN_REMOVE_STANDARD_LIB_DIRS($qt_lib_dirs)` -L$libdir/kde4/devel" + AC_LANG(C++) + AC_LINK_IFELSE([AC_LANG_SOURCE([[ + #include + diff --git a/programming/scm/subversion/files/subversion-1.8.0-pie.patch b/programming/scm/subversion/files/subversion-1.8.0-pie.patch new file mode 100644 index 0000000000..411ec30701 --- /dev/null +++ b/programming/scm/subversion/files/subversion-1.8.0-pie.patch @@ -0,0 +1,56 @@ +diff -uap subversion-1.7.0/build/generator/gen_base.py.pie subversion-1.7.0/build/generator/gen_base.py +--- subversion-1.8.0/build/generator/gen_base.py.pie ++++ subversion-1.8.0/build/generator/gen_base.py +@@ -409,7 +409,7 @@ class TargetLinked(Target): + self.install = options.get('install') + self.compile_cmd = options.get('compile-cmd') + self.sources = options.get('sources', '*.c *.cpp') +- self.link_cmd = options.get('link-cmd', '$(LINK)') ++ self.link_cmd = options.get('link-cmd', '$(LINK_LIB)') + + self.external_lib = options.get('external-lib') + self.external_project = options.get('external-project') +@@ -465,6 +465,11 @@ class TargetExe(TargetLinked): + self.manpages = options.get('manpages', '') + self.testing = options.get('testing') + ++ if self.install == 'test' or self.install == 'bdb-test': ++ self.link_cmd = '$(LINK_TEST)' ++ else: ++ self.link_cmd = '$(LINK_EXE)' ++ + def add_dependencies(self): + TargetLinked.add_dependencies(self) + +@@ -515,8 +520,8 @@ class TargetLib(TargetLinked): + self.msvc_export = options.get('msvc-export', '').split() + + ### hmm. this is Makefile-specific +- if self.link_cmd == '$(LINK)': +- self.link_cmd = '$(LINK_LIB)' ++ if self.install == 'test': ++ self.link_cmd = '$(LINK_TEST_LIB)' + + class TargetApacheMod(TargetLib): + +--- subversion-1.8.0/Makefile.in.pie ++++ subversion-1.8.0/Makefile.in +@@ -203,6 +203,9 @@ COMPILE_CXXHL_CXX = $(LIBTOOL) $(LTCXXFL + + LINK = $(LIBTOOL) $(LTFLAGS) --mode=link $(CC) $(LT_LDFLAGS) $(CFLAGS) $(LDFLAGS) + LINK_LIB = $(LINK) $(LT_SO_VERSION) -rpath $(libdir) ++LINK_TEST = $(LINK) -no-install ++LINK_TEST_LIB = $(LINK) -avoid-version ++LINK_EXE = $(LINK) -pie + LINK_CXX = $(LIBTOOL) $(LTCXXFLAGS) --mode=link $(CXX) $(LT_LDFLAGS) $(CXXFLAGS) $(LDFLAGS) -rpath $(libdir) + LINK_CXX_LIB = $(LINK_CXX) $(LT_SO_VERSION) + +@@ -676,7 +679,7 @@ schema-clean: + $(PYTHON) $(top_srcdir)/build/transform_sql.py $< $(top_srcdir)/$@ + + .c.o: +- $(COMPILE) -o $@ -c $< ++ $(COMPILE) -fpie -o $@ -c $< + + .cpp.o: + $(COMPILE_CXX) -o $@ -c $< \ No newline at end of file diff --git a/programming/scm/subversion/files/subversion-1.8.0-rpath.patch b/programming/scm/subversion/files/subversion-1.8.0-rpath.patch new file mode 100644 index 0000000000..adf12c05a1 --- /dev/null +++ b/programming/scm/subversion/files/subversion-1.8.0-rpath.patch @@ -0,0 +1,46 @@ +diff -uap subversion-1.7.0/build.conf.rpath subversion-1.7.0/build.conf +--- subversion-1.8.0/build.conf.rpath ++++ subversion-1.8.0/build.conf +@@ -501,7 +501,7 @@ type = swig_lib + lang = python + path = subversion/bindings/swig/python/libsvn_swig_py + libs = libsvn_client libsvn_wc libsvn_ra libsvn_delta libsvn_subr apriconv apr +-link-cmd = $(LINK) ++link-cmd = $(LINK_LIB) + install = swig-py-lib + # need special build rule to include -DSWIGPYTHON + compile-cmd = $(COMPILE_SWIG_PY) +@@ -524,7 +524,7 @@ type = swig_lib + lang = ruby + path = subversion/bindings/swig/ruby/libsvn_swig_ruby + libs = libsvn_client libsvn_wc libsvn_delta libsvn_subr apriconv apr +-link-cmd = $(LINK) $(SWIG_RB_LIBS) ++link-cmd = $(LINK_LIB) $(SWIG_RB_LIBS) + install = swig-rb-lib + # need special build rule to include + compile-cmd = $(COMPILE_SWIG_RB) +--- subversion-1.8.0/build/generator/gen_base.py.rpath ++++ subversion-1.8.0/build/generator/gen_base.py +@@ -514,6 +514,10 @@ class TargetLib(TargetLinked): + self.msvc_fake = options.get('msvc-fake') == 'yes' # has fake target + self.msvc_export = options.get('msvc-export', '').split() + ++ ### hmm. this is Makefile-specific ++ if self.link_cmd == '$(LINK)': ++ self.link_cmd = '$(LINK_LIB)' ++ + class TargetApacheMod(TargetLib): + + def __init__(self, name, options, gen_obj): +--- subversion-1.8.0/Makefile.in.rpath ++++ subversion-1.8.0/Makefile.in +@@ -201,8 +201,8 @@ COMPILE_JAVAHL_JAVAH = $(JAVAH) + # special compilation for files destined for cxxhl + COMPILE_CXXHL_CXX = $(LIBTOOL) $(LTCXXFLAGS) --mode=compile $(COMPILE_CXX) $(LT_CFLAGS) $(CXXHL_INCLUDES) -o $@ -c + +-LINK = $(LIBTOOL) $(LTFLAGS) --mode=link $(CC) $(LT_LDFLAGS) $(CFLAGS) $(LDFLAGS) -rpath $(libdir) +-LINK_LIB = $(LINK) $(LT_SO_VERSION) ++LINK = $(LIBTOOL) $(LTFLAGS) --mode=link $(CC) $(LT_LDFLAGS) $(CFLAGS) $(LDFLAGS) ++LINK_LIB = $(LINK) $(LT_SO_VERSION) -rpath $(libdir) + LINK_CXX = $(LIBTOOL) $(LTCXXFLAGS) --mode=link $(CXX) $(LT_LDFLAGS) $(CXXFLAGS) $(LDFLAGS) -rpath $(libdir) + LINK_CXX_LIB = $(LINK_CXX) $(LT_SO_VERSION) \ No newline at end of file diff --git a/programming/scm/subversion/files/subversion-swig-perl-install_vendor.patch b/programming/scm/subversion/files/subversion-swig-perl-install_vendor.patch new file mode 100644 index 0000000000..b8c1937f70 --- /dev/null +++ b/programming/scm/subversion/files/subversion-swig-perl-install_vendor.patch @@ -0,0 +1,14 @@ + Makefile.in | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/Makefile.in ++++ b/Makefile.in +@@ -652,7 +652,7 @@ check-swig-pl: swig-pl swig-pl-lib + cd $(SWIG_PL_DIR)/native; $(MAKE) test + + install-swig-pl: swig-pl install-swig-pl-lib +- cd $(SWIG_PL_DIR)/native; $(MAKE) install ++ cd $(SWIG_PL_DIR)/native; $(MAKE) install_vendor + + EXTRACLEAN_SWIG_PL=rm -f $(SWIG_PL_SRC_DIR)/native/svn_*.c \ + $(SWIG_PL_SRC_DIR)/native/core.c diff --git a/programming/scm/subversion/files/subversion.config b/programming/scm/subversion/files/subversion.config new file mode 100644 index 0000000000..1f29533f92 --- /dev/null +++ b/programming/scm/subversion/files/subversion.config @@ -0,0 +1,13 @@ +[miscellany] +enable-auto-props = yes + +[auto-props] +*.png = svn:mime-type=image/png +*.jpg = svn:mime-type=image/jpeg +*.jpe = svn:mime-type=image/jpeg +*.jpeg = svn:mime-type=image/jpeg +*.bmp = svn:mime-type=image/x-ms-bmp +*.odp = svn:mime-type=application/vnd.oasis.opendocument.presentation +*.odt = svn:mime-type=application/vnd.oasis.opendocument.text +*.ods = svn:mime-type=application/vnd.oasis.opendocument.spreadsheet +*.ogg = svn:mime-type=audio/ogg diff --git a/programming/scm/subversion/files/subversion.perl.LD_RUN_PATH.patch b/programming/scm/subversion/files/subversion.perl.LD_RUN_PATH.patch new file mode 100644 index 0000000000..3b21e6577f --- /dev/null +++ b/programming/scm/subversion/files/subversion.perl.LD_RUN_PATH.patch @@ -0,0 +1,19 @@ +clear LD_RUN_PATH, it will end up as RPATH in ELF binaries + +ERROR: RPATH "/usr/src/packages/BUILD/subversion-1.5.x/subversion/libsvn_subr/.libs" on /var/tmp/subversion-1.5.0-build/usr/lib/perl5/vendor_perl/5.10.0/ppc-linux-thread-multi-64int/auto/SVN/_Wc/_Wc.so is not allowed + +--- + Makefile.in | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +--- a/Makefile.in ++++ b/Makefile.in +@@ -641,7 +641,7 @@ $(SWIG_PL_DIR)/native/Makefile.PL: $(SWI + ./config.status subversion/bindings/swig/perl/native/Makefile.PL + + $(SWIG_PL_DIR)/native/Makefile: $(SWIG_PL_DIR)/native/Makefile.PL +- cd $(SWIG_PL_DIR)/native; $(PERL) Makefile.PL ++ cd $(SWIG_PL_DIR)/native; $(PERL) Makefile.PL ; for i in `grep -wl ^LD_RUN_PATH Makefile Makefile.[^P]*` ; do sed -i 's@^LD_RUN_PATH.*@LD_RUN_PATH=@' $$i ; done + + swig-pl_DEPS = autogen-swig-pl libsvn_swig_perl \ + $(SWIG_PL_DIR)/native/Makefile diff --git a/programming/scm/subversion/files/subversion.rpath.fix.patch b/programming/scm/subversion/files/subversion.rpath.fix.patch new file mode 100644 index 0000000000..aaec8fdb71 --- /dev/null +++ b/programming/scm/subversion/files/subversion.rpath.fix.patch @@ -0,0 +1,11 @@ +--- Makefile.in.orig 2009-02-16 14:10:48.000000000 -0200 ++++ Makefile.in 2009-06-04 00:56:29.000000000 -0300 +@@ -678,6 +678,7 @@ + + $(SWIG_PL_DIR)/native/Makefile: $(SWIG_PL_DIR)/native/Makefile.PL + cd $(SWIG_PL_DIR)/native; $(PERL) Makefile.PL PREFIX=$(prefix) ++ cd $(SWIG_PL_DIR)/native; sed -i 's|LD_RUN_PATH|DIE_RPATH_DIE|g' Makefile{,.{client,delta,fs,ra,repos,wc}} + + # There is a "readlink -f" command on some systems for the same purpose, + # but it's not as portable (e.g. Mac OS X doesn't have it). These should + # only be used where Python/Perl are known to be available. diff --git a/programming/scm/subversion/files/svn-clean b/programming/scm/subversion/files/svn-clean new file mode 100644 index 0000000000..3cd094499f --- /dev/null +++ b/programming/scm/subversion/files/svn-clean @@ -0,0 +1,113 @@ +#! /usr/bin/perl + +# +# This script recursively (beginning with the current directory) +# wipes out everything not registered in SVN. +# +# rewritten in perl by Oswald Buddenhagen +# based on bash version by Thiago Macieira +# inspired by cvs-clean, written by Oswald Buddenhagen +# inspired by the "old" cvs-clean target from Makefile.common +# +# This file is free software in terms of the BSD licence. That means +# that you can do anything with it except removing this license or +# the above copyright notice. There is NO WARRANTY of any kind. +# + +# Warning: +# This script processes the output from the SVN executable +# Do not run it along with colorsvn + +use File::Path; + +my $version = "svn-clean v1.0"; +my $heading = $version.": cleans up the Subversion working directory\n"; +my $usage = $heading. + "svn-clean [-h] [-n] [-q] [-i|-f] [dirname]\n\n". + "Where:\n". + " -h shows this help screen\n". + " -n dry-run: doesn't actually erase the files, just show their names\n". + " -i interactive: ask for confirmation before erasing the files\n". + " -f force: doesn't ask for confirmation before erasing\n". + " -q quiet: doesn't show output\n"; + + +my $dry_run = 0; +my $force = 0; +my $quiet = 0; + +sub check_confirm() +{ + return if ($force); + + open(TTY, "+< /dev/tty") or die "cannot open /dev/tty"; + + print TTY "This will erase files and directories that aren't in Subversion\n". + "Are you sure you want to continue? (y/n) "; + + if ( =~ /^[Yy]/) { + $force = 1; + close TTY; + return; + } + + # user cancelled + exit 0; +} + +# Parse arguments +my $rest = 0; +my @files = (); +foreach my $arg (@ARGV) { + if ($rest) { + push @files, $arg; + } else { + if ($arg eq '-h' || $arg eq '--help') { + print $usage; + exit (0); + } elsif ($arg eq '-n' || $arg eq '--dry-run') { + $dry_run = 1; + $force = 1; + } elsif ($arg eq '-f' || $arg eq '--force') { + $force = 1; + } elsif ($arg eq '-i' || $arg eq '--interactive') { + $force = 0; + } elsif ($arg eq '-q' || $arg eq '--quiet') { + $quiet = 1; + } elsif ($arg eq '--') { + $rest = 1; + } elsif ($arg =~ /^-/) { + print STDERR "svn-clean: unknown argument '".$arg."'\n\n".$usage; + exit (1); + } else { + push @files, $arg; + } + } +} +if (!@files) { + push @files, '.'; +} + +# Unset TERM just so that no colours are output +# in case $SVN points to colorsvn +delete $ENV{'TERM'}; + +#print($heading."\n") unless $quiet; + +foreach my $dir (@files) { + open SVN, "svn status --no-ignore \"".$dir."\"|"; + while () { + /^[I?] +(.*)$/ or next; + my $file = $1; + check_confirm(); + lstat $file; + if (-d _) { + print("D ".$file."\n") unless $quiet; + rmtree($file, 0, 0) unless $dry_run; + } else { + print("F ".$file."\n") unless $quiet; + unlink($file) unless $dry_run; + } + } + close SVN; +} diff --git a/programming/scm/subversion/files/svnlastchange b/programming/scm/subversion/files/svnlastchange new file mode 100644 index 0000000000..2c5556890c --- /dev/null +++ b/programming/scm/subversion/files/svnlastchange @@ -0,0 +1,20 @@ +#!/bin/sh + +if [ $# -eq 0 ]; then + cat < [ ...] + +EOF + exit 1 +fi + +if [ "$1" == "-q" ]; then + shift +else + echo >/dev/tty "Hint: Use svn log -r COMMITTED and svn diff -r PREV:COMMITTED" +fi + +svn log -r COMMITTED "$*" +svn diff -r PREV:COMMITTED "$*" || \ + echo >&2 "Error retrieving diff: the file was probably added in the last revision" \ No newline at end of file diff --git a/programming/scm/subversion/files/svnlastlog b/programming/scm/subversion/files/svnlastlog new file mode 100644 index 0000000000..615da7f6ab --- /dev/null +++ b/programming/scm/subversion/files/svnlastlog @@ -0,0 +1,15 @@ +#!/bin/sh +# This is a stripped down version of svnlastchange + +if [ $# -eq 0 ]; then + cat < [ ...] + +EOF + exit 1 +fi +echo >&2 "Warning: svnlastlog is superfluous" +echo >&2 "Use svn log -r COMMITTED" + +svn log -r COMMITTED "$*" diff --git a/programming/scm/subversion/files/svnrevertlast b/programming/scm/subversion/files/svnrevertlast new file mode 100644 index 0000000000..14348f294f --- /dev/null +++ b/programming/scm/subversion/files/svnrevertlast @@ -0,0 +1,6 @@ +#!/bin/sh +echo >&2 "Warning: this script is superfluous" +echo >&2 "Instead, use: svn merge -rBASE:PREV " +echo >&2 + +svn merge -r BASE:PREV "$@" diff --git a/programming/scm/subversion/files/svnserve.confd b/programming/scm/subversion/files/svnserve.confd new file mode 100644 index 0000000000..2855a40b5e --- /dev/null +++ b/programming/scm/subversion/files/svnserve.confd @@ -0,0 +1,8 @@ +# Default svnserve configuration for Pisi Linux + +# Options for svnserve +SVNSERVE_OPTS = "--daemon --root=/var/svn" + +# User and group as which to run svnserve +SVNSERVE_USER="svn" +SVNSERVE_GROUP="svn" diff --git a/programming/scm/subversion/pspec.xml b/programming/scm/subversion/pspec.xml new file mode 100644 index 0000000000..86117008f7 --- /dev/null +++ b/programming/scm/subversion/pspec.xml @@ -0,0 +1,225 @@ + + + + + subversion + http://subversion.apache.org/ + + PisiLinux Community + admins@pisilinux.org + + Subversion + app:console + service + A compelling replacement for CVS + SVN is a version controlling system to store files and control their change history in a repository. + http://archive.apache.org/dist/subversion/subversion-1.9.1.tar.bz2 + + apache + expat-devel + zlib-devel + ruby-devel + serf-devel + sqlite-devel + jdk7-openjdk + apr-util-devel + cyrus-sasl-devel + python-devel + dbus-devel + glib2-devel + openssl-devel + swig + + + + subversion-swig-perl-install_vendor.patch + subversion.rpath.fix.patch + dont_compile_pyc.patch + + + + + subversion + + file + zlib + expat + libgcc + sqlite + apr + serf + apr-util + cyrus-sasl + + + + /etc/conf.d + /etc/subversion + /etc/bash_completion.d + /usr/share/build + /usr/bin + /usr/lib + /usr/share/doc + /usr/share/info + /usr/share/locale + /usr/share/man + /var/svn + + + svnserve.confd + + + + + subversion.config + + + System.Service + System.Package + + + + + subversion-devel + Development files for subversion + + openssl-devel + apr-devel + serf-devel + sqlite-devel + apr-util-devel + subversion + + + /usr/include + /usr/share/pkgconfig + + + + + mod_dav_svn + server.web + + apr + apache + apr-util + subversion + + + /usr/lib/apache2 + /usr/libexec/mod_dav_svn.so + /usr/libexec/mod_authz_svn.so + /etc/apache2/modules.d + /var/www/localhost/htdocs + + + 47_mod_dav_svn.conf + + + System.Package + + + + + + 2015-09-04 + 1.9.1 + Version bump. + Ertuğrul Erata + ertugrulerata@gmail.com + + + 2015-04-04 + 1.8.13 + Version bump. + Yusuf Aydemir + yusuf.aydemir@pisilinux.org + + + 2014-09-14 + 1.8.10 + Version bump. + Serdar Soytetir + kaptan@pisilinux.org + + + 2014-06-21 + 1.8.9 + Version bump. + Alihan Öztürk + alihan@pisilinux.org + + + 2014-04-03 + 1.8.8 + Version bump. + Serdar Soytetir + kaptan@pisilinux.org + + + 2014-03-03 + 1.8.5 + rebuild for openjdk + Kamil Atlı + suvarice@gmail.com + + + 2014-01-11 + 1.8.5 + rebuild for cyrus-sasl + Kamil Atlı + suvarice@gmail.com + + + 2013-12-28 + 1.8.5 + Fix Deps + Osman Erkan + osman.erkan@pisilinux.org + + + 2013-12-24 + 1.8.5 + Version bump, fix deps, add mandatory serf dependency. + Serdar Soytetir + kaptan@pisilinux.org + + + 2013-11-30 + 1.8.1 + rebuild for perl-svn-simple + Kamil Atlı + suvarice@gmail.com + + + 2013-08-17 + 1.8.1 + Dep Fixed + Osman Erkan + osman.erkan@pisilinux.org + + + 2013-08-03 + 1.8.1 + + *Version bump to 1.8.1 + *Disable neon as suggested in http://subversion.apache.org/docs/release-notes/1.8.html#neon-deleted + + Fatih Turgel + hitaf@pisilinux.org + + + 2012-10-24 + 1.7.7 + First release + Yusuf Aydemir + yusuf.aydemir@pisilinux.org + + + diff --git a/programming/scm/subversion/translations.xml b/programming/scm/subversion/translations.xml new file mode 100644 index 0000000000..81197debbf --- /dev/null +++ b/programming/scm/subversion/translations.xml @@ -0,0 +1,14 @@ + + + + subversion + Bir sürüm kontrol sistemi + Daha gelişmiş özellikleri olan ve önceki CVS yerine kullanılan, bir sürüm yönetim sistemidir. + SVN est un gestionnaire de configuration permettant de stocker des fichiers et de contrôler leur historique de changement dans un dépôt. + + + + subversion-devel + Subversion için geliştirme dosyaları + + diff --git a/server/web/apache/actions.py b/server/web/apache/actions.py new file mode 100644 index 0000000000..89eb5e677f --- /dev/null +++ b/server/web/apache/actions.py @@ -0,0 +1,148 @@ +#!/usr/bin/python +# -*- coding: utf-8 -*- +# +# Licensed under the GNU General Public License, version 3. +# See the file http://www.gnu.org/licenses/gpl.txt + +from pisi.actionsapi import autotools +from pisi.actionsapi import pisitools +from pisi.actionsapi import shelltools +from pisi.actionsapi import get + +WorkDir = "httpd-%s" % get.srcVERSION() + +def config_layout(): + return """ + + prefix: /usr + exec_prefix: /usr + bindir: /usr/bin + sbindir: /usr/sbin + libdir: /usr/lib + libexecdir: /usr/lib/apache2/modules + mandir: /usr/share/man + infodir: /usr/share/info + includedir: /usr/include/apache2 + installbuilddir: /usr/lib/apache2/build + datadir: /var/www/localhost + errordir: /var/www/localhost/error + iconsdir: /var/www/localhost/icons + htdocsdir: /var/www/localhost/htdocs + cgidir: /var/www/localhost/cgi-bin + manualdir: /usr/share/doc/version/manual + sysconfdir: /etc/apache2 + localstatedir: /var + runtimedir: /run + logfiledir: /var/log/apache2 + proxycachedir: /var/cache/apache2 +""" + +def modules_config(): + disabled = ['bucketeer', 'example', 'optional-fn-export', 'optional-fn-import', + 'optional-hook-export','optional-hook-import'] + + static = ['so'] + + # auth_ldap, ldap needed + shared = ['actions', 'alias', 'asis', 'auth_basic', 'authn_dbm', 'authn_file', + 'auth_digest', 'authz_host', 'autoindex', 'cache', 'case_filter', + 'case-filter-in', 'cern-meta', 'cgi', 'cgid', 'charset-lite', 'dav', + 'dav-fs', 'deflate', 'dir', 'disk-cache', 'echo', 'env', 'expires', + 'ext-filter', 'file-cache', 'headers', 'imagemap', 'include', 'info', + 'log_config', 'logio', 'mem-cache', 'mime', 'mime-magic', 'negotiation', + 'proxy', 'proxy-connect','proxy-ftp', 'proxy-http', 'rewrite', 'setenvif', + 'speling', 'status', 'unique-id', 'userdir', 'usertrack', 'vhost-alias'] + + conf = "" + + for i in disabled: + conf += "--disable-%s " % i + for i in static: + conf += "--enable-%s=yes " % i + for i in shared: + conf += "--enable-%s=shared " % i + + return conf + +def setup(): + shelltools.echo("config.layout", config_layout()) + pisitools.dosed("config.layout", "version", get.srcNAME()) + + #for d in ["apr","apr-util","pcre"]: + #shelltools.unlinkDir("srclib/%s" % d) + + # this fixes segfaults, remember omit-frame-pointer will be default soon + if get.ARCH() == "i686": + shelltools.export("CFLAGS", "%s -fno-omit-frame-pointer" % get.CFLAGS()) + shelltools.export("LDFLAGS", "-Wl,-z,relro,-z,now") + + autotools.rawConfigure('--with-mpm=prefork \ + --enable-layout=PisiLinux \ + --enable-mods-shared=all \ + --with-ssl=/usr \ + --enable-ssl=shared \ + %s \ + --with-z=/usr \ + --with-port=80 \ + --with-program-name=apache2 \ + --with-apr=/usr/bin/apr-1-config \ + --with-apr-util=/usr/bin/apu-1-config \ + --with-suexec-safepath="/usr/bin:/bin" \ + --with-suexec-logfile=/var/log/apache2/suexec_log \ + --with-suexec-bin=/usr/sbin/suexec \ + --with-suexec-userdir="public_html" \ + --with-suexec-caller=apache \ + --with-suexec-docroot=/var/www \ + --with-suexec-uidmin=1000 \ + --with-suexec-gidmin=100 \ + --with-suexec-umask=077 \ + --enable-suexec=shared \ + --enable-pie \ + --with-pcre=/usr/bin/pcre-config' % modules_config()) + + pisitools.dosed("include/ap_config_auto.h", "apache2\.conf", "httpd.conf") + +def build(): + autotools.make() + +def install(): + autotools.rawInstall("DESTDIR=%s INSTALL_SUEXEC='setuid'" % get.installDIR()) + + pisitools.dosym("/usr/lib", "/usr/lib/apache2/lib") + pisitools.dosym("/var/log/apache2", "/usr/lib/apache2/logs") + pisitools.dosym("/etc/apache2", "/usr/lib/apache2/conf") + + pisitools.dosbin("support/split-logfile") + pisitools.dosbin("support/list_hooks.pl") + pisitools.dosbin("support/logresolve.pl") + pisitools.dosbin("support/log_server_status") + + pisitools.dosbin("apache2") + + pisitools.domove("/usr/sbin/envvars*", "/usr/lib/apache2/build") + pisitools.dosed("%s/usr/bin/apxs" % get.installDIR(), \ + "my \$envvars = get_vars\(\"bindir\"\) \. \"/envvars\";", \ + "my $envvars = \"$installbuilddir/envvars\";") + + # Clean-up + pisitools.remove("/etc/apache2/*") + pisitools.remove("/var/www/localhost/htdocs/*") + + # Add conf.d for 3rd party configuration files + pisitools.dodir("/etc/apache2/conf.d") + + # ssl enabled apache needs that one + pisitools.dodir("/var/cache/apache2") + + # Fix wrong libtool path + pisitools.dosed("%s/usr/lib/apache2/build/config_vars.mk" % get.installDIR(), \ + "/usr/lib/apache2/build/libtool", \ + "/usr/bin/libtool") + + # Remove cgi scripts which are vulnerable, see CVE-2007-4049 + pisitools.remove("/var/www/localhost/cgi-bin/*") + + + pisitools.dodoc("ABOUT_APACHE", "CHANGES", "LAYOUT", "LICENSE", "README*") + + pisitools.removeDir("/run") diff --git a/server/web/apache/comar/package.py b/server/web/apache/comar/package.py new file mode 100644 index 0000000000..e51c393e95 --- /dev/null +++ b/server/web/apache/comar/package.py @@ -0,0 +1,8 @@ +#!/usr/bin/python + +import os + +def postInstall(fromVersion, fromRelease, toVersion, toRelease): + os.system("/bin/chown root:apache /usr/sbin/suexec") + os.system("/bin/chmod 04710 /usr/sbin/suexec") + os.system("/bin/chown apache:apache /var/cache/apache2") diff --git a/server/web/apache/comar/service.py b/server/web/apache/comar/service.py new file mode 100644 index 0000000000..b58161d483 --- /dev/null +++ b/server/web/apache/comar/service.py @@ -0,0 +1,35 @@ +from comar.service import * + +serviceType = "server" +serviceDesc = _({"en": "Apache Web Server", + "tr": "Apache Web Sunucusu"}) + +serviceConf = "apache2" + +PIDFILE = "/run/apache2.pid" + +@synchronized +def start(): + import os + os.environ["LC_ALL"] = "C" + os.environ["LANG"] = "C" + + startService(command="/usr/sbin/apache2", + args="-d /usr/lib/apache2/ -f /etc/apache2/httpd.conf %s -k start" % config.get("APACHE2_OPTS", ""), + pidfile=PIDFILE, + donotify=True) + +@synchronized +def stop(): + stopService(command="/usr/sbin/apache2", + args="-d /usr/lib/apache2/ -f /etc/apache2/httpd.conf %s -k stop" % config.get("APACHE2_OPTS", ""), + donotify=True) + import time + time.sleep(3) + +def reload(): + stopService(command="/usr/sbin/apache2", + args="-d /usr/lib/apache2/ -f /etc/apache2/httpd.conf %s -k graceful" % config.get("APACHE2_OPTS", "")) + +def status(): + return isServiceRunning(PIDFILE) diff --git a/server/web/apache/files/00_apache_manual.conf b/server/web/apache/files/00_apache_manual.conf new file mode 100644 index 0000000000..98137d5fa2 --- /dev/null +++ b/server/web/apache/files/00_apache_manual.conf @@ -0,0 +1,10 @@ +# +# This configuration file allows the manual to be accessed at +# http://localhost/manual/ +# +AliasMatch ^/manual(?:/(?:de|en|fr|ja|ko|ru))?(/.*)?$ "/usr/share/doc/apache/manual$1" + + Options Indexes + AllowOverride None + Require all granted + \ No newline at end of file diff --git a/server/web/apache/files/00_default_vhost.conf b/server/web/apache/files/00_default_vhost.conf new file mode 100644 index 0000000000..3e03d1a120 --- /dev/null +++ b/server/web/apache/files/00_default_vhost.conf @@ -0,0 +1,92 @@ +### Section 3: Virtual Hosts +# +# VirtualHost: If you want to maintain multiple domains/hostnames on your +# machine you can setup VirtualHost containers for them. Most configurations +# use only name-based virtual hosts so the server doesn't need to worry about +# IP addresses. This is indicated by the asterisks in the directives below. +# +# Please see the documentation at +# +# for further details before you try to setup virtual hosts. +# +# You may use the command line option '-S' to verify your virtual host +# configuration. + +# +# Use name-based virtual hosting. +# +NameVirtualHost *:80 + +# +# VirtualHost example: +# Almost any Apache directive may go into a VirtualHost container. +# The first VirtualHost section is used for requests without a known +# server name. +# +# +# ServerAdmin webmaster@dummy-host.example.com +# DocumentRoot /www/docs/dummy-host.example.com +# ServerName dummy-host.example.com +# ErrorLog @rel_logfiledir@/dummy-host.example.com-error_log +# CustomLog @rel_logfiledir@/dummy-host.example.com-access_log common +# + + +# +# The First Virtual Host is also your DEFAULT Virtual Host. +# This means any requests that do not match any other vhosts will +# goto this virtual host. +# + + + + # + # DocumentRoot: The directory out of which you will serve your + # documents. By default, all requests are taken from this directory, but + # symbolic links and aliases may be used to point to other locations. + # + DocumentRoot "/var/www/localhost/htdocs" + + # + # This should be changed to whatever you set DocumentRoot to. + # + + + # + # Possible values for the Options directive are "None", "All", + # or any combination of: + # Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews + # + # Note that "MultiViews" must be named *explicitly* --- "Options All" + # doesn't give it to you. + # + # The Options directive is both complicated and important. Please see + # http://httpd.apache.org/docs-2.0/mod/core.html#options + # for more information. + # + Options Indexes FollowSymLinks + + # + # AllowOverride controls what directives may be placed in .htaccess files. + # It can be "All", "None", or any combination of the keywords: + # Options FileInfo AuthConfig Limit + # + AllowOverride None + + # + # Controls who can get stuff from this server. + # + Order allow,deny + Allow from all + + + + # this must match a Processor + ServerEnvironment apache apache + + # these are optional - defaults to the values specified in httpd.conf + MinSpareProcessors 4 + MaxProcessors 20 + + + \ No newline at end of file diff --git a/server/web/apache/files/40_mod_ssl.conf b/server/web/apache/files/40_mod_ssl.conf new file mode 100644 index 0000000000..375cf926fd --- /dev/null +++ b/server/web/apache/files/40_mod_ssl.conf @@ -0,0 +1,87 @@ + + + LoadModule ssl_module modules/mod_ssl.so + + + + +# +# This is the Apache server configuration file providing SSL support. +# It contains the configuration directives to instruct the server how to +# serve pages over an https connection. For detailing information about these +# directives see +# +# Do NOT simply read the instructions in here without understanding +# what they do. They're here only as hints or reminders. If you are unsure +# consult the online docs. You have been warned. +# + +# +# Pseudo Random Number Generator (PRNG): +# Configure one or more sources to seed the PRNG of the SSL library. +# The seed data should be of good random quality. +# WARNING! On some platforms /dev/random blocks if not enough entropy +# is available. This means you then cannot use the /dev/random device +# because it would lead to very long connection times (as long as +# it requires to make more entropy available). But usually those +# platforms additionally provide a /dev/urandom device which doesn't +# block. So, if available, use this one instead. Read the mod_ssl User +# Manual for more details. +# +# Note: This must come before the container to support +# starting without SSL on platforms with no /dev/random equivalent +# but a statically compiled-in mod_ssl. +# +SSLRandomSeed startup builtin +SSLRandomSeed connect builtin +#SSLRandomSeed startup file:/dev/random 512 +#SSLRandomSeed startup file:/dev/urandom 512 +#SSLRandomSeed connect file:/dev/random 512 +#SSLRandomSeed connect file:/dev/urandom 512 + +# +# When we also provide SSL we have to listen to the +# standard HTTP port (see above) and to the HTTPS port +# + +Listen 443 + +## +## SSL Global Context +## +## All SSL configuration in this context applies both to +## the main server and all SSL-enabled virtual hosts. +## + +# +# Some MIME-types for downloading Certificates and CRLs +# + + +AddType application/x-x509-ca-cert .crt +AddType application/x-pkcs7-crl .crl + + +# Pass Phrase Dialog: +# Configure the pass phrase gathering process. +# The filtering dialog program (`builtin' is a internal +# terminal dialog) has to provide the pass phrase on stdout. + +SSLPassPhraseDialog builtin + +# Inter-Process Session Cache: +# Configure the SSL Session Cache: First the mechanism +# to use and second the expiring timeout (in seconds). +#SSLSessionCache none +#SSLSessionCache shmht:logs/ssl_scache(512000) +#SSLSessionCache shmcb:logs/ssl_scache(512000) +#SSLSessionCache dbm:/var/cache/apache2/ssl_scache +SSLSessionCache shm:/var/cache/apache2/ssl_scache(512000) +SSLSessionCacheTimeout 300 + +# Semaphore: +# Configure the path to the mutual exclusion semaphore the +# SSL engine uses internally for inter-process synchronization. + +SSLMutex file:/var/cache/apache2/ssl_mutex + diff --git a/server/web/apache/files/41_mod_ssl.default-vhost.conf b/server/web/apache/files/41_mod_ssl.default-vhost.conf new file mode 100644 index 0000000000..3e95944db7 --- /dev/null +++ b/server/web/apache/files/41_mod_ssl.default-vhost.conf @@ -0,0 +1,190 @@ + + + # We now wrap the entire default vhost in a seperate IfDefine to fix bug + # 100624. If you are using this default vhost, add it to /etc/conf.d/apache2 + + + +## +## SSL Virtual Host Context +## + + + +# General setup for the virtual host +DocumentRoot "/var/www/localhost/htdocs" +ServerName localhost:443 +ServerAdmin root@localhost +ErrorLog logs/ssl_error_log + + TransferLog logs/ssl_access_log + + +# SSL Engine Switch: +# Enable/Disable SSL for this virtual host. +SSLEngine on + +# SSL Cipher Suite: +# List the ciphers that the client is permitted to negotiate. +# See the mod_ssl documentation for a complete list. +SSLCipherSuite ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL + +# Server Certificate: +# Point SSLCertificateFile at a PEM encoded certificate. If +# the certificate is encrypted, then you will be prompted for a +# pass phrase. Note that a kill -HUP will prompt again. A test +# certificate can be generated with `make certificate' under +# built time. Keep in mind that if you've both a RSA and a DSA +# certificate you can configure both in parallel (to also allow +# the use of DSA ciphers, etc.) +SSLCertificateFile conf/ssl/server.crt + +# Server Private Key: +# If the key is not combined with the certificate, use this +# directive to point at the key file. Keep in mind that if +# you've both a RSA and a DSA private key you can configure +# both in parallel (to also allow the use of DSA ciphers, etc.) + +SSLCertificateKeyFile conf/ssl/server.key + +# Server Certificate Chain: +# Point SSLCertificateChainFile at a file containing the +# concatenation of PEM encoded CA certificates which form the +# certificate chain for the server certificate. Alternatively +# the referenced file can be the same as SSLCertificateFile +# when the CA certificates are directly appended to the server +# certificate for convinience. +#SSLCertificateChainFile conf/ssl/ca.crt + +# Certificate Authority (CA): +# Set the CA certificate verification path where to find CA +# certificates for client authentication or alternatively one +# huge file containing all of them (file must be PEM encoded) +# Note: Inside SSLCACertificatePath you need hash symlinks +# to point to the certificate files. Use the provided +# Makefile to update the hash symlinks after changes. +#SSLCACertificatePath conf/ssl/ssl.crt +#SSLCACertificateFile conf/ssl/ca-bundle.crt + +# Certificate Revocation Lists (CRL): +# Set the CA revocation path where to find CA CRLs for client +# authentication or alternatively one huge file containing all +# of them (file must be PEM encoded) +# Note: Inside SSLCARevocationPath you need hash symlinks +# to point to the certificate files. Use the provided +# Makefile to update the hash symlinks after changes. +#SSLCARevocationPath conf/ssl/ssl.crl +#SSLCARevocationFile conf/ssl/ca-bundle.crl + +# Client Authentication (Type): +# Client certificate verification type and depth. Types are +# none, optional, require and optional_no_ca. Depth is a +# number which specifies how deeply to verify the certificate +# issuer chain before deciding the certificate is not valid. +#SSLVerifyClient require +#SSLVerifyDepth 10 + +# Access Control: +# With SSLRequire you can do per-directory access control based +# on arbitrary complex boolean expressions containing server +# variable checks and other lookup directives. The syntax is a +# mixture between C and Perl. See the mod_ssl documentation +# for more details. +# +#SSLRequire ( %{SSL_CIPHER} !~ m/^(EXP|NULL)/ \ +# and %{SSL_CLIENT_S_DN_O} eq "Snake Oil, Ltd." \ +# and %{SSL_CLIENT_S_DN_OU} in {"Staff", "CA", "Dev"} \ +# and %{TIME_WDAY} >= 1 and %{TIME_WDAY} <= 5 \ +# and %{TIME_HOUR} >= 8 and %{TIME_HOUR} <= 20 ) \ +# or %{REMOTE_ADDR} =~ m/^192\.76\.162\.[0-9]+$/ +# + +# SSL Engine Options: +# Set various options for the SSL engine. +# o FakeBasicAuth: +# Translate the client X.509 into a Basic Authorisation. This means that +# the standard Auth/DBMAuth methods can be used for access control. The +# user name is the `one line' version of the client's X.509 certificate. +# Note that no password is obtained from the user. Every entry in the user +# file needs this password: `xxj31ZMTZzkVA'. +# o ExportCertData: +# This exports two additional environment variables: SSL_CLIENT_CERT and +# SSL_SERVER_CERT. These contain the PEM-encoded certificates of the +# server (always existing) and the client (only existing when client +# authentication is used). This can be used to import the certificates +# into CGI scripts. +# o StdEnvVars: +# This exports the standard SSL/TLS related `SSL_*' environment variables. +# Per default this exportation is switched off for performance reasons, +# because the extraction step is an expensive operation and is usually +# useless for serving static content. So one usually enables the +# exportation for CGI and SSI requests only. +# o CompatEnvVars: +# This exports obsolete environment variables for backward compatibility +# to Apache-SSL 1.x, mod_ssl 2.0.x, Sioux 1.0 and Stronghold 2.x. Use this +# to provide compatibility to existing CGI scripts. +# o StrictRequire: +# This denies access when "SSLRequireSSL" or "SSLRequire" applied even +# under a "Satisfy any" situation, i.e. when it applies access is denied +# and no other module can change it. +# o OptRenegotiate: +# This enables optimized SSL connection renegotiation handling when SSL +# directives are used in per-directory context. +#SSLOptions +FakeBasicAuth +ExportCertData +CompatEnvVars +StrictRequire + + + SSLOptions +StdEnvVars + + + + SSLOptions +StdEnvVars + + +# SSL Protocol Adjustments: +# The safe and default but still SSL/TLS standard compliant shutdown +# approach is that mod_ssl sends the close notify alert but doesn't wait for +# the close notify alert from client. When you need a different shutdown +# approach you can use one of the following variables: +# o ssl-unclean-shutdown: +# This forces an unclean shutdown when the connection is closed, i.e. no +# SSL close notify alert is send or allowed to received. This violates +# the SSL/TLS standard but is needed for some brain-dead browsers. Use +# this when you receive I/O errors because of the standard approach where +# mod_ssl sends the close notify alert. +# o ssl-accurate-shutdown: +# This forces an accurate shutdown when the connection is closed, i.e. a +# SSL close notify alert is send and mod_ssl waits for the close notify +# alert of the client. This is 100% SSL/TLS standard compliant, but in +# practice often causes hanging connections with brain-dead browsers. Use +# this only for browsers where you know that their SSL implementation +# works correctly. +# Notice: Most problems of broken clients are also related to the HTTP +# keep-alive facility, so you usually additionally want to disable +# keep-alive for those clients, too. Use variable "nokeepalive" for this. +# Similarly, one has to force some clients to use HTTP/1.0 to workaround +# their broken HTTP/1.1 implementation. Use variables "downgrade-1.0" and +# "force-response-1.0" for this. + + SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown \ + downgrade-1.0 force-response-1.0 + + +# Per-Server Logging: +# The home of a custom SSL log file. Use this when you want a +# compact non-error SSL logfile on a virtual host basis. + +CustomLog logs/ssl_request_log \ + "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b" + + + +RewriteEngine On +RewriteOptions inherit + + + + + + + + diff --git a/server/web/apache/files/45_mod_dav.conf b/server/web/apache/files/45_mod_dav.conf new file mode 100644 index 0000000000..74dffd07d2 --- /dev/null +++ b/server/web/apache/files/45_mod_dav.conf @@ -0,0 +1,31 @@ + + + LoadModule dav_module modules/mod_dav.so + + + + + + LoadModule dav_fs_module modules/mod_dav_fs.so + + + + + + DavMinTimeout 600 +# +# Options None +# Dav On +# +# Require user greg +# +# + + + + + + # Location of the WebDAV lock database. + DavLockDB /var/lib/dav/lockdb + + diff --git a/server/web/apache/files/46_mod_ldap.conf b/server/web/apache/files/46_mod_ldap.conf new file mode 100644 index 0000000000..665b08b1cb --- /dev/null +++ b/server/web/apache/files/46_mod_ldap.conf @@ -0,0 +1,40 @@ + + + LoadModule ldap_module modules/mod_ldap.so + + + + + + LoadModule auth_ldap_module modules/mod_auth_ldap.so + + + +# Examples below are taken from the online documentation +# Refer to: +# http://localhost/manual/mod/mod_ldap.html +# http://localhost/manual/mod/mod_auth_ldap.html + + + + LDAPSharedCacheSize 200000 + LDAPCacheEntries 1024 + LDAPCacheTTL 600 + LDAPOpCacheEntries 1024 + LDAPOpCacheTTL 600 + + + SetHandler ldap-status + Order deny,allow + Deny from all + Allow from 127.0.0.1 + + + + + + + #AuthLDAPURL ldap://ldap1.airius.com:389/ou=People, o=Airius?uid?sub?(objectClass=*) + #require valid-user + + diff --git a/server/web/apache/files/apache.service b/server/web/apache/files/apache.service new file mode 100644 index 0000000000..b2f62d53bf --- /dev/null +++ b/server/web/apache/files/apache.service @@ -0,0 +1,15 @@ +[Unit] +Description=Apache Web Server +After=network.target remote-fs.target nss-lookup.target + +[Service] +Type=notify +EnvironmentFile=/etc/conf.d/apache2 +PIDFile=/run/apache2.pid +ExecStart=/usr/sbin/apache2 -d /usr/lib/apache2/ -f /etc/apache2/httpd.conf $APACHE2_OPTS -k start +ExecReload=/usr/sbin/apache2 -d /usr/lib/apache2/ -f /etc/apache2/httpd.conf $APACHE2_OPTS -k graceful +ExecStop=/usr/sbin/apache2 -d /usr/lib/apache2/ -f /etc/apache2/httpd.conf $APACHE2_OPTS -k graceful-stop +PrivateTmp=true + +[Install] +WantedBy=multi-user.target diff --git a/server/web/apache/files/apache2.confd b/server/web/apache/files/apache2.confd new file mode 100644 index 0000000000..afe3f9638a --- /dev/null +++ b/server/web/apache/files/apache2.confd @@ -0,0 +1,48 @@ +# Original works belongs to Gentoo Linux + +# Config file for /etc/conf. d/apache2 + +# When you install a module it is easy to activate or deactivate the modules +# and other features of apache using the APACHE2_OPTS line. Every module should +# install a configuration in /etc/apache2/modules.d. In that file will be an +# where NNN is the option to enable that module. +# Here are the options available in the default configuration: +# USERDIR Enables /~username mapping to /home/username/public_html +# INFO Enables mod_info, a useful module for debugging +# PROXY Enables mod_proxy +# DAV Enables mod_dav +# DAV_FS Enables mod_dav_fs (you should enable this when you enable DAV +# unless you know what you are doing) +# SSL Enables SSL +# SSL_DEFAULT_VHOST Enables default vhost for SSL (you should enable this +# when you enable SSL unless you know what you are doing) +# LDAP Enables mod_ldap +# AUTH_LDAP Enables authentication through mod_ldap +# DEFAULT_VHOST Enables the default virtual host in /var/www/localhost/htdocs +APACHE2_OPTS="-D DEFAULT_VHOST -D USERDIR" + +# Extended options for advanced uses of Apache ONLY +# You don't need to edit these unless you are doing crazy Apache stuff +# As not having them set correctly, or feeding in an incorrect configuration +# via them will result in Apache failing to start +# YOU HAVE BEEN WARNED. + +# ServerRoot setting +#SERVERROOT=/usr/lib/apache2 + +# Configuration file location +# - If this does NOT start with a '/', then it is treated relative to +# $SERVERROOT by Apache +#CONFIGFILE=/etc/apache2/httpd.conf + +# Location to log startup errors to +# They are normally dumped to your terminal. +#STARTUPERRORLOG="/var/log/apache2/startuperror.log" + +# Environment variables to keep +# All environment variables are cleared from apache +# Use this to preserve some of them +# NOTE!!! It's very important that this contains PATH +# Also, it will fail if the _value_ of any of these variables contains a space +KEEPENV="PATH" + diff --git a/server/web/apache/files/httpd-2.4.1-apctl.patch b/server/web/apache/files/httpd-2.4.1-apctl.patch new file mode 100644 index 0000000000..b10ca8e5c8 --- /dev/null +++ b/server/web/apache/files/httpd-2.4.1-apctl.patch @@ -0,0 +1,83 @@ + +- fail gracefully if links is not installed on target system +- source sysconfig/httpd for custom env. vars etc. +- make httpd -t work even in SELinux +- pass $OPTIONS to all $HTTPD invocation + +Upstream-HEAD: vendor +Upstream-2.0: vendor +Upstream-Status: Vendor-specific changes for better initscript integration + +--- httpd-2.4.1/support/apachectl.in.apctl ++++ httpd-2.4.1/support/apachectl.in +@@ -44,19 +44,25 @@ + # the path to your httpd binary, including options if necessary + HTTPD='@exp_sbindir@/@progname@' + # +-# pick up any necessary environment variables +-if test -f @exp_sbindir@/envvars; then +- . @exp_sbindir@/envvars +-fi + # + # a command that outputs a formatted text version of the HTML at the + # url given on the command line. Designed for lynx, however other + # programs may work. +-LYNX="@LYNX_PATH@ -dump" ++if [ -x "@LYNX_PATH@" ]; then ++ LYNX="@LYNX_PATH@ -dump" ++else ++ LYNX=none ++fi + # + # the URL to your server's mod_status status page. If you do not + # have one, then status and fullstatus will not work. + STATUSURL="http://localhost:@PORT@/server-status" ++ ++# Source /etc/conf.d/apache2 for $HTTPD setting, etc. ++if [ -r /etc/conf.d/apache2 ]; then ++ . /etc/conf.d/apache2 ++fi ++ + # + # Set this variable to a command that increases the maximum + # number of file descriptors allowed per child process. This is +@@ -76,9 +82,16 @@ + ARGV="-h" + fi + ++function checklynx() { ++if [ "$LYNX" = "none" ]; then ++ echo "The 'links' package is required for this functionality." ++ exit 8 ++fi ++} ++ + case $ACMD in + start|stop|restart|graceful|graceful-stop) +- $HTTPD -k $ARGV ++ $HTTPD $OPTIONS -k $ARGV + ERROR=$? + ;; + startssl|sslstart|start-SSL) +@@ -88,17 +101,18 @@ + ERROR=2 + ;; + configtest) +- $HTTPD -t +- ERROR=$? ++ testconfig + ;; + status) ++ checklynx + $LYNX $STATUSURL | awk ' /process$/ { print; exit } { print } ' + ;; + fullstatus) ++ checklynx + $LYNX $STATUSURL + ;; + *) +- $HTTPD "$@" ++ $HTTPD $OPTIONS "$@" + ERROR=$? + esac + diff --git a/server/web/apache/files/httpd-2.4.1-corelimit.patch b/server/web/apache/files/httpd-2.4.1-corelimit.patch new file mode 100644 index 0000000000..96f848674f --- /dev/null +++ b/server/web/apache/files/httpd-2.4.1-corelimit.patch @@ -0,0 +1,35 @@ + +Bump up the core size limit if CoreDumpDirectory is +configured. + +Upstream-Status: Was discussed but there are competing desires; + there are portability oddities here too. + +--- httpd-2.4.1/server/core.c.corelimit ++++ httpd-2.4.1/server/core.c +@@ -4433,6 +4433,25 @@ static int core_post_config(apr_pool_t * + } + apr_pool_cleanup_register(pconf, NULL, ap_mpm_end_gen_helper, + apr_pool_cleanup_null); ++ ++#ifdef RLIMIT_CORE ++ if (ap_coredumpdir_configured) { ++ struct rlimit lim; ++ ++ if (getrlimit(RLIMIT_CORE, &lim) == 0 && lim.rlim_cur == 0) { ++ lim.rlim_cur = lim.rlim_max; ++ if (setrlimit(RLIMIT_CORE, &lim) == 0) { ++ ap_log_error(APLOG_MARK, APLOG_NOTICE, 0, NULL, ++ "core dump file size limit raised to %lu bytes", ++ lim.rlim_cur); ++ } else { ++ ap_log_error(APLOG_MARK, APLOG_NOTICE, errno, NULL, ++ "core dump file size is zero, setrlimit failed"); ++ } ++ } ++ } ++#endif ++ + return OK; + } + diff --git a/server/web/apache/files/httpd-2.4.1-deplibs.patch b/server/web/apache/files/httpd-2.4.1-deplibs.patch new file mode 100644 index 0000000000..b73c21dcff --- /dev/null +++ b/server/web/apache/files/httpd-2.4.1-deplibs.patch @@ -0,0 +1,19 @@ + +Link straight against .la files. + +Upstream-Status: vendor specific + +--- httpd-2.4.1/configure.in.deplibs ++++ httpd-2.4.1/configure.in +@@ -707,9 +707,9 @@ APACHE_HELP_STRING(--with-suexec-umask,u + + dnl APR should go after the other libs, so the right symbols can be picked up + if test x${apu_found} != xobsolete; then +- AP_LIBS="$AP_LIBS `$apu_config --avoid-ldap --link-libtool --libs`" ++ AP_LIBS="$AP_LIBS `$apu_config --avoid-ldap --link-libtool`" + fi +-AP_LIBS="$AP_LIBS `$apr_config --link-libtool --libs`" ++AP_LIBS="$AP_LIBS `$apr_config --link-libtool`" + APACHE_SUBST(AP_LIBS) + APACHE_SUBST(AP_BUILD_SRCLIB_DIRS) + APACHE_SUBST(AP_CLEAN_SRCLIB_DIRS) diff --git a/server/web/apache/files/httpd-2.4.2-icons.patch b/server/web/apache/files/httpd-2.4.2-icons.patch new file mode 100644 index 0000000000..13419996a9 --- /dev/null +++ b/server/web/apache/files/httpd-2.4.2-icons.patch @@ -0,0 +1,26 @@ + +- Fix config for /icons/ dir to allow symlink to poweredby.png. +- Avoid using coredump GIF for a directory called "core" + +Upstream-Status: vendor specific patch + +--- httpd-2.4.2/docs/conf/extra/httpd-autoindex.conf.in.icons ++++ httpd-2.4.2/docs/conf/extra/httpd-autoindex.conf.in +@@ -21,7 +21,7 @@ IndexOptions FancyIndexing HTMLTable Ver + Alias /icons/ "@exp_iconsdir@/" + + +- Options Indexes MultiViews ++ Options Indexes MultiViews FollowSymlinks + AllowOverride None + Require all granted + +@@ -53,7 +53,7 @@ AddIcon /icons/dvi.gif .dvi + AddIcon /icons/uuencoded.gif .uu + AddIcon /icons/script.gif .conf .sh .shar .csh .ksh .tcl + AddIcon /icons/tex.gif .tex +-AddIcon /icons/bomb.gif core ++AddIcon /icons/bomb.gif core. + + AddIcon /icons/back.gif .. + AddIcon /icons/hand.right.gif README diff --git a/server/web/apache/files/httpd-2.4.3-apctl-systemd.patch b/server/web/apache/files/httpd-2.4.3-apctl-systemd.patch new file mode 100644 index 0000000000..bcb57fe8e9 --- /dev/null +++ b/server/web/apache/files/httpd-2.4.3-apctl-systemd.patch @@ -0,0 +1,45 @@ + +Upstream-Status: vendor specific patch + +diff --git a/support/apachectl.in b/support/apachectl.in +index c6ac3ea..2599386 100644 +--- a/support/apachectl.in ++++ b/support/apachectl.in +@@ -100,9 +100,24 @@ fi + ERROR=$? + } + ++if [ "x$2" != "x" ] ; then ++ echo Passing arguments to httpd using apachectl is no longer supported. ++ echo You can only start/stop/restart httpd using this script. ++ echo If you want to pass extra arguments to httpd, edit the ++ echo /etc/sysconfig/httpd config file. ++fi ++ + case $ACMD in +-start|stop|restart|graceful|graceful-stop) +- $HTTPD $OPTIONS -k $ARGV ++start|stop|restart|status) ++ /usr/bin/systemctl $ACMD httpd.service ++ ERROR=$? ++ ;; ++graceful) ++ /usr/bin/systemctl restart httpd.service ++ ERROR=$? ++ ;; ++graceful-stop) ++ /usr/bin/systemctl stop httpd.service + ERROR=$? + ;; + startssl|sslstart|start-SSL) +@@ -114,10 +129,6 @@ startssl|sslstart|start-SSL) + configtest) + testconfig + ;; +-status) +- checklynx +- $LYNX $STATUSURL | awk ' /process$/ { print; exit } { print } ' +- ;; + fullstatus) + checklynx + $LYNX $STATUSURL diff --git a/server/web/apache/files/httpd-2.4.3-apxs.patch b/server/web/apache/files/httpd-2.4.3-apxs.patch new file mode 100644 index 0000000000..ea1bc14891 --- /dev/null +++ b/server/web/apache/files/httpd-2.4.3-apxs.patch @@ -0,0 +1,56 @@ +--- httpd-2.4.3/support/apxs.in.apxs ++++ httpd-2.4.3/support/apxs.in +@@ -25,7 +25,18 @@ package apxs; + + my %config_vars = (); + +-my $installbuilddir = "@exp_installbuilddir@"; ++# Awful hack to make apxs libdir-agnostic: ++my $pkg_config = "/usr/bin/pkg-config"; ++if (! -x "$pkg_config") { ++ error("$pkg_config not found!"); ++ exit(1); ++} ++ ++my $libdir = `pkg-config --variable=libdir apr-1`; ++chomp $libdir; ++ ++my $installbuilddir = $libdir . "/apache2/build"; ++ + get_config_vars("$installbuilddir/config_vars.mk",\%config_vars); + + # read the configuration variables once +@@ -275,7 +286,7 @@ if ($opt_g) { + $data =~ s|%NAME%|$name|sg; + $data =~ s|%TARGET%|$CFG_TARGET|sg; + $data =~ s|%PREFIX%|$prefix|sg; +- $data =~ s|%INSTALLBUILDDIR%|$installbuilddir|sg; ++ $data =~ s|%LIBDIR%|$libdir|sg; + + my ($mkf, $mods, $src) = ($data =~ m|^(.+)-=#=-\n(.+)-=#=-\n(.+)|s); + +@@ -453,11 +464,11 @@ if ($opt_c) { + my $ldflags = "$CFG_LDFLAGS"; + if ($opt_p == 1) { + +- my $apr_libs=`$apr_config --cflags --ldflags --link-libtool --libs`; ++ my $apr_libs=`$apr_config --cflags --ldflags --link-libtool`; + chomp($apr_libs); + my $apu_libs=""; + if ($apr_major_version < 2) { +- $apu_libs=`$apu_config --ldflags --link-libtool --libs`; ++ $apu_libs=`$apu_config --ldflags --link-libtool`; + chomp($apu_libs); + } + +@@ -672,8 +683,8 @@ __DATA__ + + builddir=. + top_srcdir=%PREFIX% +-top_builddir=%PREFIX% +-include %INSTALLBUILDDIR%/special.mk ++top_builddir=%LIBDIR%/apache2 ++include %LIBDIR%/apache2/build/special.mk + + # the used tools + APXS=apxs diff --git a/server/web/apache/files/httpd-2.4.3-mod_systemd.patch b/server/web/apache/files/httpd-2.4.3-mod_systemd.patch new file mode 100644 index 0000000000..a9b1fd9910 --- /dev/null +++ b/server/web/apache/files/httpd-2.4.3-mod_systemd.patch @@ -0,0 +1,163 @@ +--- httpd-2.4.3/modules/arch/unix/config5.m4.systemd ++++ httpd-2.4.3/modules/arch/unix/config5.m4 +@@ -18,6 +18,19 @@ APACHE_MODULE(privileges, Per-virtualhos + fi + ]) + ++ ++APACHE_MODULE(systemd, Systemd support, , , $unixd_mods_enabled, [ ++ AC_CHECK_LIB(systemd-daemon, sd_notify, SYSTEMD_LIBS="-lsystemd-daemon") ++ AC_CHECK_HEADERS(systemd/sd-daemon.h, [ap_HAVE_SD_DAEMON_H="yes"], [ap_HAVE_SD_DAEMON_H="no"]) ++ if test $ap_HAVE_SD_DAEMON_H = "no" || test -z "${SYSTEMD_LIBS}"; then ++ AC_MSG_WARN([Your system does not support systemd.]) ++ enable_systemd="no" ++ else ++ APR_ADDTO(MOD_SYSTEMD_LDADD, [$SYSTEMD_LIBS]) ++ enable_systemd="yes" ++ fi ++]) ++ + APR_ADDTO(INCLUDES, [-I\$(top_srcdir)/$modpath_current]) + + APACHE_MODPATH_FINISH +--- httpd-2.4.3/modules/arch/unix/mod_systemd.c.systemd ++++ httpd-2.4.3/modules/arch/unix/mod_systemd.c +@@ -0,0 +1,138 @@ ++/* Licensed to the Apache Software Foundation (ASF) under one or more ++ * contributor license agreements. See the NOTICE file distributed with ++ * this work for additional information regarding copyright ownership. ++ * The ASF licenses this file to You under the Apache License, Version 2.0 ++ * (the "License"); you may not use this file except in compliance with ++ * the License. You may obtain a copy of the License at ++ * ++ * http://www.apache.org/licenses/LICENSE-2.0 ++ * ++ * Unless required by applicable law or agreed to in writing, software ++ * distributed under the License is distributed on an "AS IS" BASIS, ++ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. ++ * See the License for the specific language governing permissions and ++ * limitations under the License. ++ * ++ */ ++ ++#include ++#include ++#include "ap_mpm.h" ++#include ++#include ++#include ++#include ++#include ++#include "unixd.h" ++#include "scoreboard.h" ++#include "mpm_common.h" ++ ++#include "systemd/sd-daemon.h" ++ ++#if APR_HAVE_UNISTD_H ++#include ++#endif ++ ++#define KBYTE 1024 ++ ++static pid_t pid; /* PID of the main httpd instance */ ++static int server_limit, thread_limit, threads_per_child, max_servers; ++static time_t last_update_time; ++static unsigned long last_update_access; ++static unsigned long last_update_kbytes; ++ ++static int systemd_pre_mpm(apr_pool_t *p, ap_scoreboard_e sb_type) ++{ ++ int rv; ++ last_update_time = time(0); ++ ++ ap_mpm_query(AP_MPMQ_HARD_LIMIT_THREADS, &thread_limit); ++ ap_mpm_query(AP_MPMQ_HARD_LIMIT_DAEMONS, &server_limit); ++ ap_mpm_query(AP_MPMQ_MAX_THREADS, &threads_per_child); ++ /* work around buggy MPMs */ ++ if (threads_per_child == 0) ++ threads_per_child = 1; ++ ap_mpm_query(AP_MPMQ_MAX_DAEMONS, &max_servers); ++ ++ pid = getpid(); ++ ++ rv = sd_notifyf(0, "READY=1\n" ++ "STATUS=Processing requests...\n" ++ "MAINPID=%lu", ++ (unsigned long) pid); ++ if (rv < 0) { ++ ap_log_perror(APLOG_MARK, APLOG_ERR, 0, p, ++ "sd_notifyf returned an error %d", rv); ++ } ++ ++ return OK; ++} ++ ++static int systemd_monitor(apr_pool_t *p, server_rec *s) ++{ ++ int i, j, res, rv; ++ process_score *ps_record; ++ worker_score *ws_record; ++ unsigned long access = 0; ++ unsigned long bytes = 0; ++ unsigned long kbytes = 0; ++ char bps[5]; ++ time_t now = time(0); ++ time_t elapsed = now - last_update_time; ++ ++ for (i = 0; i < server_limit; ++i) { ++ ps_record = ap_get_scoreboard_process(i); ++ for (j = 0; j < thread_limit; ++j) { ++ ws_record = ap_get_scoreboard_worker_from_indexes(i, j); ++ if (ap_extended_status && !ps_record->quiescing && ps_record->pid) { ++ res = ws_record->status; ++ if (ws_record->access_count != 0 || ++ (res != SERVER_READY && res != SERVER_DEAD)) { ++ access += ws_record->access_count; ++ bytes += ws_record->bytes_served; ++ if (bytes >= KBYTE) { ++ kbytes += (bytes >> 10); ++ bytes = bytes & 0x3ff; ++ } ++ } ++ } ++ } ++ } ++ ++ apr_strfsize((unsigned long)(KBYTE *(float) (kbytes - last_update_kbytes) ++ / (float) elapsed), bps); ++ ++ rv = sd_notifyf(0, "READY=1\n" ++ "STATUS=Total requests: %lu; Current requests/sec: %.3g; " ++ "Current traffic: %sB/sec\n", access, ++ ((float)access - last_update_access) / (float) elapsed, bps); ++ if (rv < 0) { ++ ap_log_error(APLOG_MARK, APLOG_ERR, 0, s, APLOGNO(00000) ++ "sd_notifyf returned an error %d", rv); ++ } ++ ++ last_update_access = access; ++ last_update_kbytes = kbytes; ++ last_update_time = now; ++ ++ return DECLINED; ++} ++ ++static void systemd_register_hooks(apr_pool_t *p) ++{ ++ /* We know the PID in this hook ... */ ++ ap_hook_pre_mpm(systemd_pre_mpm, NULL, NULL, APR_HOOK_LAST); ++ /* Used to update httpd's status line using sd_notifyf */ ++ ap_hook_monitor(systemd_monitor, NULL, NULL, APR_HOOK_MIDDLE); ++} ++ ++module AP_MODULE_DECLARE_DATA systemd_module = ++{ ++ STANDARD20_MODULE_STUFF, ++ NULL, ++ NULL, ++ NULL, ++ NULL, ++ NULL, ++ systemd_register_hooks, ++}; diff --git a/server/web/apache/files/httpd-2.4.3-sslsninotreq.patch b/server/web/apache/files/httpd-2.4.3-sslsninotreq.patch new file mode 100644 index 0000000000..6e158c60d7 --- /dev/null +++ b/server/web/apache/files/httpd-2.4.3-sslsninotreq.patch @@ -0,0 +1,83 @@ +diff --git a/modules/ssl/ssl_engine_config.c b/modules/ssl/ssl_engine_config.c +index 15993f1..53ed6f1 100644 +--- a/modules/ssl/ssl_engine_config.c ++++ b/modules/ssl/ssl_engine_config.c +@@ -55,6 +55,7 @@ SSLModConfigRec *ssl_config_global_create(server_rec *s) + mc = (SSLModConfigRec *)apr_palloc(pool, sizeof(*mc)); + mc->pPool = pool; + mc->bFixed = FALSE; ++ mc->sni_required = FALSE; + + /* + * initialize per-module configuration +diff --git a/modules/ssl/ssl_engine_init.c b/modules/ssl/ssl_engine_init.c +index bf1f0e4..a7523de 100644 +--- a/modules/ssl/ssl_engine_init.c ++++ b/modules/ssl/ssl_engine_init.c +@@ -409,7 +409,7 @@ int ssl_init_Module(apr_pool_t *p, apr_pool_t *plog, + /* + * Configuration consistency checks + */ +- ssl_init_CheckServers(base_server, ptemp); ++ ssl_init_CheckServers(mc, base_server, ptemp); + + /* + * Announce mod_ssl and SSL library in HTTP Server field +@@ -1475,7 +1475,7 @@ void ssl_init_ConfigureServer(server_rec *s, + } + } + +-void ssl_init_CheckServers(server_rec *base_server, apr_pool_t *p) ++void ssl_init_CheckServers(SSLModConfigRec *mc, server_rec *base_server, apr_pool_t *p) + { + server_rec *s, *ps; + SSLSrvConfigRec *sc; +@@ -1557,6 +1557,7 @@ void ssl_init_CheckServers(server_rec *base_server, apr_pool_t *p) + } + + if (conflict) { ++ mc->sni_required = TRUE; + #ifdef OPENSSL_NO_TLSEXT + ap_log_error(APLOG_MARK, APLOG_WARNING, 0, base_server, APLOGNO(01917) + "Init: You should not use name-based " +diff --git a/modules/ssl/ssl_engine_kernel.c b/modules/ssl/ssl_engine_kernel.c +index bc9e26b..2460f01 100644 +--- a/modules/ssl/ssl_engine_kernel.c ++++ b/modules/ssl/ssl_engine_kernel.c +@@ -164,6 +164,7 @@ int ssl_hook_ReadReq(request_rec *r) + return DECLINED; + } + #ifndef OPENSSL_NO_TLSEXT ++ if (myModConfig(r->server)->sni_required) { + if ((servername = SSL_get_servername(ssl, TLSEXT_NAMETYPE_host_name))) { + char *host, *scope_id; + apr_port_t port; +@@ -206,6 +207,7 @@ int ssl_hook_ReadReq(request_rec *r) + " virtual host"); + return HTTP_FORBIDDEN; + } ++ } + #endif + SSL_set_app_data2(ssl, r); + +diff --git a/modules/ssl/ssl_private.h b/modules/ssl/ssl_private.h +index 75fc0e3..31dbfa9 100644 +--- a/modules/ssl/ssl_private.h ++++ b/modules/ssl/ssl_private.h +@@ -554,6 +554,7 @@ typedef struct { + struct { + void *pV1, *pV2, *pV3, *pV4, *pV5, *pV6, *pV7, *pV8, *pV9, *pV10; + } rCtx; ++ BOOL sni_required; + } SSLModConfigRec; + + /** Structure representing configured filenames for certs and keys for +@@ -786,7 +787,7 @@ const char *ssl_cmd_SSLFIPS(cmd_parms *cmd, void *dcfg, int flag); + int ssl_init_Module(apr_pool_t *, apr_pool_t *, apr_pool_t *, server_rec *); + void ssl_init_Engine(server_rec *, apr_pool_t *); + void ssl_init_ConfigureServer(server_rec *, apr_pool_t *, apr_pool_t *, SSLSrvConfigRec *); +-void ssl_init_CheckServers(server_rec *, apr_pool_t *); ++void ssl_init_CheckServers(SSLModConfigRec *mc, server_rec *, apr_pool_t *); + STACK_OF(X509_NAME) + *ssl_init_FindCAList(server_rec *, apr_pool_t *, const char *, const char *); + void ssl_init_Child(apr_pool_t *, server_rec *); diff --git a/server/web/apache/files/httpd-2.4.4-r1337344+.patch b/server/web/apache/files/httpd-2.4.4-r1337344+.patch new file mode 100644 index 0000000000..6e5c3e7832 --- /dev/null +++ b/server/web/apache/files/httpd-2.4.4-r1337344+.patch @@ -0,0 +1,250 @@ +# ./pullrev.sh 1337344 1341905 1342065 1341930 + +suexec enhancements: + +1) use syslog for logging +2) use capabilities not setuid/setgid root binary + +http://svn.apache.org/viewvc?view=revision&revision=1337344 +http://svn.apache.org/viewvc?view=revision&revision=1341905 +http://svn.apache.org/viewvc?view=revision&revision=1342065 +http://svn.apache.org/viewvc?view=revision&revision=1341930 + +--- httpd-2.4.4/configure.in.r1337344+ ++++ httpd-2.4.4/configure.in +@@ -734,7 +734,24 @@ APACHE_HELP_STRING(--with-suexec-gidmin, + + AC_ARG_WITH(suexec-logfile, + APACHE_HELP_STRING(--with-suexec-logfile,Set the logfile),[ +- AC_DEFINE_UNQUOTED(AP_LOG_EXEC, "$withval", [SuExec log file] ) ] ) ++ if test "x$withval" = "xyes"; then ++ AC_DEFINE_UNQUOTED(AP_LOG_EXEC, "$withval", [SuExec log file]) ++ fi ++]) ++ ++AC_ARG_WITH(suexec-syslog, ++APACHE_HELP_STRING(--with-suexec-syslog,Set the logfile),[ ++ if test $withval = "yes"; then ++ if test "x${with_suexec_logfile}" != "xno"; then ++ AC_MSG_NOTICE([hint: use "--without-suexec-logfile --with-suexec-syslog"]) ++ AC_MSG_ERROR([suexec does not support both logging to file and syslog]) ++ fi ++ AC_CHECK_FUNCS([vsyslog], [], [ ++ AC_MSG_ERROR([cannot support syslog from suexec without vsyslog()])]) ++ AC_DEFINE(AP_LOG_SYSLOG, 1, [SuExec log to syslog]) ++ fi ++]) ++ + + AC_ARG_WITH(suexec-safepath, + APACHE_HELP_STRING(--with-suexec-safepath,Set the safepath),[ +@@ -744,6 +761,15 @@ AC_ARG_WITH(suexec-umask, + APACHE_HELP_STRING(--with-suexec-umask,umask for suexec'd process),[ + AC_DEFINE_UNQUOTED(AP_SUEXEC_UMASK, 0$withval, [umask for suexec'd process] ) ] ) + ++INSTALL_SUEXEC=setuid ++AC_ARG_ENABLE([suexec-capabilities], ++APACHE_HELP_STRING(--enable-suexec-capabilities,Use Linux capability bits not setuid root suexec), [ ++INSTALL_SUEXEC=caps ++AC_DEFINE(AP_SUEXEC_CAPABILITIES, 1, ++ [Enable if suexec is installed with Linux capabilities, not setuid]) ++]) ++APACHE_SUBST(INSTALL_SUEXEC) ++ + dnl APR should go after the other libs, so the right symbols can be picked up + if test x${apu_found} != xobsolete; then + AP_LIBS="$AP_LIBS `$apu_config --avoid-ldap --link-libtool`" +--- httpd-2.4.4/docs/manual/suexec.html.en.r1337344+ ++++ httpd-2.4.4/docs/manual/suexec.html.en +@@ -372,6 +372,21 @@ + together with the --enable-suexec option to let + APACI accept your request for using the suEXEC feature. + ++
--enable-suexec-capabilities
++ ++
Linux specific: Normally, ++ the suexec binary is installed "setuid/setgid ++ root", which allows it to run with the full privileges of the ++ root user. If this option is used, the suexec ++ binary will instead be installed with only the setuid/setgid ++ "capability" bits set, which is the subset of full root ++ priviliges required for suexec operation. Note that ++ the suexec binary may not be able to write to a log ++ file in this mode; it is recommended that the ++ --with-suexec-syslog --without-suexec-logfile ++ options are used in conjunction with this mode, so that syslog ++ logging is used instead.
++ +
--with-suexec-bin=PATH
+ +
The path to the suexec binary must be hard-coded +@@ -433,6 +448,12 @@ + "suexec_log" and located in your standard logfile + directory (--logfiledir).
+ ++
--with-suexec-syslog
++ ++
If defined, suexec will log notices and errors to syslog ++ instead of a logfile. This option must be combined ++ with --without-suexec-logfile.
++ +
--with-suexec-safepath=PATH
+ +
Define a safe PATH environment to pass to CGI +@@ -550,9 +571,12 @@ Group webgroup + +

The suEXEC wrapper will write log information + to the file defined with the --with-suexec-logfile +- option as indicated above. If you feel you have configured and +- installed the wrapper properly, have a look at this log and the +- error_log for the server to see where you may have gone astray.

++ option as indicated above, or to syslog if --with-suexec-syslog ++ is used. If you feel you have configured and ++ installed the wrapper properly, have a look at the log and the ++ error_log for the server to see where you may have gone astray. ++ The output of "suexec -V" will show the options ++ used to compile suexec, if using a binary distribution.

+ +
top
+
+@@ -640,4 +664,4 @@ if (typeof(prettyPrint) !== 'undefined') + prettyPrint(); + } + //--> +- +\ No newline at end of file ++ +--- httpd-2.4.4/Makefile.in.r1337344+ ++++ httpd-2.4.4/Makefile.in +@@ -238,11 +238,22 @@ install-man: + cd $(DESTDIR)$(manualdir) && find . -name ".svn" -type d -print | xargs rm -rf 2>/dev/null || true; \ + fi + +-install-suexec: ++install-suexec: install-suexec-binary install-suexec-$(INSTALL_SUEXEC) ++ ++install-suexec-binary: + @if test -f $(builddir)/support/suexec; then \ + test -d $(DESTDIR)$(sbindir) || $(MKINSTALLDIRS) $(DESTDIR)$(sbindir); \ + $(INSTALL_PROGRAM) $(top_builddir)/support/suexec $(DESTDIR)$(sbindir); \ +- chmod 4755 $(DESTDIR)$(sbindir)/suexec; \ ++ fi ++ ++install-suexec-setuid: ++ @if test -f $(builddir)/support/suexec; then \ ++ chmod 4755 $(DESTDIR)$(sbindir)/suexec; \ ++ fi ++ ++install-suexec-caps: ++ @if test -f $(builddir)/support/suexec; then \ ++ setcap 'cap_setuid,cap_setgid+pe' $(DESTDIR)$(sbindir)/suexec; \ + fi + + suexec: +--- httpd-2.4.4/modules/arch/unix/mod_unixd.c.r1337344+ ++++ httpd-2.4.4/modules/arch/unix/mod_unixd.c +@@ -284,6 +284,13 @@ unixd_set_suexec(cmd_parms *cmd, void *d + return NULL; + } + ++#ifdef AP_SUEXEC_CAPABILITIES ++/* If suexec is using capabilities, don't test for the setuid bit. */ ++#define SETUID_TEST(finfo) (1) ++#else ++#define SETUID_TEST(finfo) (finfo.protection & APR_USETID) ++#endif ++ + static int + unixd_pre_config(apr_pool_t *pconf, apr_pool_t *plog, + apr_pool_t *ptemp) +@@ -300,7 +307,7 @@ unixd_pre_config(apr_pool_t *pconf, apr_ + ap_unixd_config.suexec_enabled = 0; + if ((apr_stat(&wrapper, SUEXEC_BIN, APR_FINFO_NORM, ptemp)) + == APR_SUCCESS) { +- if ((wrapper.protection & APR_USETID) && wrapper.user == 0 ++ if (SETUID_TEST(wrapper) && wrapper.user == 0 + && (access(SUEXEC_BIN, R_OK|X_OK) == 0)) { + ap_unixd_config.suexec_enabled = 1; + ap_unixd_config.suexec_disabled_reason = ""; +--- httpd-2.4.4/support/suexec.c.r1337344+ ++++ httpd-2.4.4/support/suexec.c +@@ -58,6 +58,10 @@ + #include + #endif + ++#ifdef AP_LOG_SYSLOG ++#include ++#endif ++ + #if defined(PATH_MAX) + #define AP_MAXPATH PATH_MAX + #elif defined(MAXPATHLEN) +@@ -69,7 +73,20 @@ + #define AP_ENVBUF 256 + + extern char **environ; ++ ++#ifdef AP_LOG_SYSLOG ++/* Syslog support. */ ++#if !defined(AP_LOG_FACILITY) && defined(LOG_AUTHPRIV) ++#define AP_LOG_FACILITY LOG_AUTHPRIV ++#elif !defined(AP_LOG_FACILITY) ++#define AP_LOG_FACILITY LOG_AUTH ++#endif ++ ++static int log_open; ++#else ++/* Non-syslog support. */ + static FILE *log = NULL; ++#endif + + static const char *const safe_env_lst[] = + { +@@ -137,7 +154,14 @@ static void err_output(int is_error, con + + static void err_output(int is_error, const char *fmt, va_list ap) + { +-#ifdef AP_LOG_EXEC ++#if defined(AP_LOG_SYSLOG) ++ if (!log_open) { ++ openlog("suexec", LOG_PID, AP_LOG_FACILITY); ++ log_open = 1; ++ } ++ ++ vsyslog(is_error ? LOG_ERR : LOG_INFO, fmt, ap); ++#elif defined(AP_LOG_EXEC) + time_t timevar; + struct tm *lt; + +@@ -295,7 +319,9 @@ int main(int argc, char *argv[]) + #ifdef AP_HTTPD_USER + fprintf(stderr, " -D AP_HTTPD_USER=\"%s\"\n", AP_HTTPD_USER); + #endif +-#ifdef AP_LOG_EXEC ++#if defined(AP_LOG_SYSLOG) ++ fprintf(stderr, " -D AP_LOG_SYSLOG\n"); ++#elif defined(AP_LOG_EXEC) + fprintf(stderr, " -D AP_LOG_EXEC=\"%s\"\n", AP_LOG_EXEC); + #endif + #ifdef AP_SAFE_PATH +@@ -591,6 +617,12 @@ int main(int argc, char *argv[]) + #endif /* AP_SUEXEC_UMASK */ + + /* Be sure to close the log file so the CGI can't mess with it. */ ++#ifdef AP_LOG_SYSLOG ++ if (log_open) { ++ closelog(); ++ log_open = 0; ++ } ++#else + if (log != NULL) { + #if APR_HAVE_FCNTL_H + /* +@@ -612,6 +644,7 @@ int main(int argc, char *argv[]) + log = NULL; + #endif + } ++#endif + + /* + * Execute the command, replacing our image with its own. diff --git a/server/web/apache/files/httpd.conf b/server/web/apache/files/httpd.conf new file mode 100644 index 0000000000..2d22bd710d --- /dev/null +++ b/server/web/apache/files/httpd.conf @@ -0,0 +1,1060 @@ + +# Based upon the NCSA server configuration files originally by Rob McCool. +# +# This is the main Apache server configuration file. It contains the +# configuration directives that give the server its instructions. +# See for detailed information about +# the directives. +# +# Do NOT simply read the instructions in here without understanding +# what they do. They're here only as hints or reminders. If you are unsure +# consult the online docs. You have been warned. +# +# The configuration directives are grouped into three basic sections: +# 1. Directives that control the operation of the Apache server process as a +# whole (the 'global environment'). +# 2. Directives that define the parameters of the 'main' or 'default' server, +# which responds to requests that aren't handled by a virtual host. +# These directives also provide default values for the settings +# of all virtual hosts. +# 3. Settings for virtual hosts, which allow Web requests to be sent to +# different IP addresses or hostnames and have them handled by the +# same Apache server process. +# +# Configuration and logfile names: If the filenames you specify for many +# of the server's control files begin with "/" (or "drive:/" for Win32), the +# server will use that explicit path. If the filenames do *not* begin +# with "/", the value of ServerRoot is prepended -- so "logs/foo.log" +# with ServerRoot set to "/usr/lib/apache2" will be interpreted by the +# server as "/usr/lib/apache2/logs/foo.log". +# + +### Section 1: Global Environment +# +# The directives in this section affect the overall operation of Apache, +# such as the number of concurrent requests it can handle or where it +# can find its configuration files. +# + +# +# ServerRoot: The top of the directory tree under which the server's +# configuration, error, and log files are kept. +# +# NOTE! If you intend to place this on an NFS (or otherwise network) +# mounted filesystem then please read the LockFile documentation (available +# at ); +# you will save yourself a lot of trouble. +# +# Do NOT add a slash at the end of the directory path. +# +ServerRoot "/usr/lib/apache2" + +# +# The accept serialization lock file MUST BE STORED ON A LOCAL DISK. +# +#LockFile "/var/run/apache2.lock" + +# +# ScoreBoardFile: File used to store internal server process information. +# If unspecified (the default), the scoreboard will be stored in an +# anonymous shared memory segment, and will be unavailable to third-party +# applications. +# If specified, ensure that no two invocations of Apache share the same +# scoreboard file. The scoreboard file MUST BE STORED ON A LOCAL DISK. +# + + #ScoreBoardFile /var/run/apache2_runtime_status + + + +# +# PidFile: The file in which the server should record its process +# identification number when it starts. +# +PidFile "/run/apache2.pid" + +# +# Timeout: The number of seconds before receives and sends time out. +# +Timeout 300 + +# +# KeepAlive: Whether or not to allow persistent connections (more than +# one request per connection). Set to "Off" to deactivate. +# +KeepAlive On + +# +# MaxKeepAliveRequests: The maximum number of requests to allow +# during a persistent connection. Set to 0 to allow an unlimited amount. +# We recommend you leave this number high, for maximum performance. +# +MaxKeepAliveRequests 100 + +# +# KeepAliveTimeout: Number of seconds to wait for the next request from the +# same client on the same connection. +# +KeepAliveTimeout 15 + +## +## Server-Pool Size Regulation (MPM specific) +## + +# prefork MPM [DEFAULT IF USE=-threads] +# StartServers: number of server processes to start +# MinSpareServers: minimum number of server processes which are kept spare +# MaxSpareServers: maximum number of server processes which are kept spare +# MaxClients: maximum number of server processes allowed to start +# MaxRequestsPerChild: maximum number of requests a server process serves + + StartServers 5 + MinSpareServers 5 + MaxSpareServers 10 + MaxClients 150 + MaxRequestsPerChild 0 + + +# worker MPM [DEFAULT IF USE=threads] +# StartServers: initial number of server processes to start +# MaxClients: maximum number of simultaneous client connections +# MinSpareThreads: minimum number of worker threads which are kept spare +# MaxSpareThreads: maximum number of worker threads which are kept spare +# ThreadsPerChild: constant number of worker threads in each server process +# MaxRequestsPerChild: maximum number of requests a server process serves + + StartServers 2 + MaxClients 150 + MinSpareThreads 25 + MaxSpareThreads 75 + ThreadsPerChild 25 + MaxRequestsPerChild 0 + + +# perchild MPM [THIS MPM IS NOT SUPPORTED] +# NumServers: constant number of server processes +# StartThreads: initial number of worker threads in each server process +# MinSpareThreads: minimum number of worker threads which are kept spare +# MaxSpareThreads: maximum number of worker threads which are kept spare +# MaxThreadsPerChild: maximum number of worker threads in each server process +# MaxRequestsPerChild: maximum number of connections per server process + + NumServers 5 + StartThreads 5 + MinSpareThreads 5 + MaxSpareThreads 10 + MaxThreadsPerChild 20 + MaxRequestsPerChild 0 + + +# peruser MPM [THIS MPM IS NOT SUPPORTED] +# MinSpareServers - Minimum number of idle children, to handle request spikes +# MaxClients - Maximum number of children alive at the same time +# MaxProcessors - Maximum number of processors per vhost +# Multiplexer - Specify an Multiplexer Child configuration. +# Processor - Specify a User and Group for a specific child process. +# ServerEnvironment - Specify the server environment for this virtual host. + + ServerLimit 256 + MaxClients 256 + MinSpareProcessors 2 + MaxProcessors 10 + MaxRequestsPerChild 1000 + + # kill off idle processors after this many seconds + # set to 0 to disable + ExpireTimeout 1800 + + Multiplexer nobody nobody + + Processor apache apache + + # chroot dir is optional: + # Processor user group /path/to/chroot + + +# +# Listen: Allows you to bind Apache to specific IP addresses and/or +# ports, instead of the default. See also the +# directive. +# +# Change this to Listen on specific IP addresses as shown below to +# prevent Apache from glomming onto all bound IP addresses (0.0.0.0) +# +#Listen 12.34.56.78:80 +Listen 80 + +# +# Dynamic Shared Object (DSO) Support +# +# To be able to use the functionality of a module which was built as a DSO you +# have to place corresponding `LoadModule' lines at this location so the +# directives contained in it are actually available _before_ they are used. +# Statically compiled modules (those listed by `httpd -l') do not need +# to be loaded here. +# +# The following modules are considered as the default configuration. +# If you wish to disable one of them, you may have to alter other +# configuration directives. +# +# You should always leave these three, as they are needed for normal use. +# mod_authz_host (Order, Allow, etc..) +# mod_log_config (Transferlog, etc..) +# mod_mime (AddType, etc...) +# +# Example: +# LoadModule foo_module modules/mod_foo.so + + +# Authentication Modules +# +# These modules provide authentication and authorization for +# clients. They should not normally be disabled. +# +LoadModule authz_host_module modules/mod_authz_host.so +LoadModule auth_basic_module modules/mod_auth_basic.so +LoadModule authn_dbm_module modules/mod_authn_dbm.so +LoadModule authn_file_module modules/mod_authn_file.so +LoadModule auth_digest_module modules/mod_auth_digest.so + +# +# Metadata Modules +# +# These modules provide extra data to clients about +# a file, such as the mime-type or charset. +# +LoadModule charset_lite_module modules/mod_charset_lite.so +LoadModule env_module modules/mod_env.so +LoadModule expires_module modules/mod_expires.so +LoadModule headers_module modules/mod_headers.so +LoadModule mime_module modules/mod_mime.so +LoadModule negotiation_module modules/mod_negotiation.so +LoadModule setenvif_module modules/mod_setenvif.so + +# +# Logging Modules +# +# These modules provide logging services for Apache +# +LoadModule log_config_module modules/mod_log_config.so +LoadModule logio_module modules/mod_logio.so + + +# +# CGI Modules +# +# These modules provide the ability to execute CGI Scripts. +# +LoadModule cgi_module modules/mod_cgi.so +LoadModule cgid_module modules/mod_cgid.so + + +# +# This `suexec` module provides the ability to exeucte CGI scripts under +# a different user than apache is run. +# +LoadModule suexec_module modules/mod_suexec.so + + +# +# Mappers +# +# These Modules provide URL mappings or translations. +LoadModule alias_module modules/mod_alias.so +LoadModule rewrite_module modules/mod_rewrite.so + + LoadModule userdir_module modules/mod_userdir.so + + + +# +# Handlers +# +# These modules create content for a client. +# + + LoadModule info_module modules/mod_info.so + LoadModule status_module modules/mod_status.so + +LoadModule actions_module modules/mod_actions.so +LoadModule autoindex_module modules/mod_autoindex.so +LoadModule dir_module modules/mod_dir.so + +# +# Filters +# +# These modules provide filters for Apache. +# They preform common tasks like gzip encoding or SSI +# +# +LoadModule ext_filter_module modules/mod_ext_filter.so +LoadModule deflate_module modules/mod_deflate.so +LoadModule include_module modules/mod_include.so + + +# +# Cache Modules +# +# The following modules are used for storing a cache of +# generated or proxied content. +# +#LoadModule cache_module modules/mod_cache.so +#LoadModule disk_cache_module modules/mod_disk_cache.so +#LoadModule mem_cache_module modules/mod_mem_cache.so +#LoadModule file_cache_module modules/mod_file_cache.so + +# +# Proxy Modules +# +# The following modules are only needed if you are running +# Apache as a Forward or Reverse Proxy. +# +# WARNING: Enabling these modules can be dangerous! +# READ THE DOCUMENTATION FIRST: +# http://httpd.apache.org/docs-2.0/mod/mod_proxy.html + + LoadModule proxy_module modules/mod_proxy.so + LoadModule proxy_connect_module modules/mod_proxy_connect.so + LoadModule proxy_ftp_module modules/mod_proxy_ftp.so + LoadModule proxy_http_module modules/mod_proxy_http.so + + +# +# Uncommon Modules +# +# The following Modules are not commonly loaded for Apache +# +#LoadModule case_filter_module modules/mod_case_filter.so +#LoadModule case_filter_in_module modules/mod_case_filter_in.so +#LoadModule echo_module modules/mod_echo.so +#LoadModule mime_magic_module modules/mod_mime_magic.so +#LoadModule speling_module modules/mod_speling.so +#LoadModule unique_id_module modules/mod_unique_id.so +#LoadModule vhost_alias_module modules/mod_vhost_alias.so + +# +# Obsolete Modules +# +# The Following modules are not commonly needed and use +# obsolete technologies. +# +#LoadModule cern_meta_module modules/mod_cern_meta.so +#LoadModule imap_module modules/mod_imap.so +#LoadModule usertrack_module modules/mod_usertrack.so +#LoadModule asis_module modules/mod_asis.so + + +# Extra configuration +# +IncludeOptional /etc/apache2/conf.d/*.conf + +# +# Extra Modules +# +# We Include extra .conf files from /etc/apache2/modules.d +# This is used to load things like PHP and mod_ssl. +# +Include /etc/apache2/modules.d/*.conf + +### Section 2: 'Main' server configuration +# +# The directives in this section set up the values used by the 'main' +# server, which responds to any requests that aren't handled by a +# definition. These values also provide defaults for +# any containers you may define later in the file. +# +# All of these directives may appear inside containers, +# in which case these default settings will be overridden for the +# virtual host being defined. +# + +# +# If you wish httpd to run as a different user or group, you must run +# httpd as root initially and it will switch. +# +# User/Group: The name (or #number) of the user/group to run httpd as. +# . On SCO (ODT 3) use "User nouser" and "Group nogroup". +# . On HPUX you may not be able to use shared memory as nobody, and the +# suggested workaround is to create a user www and use that user. +# NOTE that some kernels refuse to setgid(Group) or semctl(IPC_SET) +# when the value of (unsigned)Group is above 60000; +# don't use Group #-1 on these systems! +# +LoadModule unixd_module modules/mod_unixd.so +User apache +Group apache + +# +# ServerAdmin: Your address, where problems with the server should be +# e-mailed. This address appears on some server-generated pages, such +# as error documents. e.g. admin@your-domain.com +# +ServerAdmin root@localhost + +# +# ServerName gives the name and port that the server uses to identify itself. +# This can often be determined automatically, but we recommend you specify +# it explicitly to prevent problems during startup. +# +# If this is not set to valid DNS name for your host, server-generated +# redirections will not work. See also the UseCanonicalName directive. +# +# If your host doesn't have a registered DNS name, enter its IP address here. +# You will have to access it by its address anyway, and this will make +# redirections work in a sensible way. +# +ServerName localhost + +# +# UseCanonicalName: Determines how Apache constructs self-referencing +# URLs and the SERVER_NAME and SERVER_PORT variables. +# When set "Off", Apache will use the Hostname and Port supplied +# by the client. When set "On", Apache will use the value of the +# ServerName directive. +# +UseCanonicalName Off + + +# +# Each directory to which Apache has access can be configured with respect +# to which services and features are allowed and/or disabled in that +# directory (and its subdirectories). +# +# First, we configure the "default" to be a very restrictive set of +# features. +# + + Options FollowSymLinks + AllowOverride None + + +# +# Note that from this point forward you must specifically allow +# particular features to be enabled - so if something's not working as +# you might expect, make sure that you have specifically enabled it +# below. +# + +# +# UserDir: The name of the directory that is appended onto a user's home +# directory if a ~user request is received. +# enable by adding -D USERDIR to /etc/conf.d/apache2 +# +LoadModule authz_core_module modules/mod_authz_core.so +LoadModule authz_host_module modules/mod_authz_host.so +LoadModule access_compat_module modules/mod_access_compat.so + + UserDir public_html + +# +# Control access to UserDir directories. The following is an example +# for a site where these directories are restricted to read-only. +# + + + AllowOverride FileInfo AuthConfig Limit Indexes + Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec + + Order allow,deny + Allow from all + + + Order deny,allow + Deny from all + + + + +# Enable this additional section if you would like to make use of a +# suexec-enabled cgi-bin directory on a per-user basis. +# +# +# Options ExecCGI +# SetHandler cgi-script +# + + + + +# +# DirectoryIndex: sets the file that Apache will serve if a directory +# is requested. +# +# The index.html.var file (a type-map) is used to deliver content- +# negotiated documents. The MultiViews Option can be used for the +# same purpose, but it is much slower. +# +DirectoryIndex index.html + +# +# AccessFileName: The name of the file to look for in each directory +# for additional configuration directives. See also the AllowOverride +# directive. +# +AccessFileName .htaccess + +# +# The following lines prevent .htaccess and .htpasswd files from being +# viewed by Web clients. +# + + Order allow,deny + Deny from all + + +# +# TypesConfig describes where the mime.types file (or equivalent) is +# to be found. +# +TypesConfig /etc/mime.types + +# +# DefaultType is the default MIME type the server will use for a document +# if it cannot otherwise determine one, such as from filename extensions. +# If your server contains mostly text or HTML documents, "text/plain" is +# a good value. If most of your content is binary, such as applications +# or images, you may want to use "application/octet-stream" instead to +# keep browsers from trying to display binary files as though they are +# text. +# +DefaultType text/plain + +# +# The mod_mime_magic module allows the server to use various hints from the +# contents of the file itself to determine its type. The MIMEMagicFile +# directive tells the module where the hint definitions are located. +# + + MIMEMagicFile /etc/apache2/magic + + +# +# HostnameLookups: Log the names of clients or just their IP addresses +# e.g., www.apache.org (on) or 204.62.129.132 (off). +# The default is off because it'd be overall better for the net if people +# had to knowingly turn this feature on, since enabling it means that +# each client request will result in AT LEAST one lookup request to the +# nameserver. +# +HostnameLookups Off + +# +# EnableMMAP: Control whether memory-mapping is used to deliver +# files (assuming that the underlying OS supports it). +# The default is on; turn this off if you serve from NFS-mounted +# filesystems. On some systems, turning it off (regardless of +# filesystem) can improve performance; for details, please see +# http://httpd.apache.org/docs-2.0/mod/core.html#enablemmap +# +#EnableMMAP off + +# +# EnableSendfile: Control whether the sendfile kernel support is +# used to deliver files (assuming that the OS supports it). +# The default is on; turn this off if you serve from NFS-mounted +# filesystems. Please see +# http://httpd.apache.org/docs-2.0/mod/core.html#enablesendfile +# +#EnableSendfile off + +# +# ErrorLog: The location of the error log file. +# If you do not specify an ErrorLog directive within a +# container, error messages relating to that virtual host will be +# logged here. If you *do* define an error logfile for a +# container, that host's errors will be logged there and not here. +# +ErrorLog logs/error_log + +# +# LogLevel: Control the number of messages logged to the error_log. +# Possible values include: debug, info, notice, warn, error, crit, +# alert, emerg. +# +LogLevel warn + +# +# The following directives define some format nicknames for use with +# a CustomLog directive (see below). +# +LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined +LogFormat "%h %l %u %t \"%r\" %>s %b" common +LogFormat "%{Referer}i -> %U" referer +LogFormat "%{User-agent}i" agent +LogFormat "%v %h %l %u %t \"%r\" %>s %b %T" script +LogFormat "%v %h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" VLOG=%{VLOG}e" vhost + +# You need to enable mod_logio.c to use %I and %O +#LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio + +# +# The location and format of the access logfile (Common Logfile Format). +# If you do not define any access logfiles within a +# container, they will be logged here. Contrariwise, if you *do* +# define per- access logfiles, transactions will be +# logged therein and *not* in this file. +# +CustomLog logs/access_log common + +# +# If you would like to have agent and referer logfiles, uncomment the +# following directives. +# +#CustomLog logs/referer_log referer +#CustomLog logs/agent_log agent + +# +# If you prefer a single logfile with access, agent, and referer information +# (Combined Logfile Format) you can use the following directive. +# +#CustomLog logs/access_log combined + +# +# ServerTokens +# This directive configures what you return as the Server HTTP response +# Header. The default is 'Full' which sends information about the OS-Type +# and compiled in modules. +# Set to one of: Full | OS | Minor | Minimal | Major | Prod +# where Full conveys the most information, and Prod the least. +# +ServerTokens Prod + +# +# Optionally add a line containing the server version and virtual host +# name to server-generated pages (internal error documents, FTP directory +# listings, mod_status and mod_info output etc., but not CGI generated +# documents or custom error documents). +# Set to "EMail" to also include a mailto: link to the ServerAdmin. +# Set to one of: On | Off | EMail +# +ServerSignature Off + +# +# Aliases: Add here as many aliases as you need (with no limit). The format is +# Alias fakename realname +# +# Note that if you include a trailing / on fakename then the server will +# require it to be present in the URL. So "/icons" isn't aliased in this +# example, only "/icons/". If the fakename is slash-terminated, then the +# realname must also be slash terminated, and if the fakename omits the +# trailing slash, the realname must also omit it. +# +# We include the /icons/ alias for FancyIndexed directory listings. If you +# do not use FancyIndexing, you may comment this out. +# +Alias /icons/ "/var/www/localhost/icons/" + + + Options Indexes MultiViews + AllowOverride None + Order allow,deny + Allow from all + + +# +# ScriptAlias: This controls which directories contain server scripts. +# ScriptAliases are essentially the same as Aliases, except that +# documents in the realname directory are treated as applications and +# run by the server when requested rather than as documents sent to the client. +# The same rules about trailing "/" apply to ScriptAlias directives as to +# Alias. +# +ScriptAlias /cgi-bin/ /var/www/localhost/cgi-bin/ + + + # + # Additional to mod_cgid.c settings, mod_cgid has Scriptsock + # for setting UNIX socket for communicating with cgid. + # + #Scriptsock /var/run/cgisock + + +# +# "/var/www/localhost/cgi-bin/" should be changed to whatever your ScriptAliased +# CGI directory exists, if you have that configured. +# + + AllowOverride None + Options None + Order allow,deny + Allow from all + + +# +# Redirect allows you to tell clients about documents which used to exist in +# your server's namespace, but do not anymore. This allows you to tell the +# clients where to look for the relocated document. +# Example: +# Redirect permanent /foo http://www.example.com/bar + +# +# Directives controlling the display of server-generated directory listings. +# + + # + # IndexOptions: Controls the appearance of server-generated directory + # listings. + # + IndexOptions FancyIndexing VersionSort NameWidth=60 + + # + # AddIcon* directives tell the server which icon to show for different + # files or filename extensions. These are only displayed for + # FancyIndexed directories. + # + AddIconByEncoding (CMP,/icons/compressed.gif) x-compress x-gzip + + AddIconByType (TXT,/icons/text.gif) text/* + AddIconByType (IMG,/icons/image2.gif) image/* + AddIconByType (SND,/icons/sound2.gif) audio/* + AddIconByType (VID,/icons/movie.gif) video/* + + AddIcon /icons/binary.gif .bin .exe + AddIcon /icons/binhex.gif .hqx + AddIcon /icons/tar.gif .tar + AddIcon /icons/world2.gif .wrl .wrl.gz .vrml .vrm .iv + AddIcon /icons/compressed.gif .Z .z .tgz .gz .zip + AddIcon /icons/a.gif .ps .ai .eps + AddIcon /icons/layout.gif .html .shtml .htm .pdf + AddIcon /icons/text.gif .txt + AddIcon /icons/c.gif .c + AddIcon /icons/p.gif .pl .py + AddIcon /icons/f.gif .for + AddIcon /icons/dvi.gif .dvi + AddIcon /icons/uuencoded.gif .uu + AddIcon /icons/script.gif .conf .sh .shar .csh .ksh .tcl + AddIcon /icons/tex.gif .tex + AddIcon /icons/bomb.gif core + + AddIcon /icons/back.gif .. + AddIcon /icons/hand.right.gif README + AddIcon /icons/folder.gif ^^DIRECTORY^^ + AddIcon /icons/blank.gif ^^BLANKICON^^ + + # + # DefaultIcon is which icon to show for files which do not have an icon + # explicitly set. + # + DefaultIcon /icons/unknown.gif + + # + # AddDescription allows you to place a short description after a file in + # server-generated indexes. These are only displayed for FancyIndexed + # directories. + # Format: AddDescription "description" filename + # + #AddDescription "GZIP compressed document" .gz + #AddDescription "tar archive" .tar + #AddDescription "GZIP compressed tar archive" .tgz + + # + # ReadmeName is the name of the README file the server will look for by + # default, and append to directory listings. + # + # HeaderName is the name of a file which should be prepended to + # directory indexes. + ReadmeName README.html + HeaderName HEADER.html + + # + # IndexIgnore is a set of filenames which directory indexing should ignore + # and not include in the listing. Shell-style wildcarding is permitted. + # + IndexIgnore .??* *~ *# HEADER* README* RCS CVS *,v *,t .svn + + +# +# DefaultLanguage and AddLanguage allows you to specify the language of +# a document. You can then use content negotiation to give a browser a +# file in a language the user can understand. +# +# Specify a default language. This means that all data +# going out without a specific language tag (see below) will +# be marked with this one. You probably do NOT want to set +# this unless you are sure it is correct for all cases. +# +# * It is generally better to not mark a page as +# * being a certain language than marking it with the wrong +# * language! +# +# DefaultLanguage nl +# +# Note 1: The suffix does not have to be the same as the language +# keyword --- those with documents in Polish (whose net-standard +# language code is pl) may wish to use "AddLanguage pl .po" to +# avoid the ambiguity with the common suffix for perl scripts. +# +# Note 2: The example entries below illustrate that in some cases +# the two character 'Language' abbreviation is not identical to +# the two character 'Country' code for its country, +# E.g. 'Danmark/dk' versus 'Danish/da'. +# +# Note 3: In the case of 'ltz' we violate the RFC by using a three char +# specifier. There is 'work in progress' to fix this and get +# the reference data for rfc1766 cleaned up. +# +# Catalan (ca) - Croatian (hr) - Czech (cs) - Danish (da) - Dutch (nl) +# English (en) - Esperanto (eo) - Estonian (et) - French (fr) - German (de) +# Greek-Modern (el) - Hebrew (he) - Italian (it) - Japanese (ja) +# Korean (ko) - Luxembourgeois* (ltz) - Norwegian Nynorsk (nn) +# Norwegian (no) - Polish (pl) - Portugese (pt) +# Brazilian Portuguese (pt-BR) - Russian (ru) - Swedish (sv) +# Simplified Chinese (zh-CN) - Spanish (es) - Traditional Chinese (zh-TW) +# +AddLanguage ca .ca +AddLanguage cs .cz .cs +AddLanguage da .dk +AddLanguage de .de +AddLanguage el .el +AddLanguage en .en +AddLanguage eo .eo +AddLanguage es .es +AddLanguage et .et +AddLanguage fr .fr +AddLanguage he .he +AddLanguage hr .hr +AddLanguage it .it +AddLanguage ja .ja +AddLanguage ko .ko +AddLanguage ltz .ltz +AddLanguage nl .nl +AddLanguage nn .nn +AddLanguage no .no +AddLanguage pl .po +AddLanguage pt .pt +AddLanguage pt-BR .pt-br +AddLanguage ru .ru +AddLanguage sv .sv +AddLanguage zh-CN .zh-cn +AddLanguage zh-TW .zh-tw + +# +# LanguagePriority allows you to give precedence to some languages +# in case of a tie during content negotiation. +# +# Just list the languages in decreasing order of preference. We have +# more or less alphabetized them here. You probably want to change this. +# +LanguagePriority en ca cs da de el eo es et fr he hr it ja ko ltz nl nn no pl pt pt-BR ru sv zh-CN zh-TW + +# +# ForceLanguagePriority allows you to serve a result page rather than +# MULTIPLE CHOICES (Prefer) [in case of a tie] or NOT ACCEPTABLE (Fallback) +# [in case no accepted languages matched the available variants] +# +ForceLanguagePriority Prefer Fallback + +# +# Specify a default charset for all pages sent out. This is +# always a good idea and opens the door for future internationalisation +# of your web site, should you ever want it. Specifying it as +# a default does little harm; as the standard dictates that a page +# is in iso-8859-1 (latin1) unless specified otherwise i.e. you +# are merely stating the obvious. There are also some security +# reasons in browsers, related to javascript and URL parsing +# which encourage you to always set a default char set. +# +AddDefaultCharset UTF-8 + +# +# Commonly used filename extensions to character sets. You probably +# want to avoid clashes with the language extensions, unless you +# are good at carefully testing your setup after each change. +# See http://www.iana.org/assignments/character-sets for the +# official list of charset names and their respective RFCs. +# +AddCharset ISO-8859-1 .iso8859-1 .latin1 +AddCharset ISO-8859-2 .iso8859-2 .latin2 .cen +AddCharset ISO-8859-3 .iso8859-3 .latin3 +AddCharset ISO-8859-4 .iso8859-4 .latin4 +AddCharset ISO-8859-5 .iso8859-5 .latin5 .cyr .iso-ru +AddCharset ISO-8859-6 .iso8859-6 .latin6 .arb +AddCharset ISO-8859-7 .iso8859-7 .latin7 .grk +AddCharset ISO-8859-8 .iso8859-8 .latin8 .heb +AddCharset ISO-8859-9 .iso8859-9 .latin9 .trk +AddCharset ISO-2022-JP .iso2022-jp .jis +AddCharset ISO-2022-KR .iso2022-kr .kis +AddCharset ISO-2022-CN .iso2022-cn .cis +AddCharset Big5 .Big5 .big5 +# For russian, more than one charset is used (depends on client, mostly): +AddCharset WINDOWS-1251 .cp-1251 .win-1251 +AddCharset CP866 .cp866 +AddCharset KOI8-r .koi8-r .koi8-ru +AddCharset KOI8-ru .koi8-uk .ua +AddCharset ISO-10646-UCS-2 .ucs2 +AddCharset ISO-10646-UCS-4 .ucs4 +AddCharset UTF-8 .utf8 + +# The set below does not map to a specific (iso) standard +# but works on a fairly wide range of browsers. Note that +# capitalization actually matters (it should not, but it +# does for some browsers). +# +# See http://www.iana.org/assignments/character-sets +# for a list of sorts. But browsers support few. +# +AddCharset GB2312 .gb2312 .gb +AddCharset utf-7 .utf7 +AddCharset utf-8 .utf8 +AddCharset big5 .big5 .b5 +AddCharset EUC-TW .euc-tw +AddCharset EUC-JP .euc-jp +AddCharset EUC-KR .euc-kr +AddCharset shift_jis .sjis + +# +# AddType allows you to add to or override the MIME configuration +# file mime.types for specific file types. +# +#AddType application/x-tar .tgz +# +# AddEncoding allows you to have certain browsers uncompress +# information on the fly. Note: Not all browsers support this. +# Despite the name similarity, the following Add* directives have nothing +# to do with the FancyIndexing customization directives above. +# +#AddEncoding x-compress .Z +#AddEncoding x-gzip .gz .tgz +# +# If the AddEncoding directives above are commented-out, then you +# probably should define those extensions to indicate media types: +# +AddType application/x-compress .Z +AddType application/x-gzip .gz .tgz + +# +# AddHandler allows you to map certain file extensions to "handlers": +# actions unrelated to filetype. These can be either built into the server +# or added with the Action directive (see below) +# +# To use CGI scripts outside of ScriptAliased directories: +# (You will also need to add "ExecCGI" to the "Options" directive.) +# +#AddHandler cgi-script .cgi + +# +# For files that include their own HTTP headers: +# +#AddHandler send-as-is asis + +# +# For server-parsed imagemap files: +# +#AddHandler imap-file map + +# +# For type maps (negotiated resources): +# (This is enabled by default to allow the Apache "It Worked" page +# to be distributed in multiple languages.) +# +AddHandler type-map var + +# +# Filters allow you to process content before it is sent to the client. +# +# To parse .shtml files for server-side includes (SSI): +# (You will also need to add "Includes" to the "Options" directive.) +# +#AddType text/html .shtml +#AddOutputFilter INCLUDES .shtml + +# +# Action lets you define media types that will execute a script whenever +# a matching file is called. This eliminates the need for repeated URL +# pathnames for oft-used CGI file processors. +# Format: Action media/type /cgi-script/location +# Format: Action handler-name /cgi-script/location +# + +# +# Customizable error responses come in three flavors: +# 1) plain text 2) local redirects 3) external redirects +# +# Some examples: +#ErrorDocument 500 "The server made a boo boo." +#ErrorDocument 404 /missing.html +#ErrorDocument 404 "/cgi-bin/missing_handler.pl" +#ErrorDocument 402 http://www.example.com/subscription_info.html +# + +# +# Putting this all together, we can internationalize error responses. +# +# We use Alias to redirect any /error/HTTP_.html.var response to +# our collection of by-error message multi-language collections. We use +# includes to substitute the appropriate text. +# +# You can modify the messages' appearance without changing any of the +# default HTTP_.html.var files by adding the line: +# +# Alias /error/include/ "/your/include/path/" +# +# which allows you to create your own set of files by starting with the +# /var/www/localhost/error/include files and copying them to /your/includepath/ +# even on a per-VirtualHost basis. The default include files will display +# your Apache version number and your ServerAdmin email address regardless +# of the setting of ServerSignature. +# +# The internationalized error documents require mod_alias, mod_include +# and mod_negotiation. To activate them, uncomment the following 30 lines. + +# Alias /error/ "/var/www/localhost/error" +# +# +# AllowOverride None +# Options IncludesNoExec +# AddOutputFilter Includes html +# AddHandler type-map var +# Order allow,deny +# Allow from all +# LanguagePriority en cs de es fr it nl sv pt-br ro +# ForceLanguagePriority Prefer Fallback +# +# +# ErrorDocument 400 /error/HTTP_BAD_REQUEST.html.var +# ErrorDocument 401 /error/HTTP_UNAUTHORIZED.html.var +# ErrorDocument 403 /error/HTTP_FORBIDDEN.html.var +# ErrorDocument 404 /error/HTTP_NOT_FOUND.html.var +# ErrorDocument 405 /error/HTTP_METHOD_NOT_ALLOWED.html.var +# ErrorDocument 408 /error/HTTP_REQUEST_TIME_OUT.html.var +# ErrorDocument 410 /error/HTTP_GONE.html.var +# ErrorDocument 411 /error/HTTP_LENGTH_REQUIRED.html.var +# ErrorDocument 412 /error/HTTP_PRECONDITION_FAILED.html.var +# ErrorDocument 413 /error/HTTP_REQUEST_ENTITY_TOO_LARGE.html.var +# ErrorDocument 414 /error/HTTP_REQUEST_URI_TOO_LARGE.html.var +# ErrorDocument 415 /error/HTTP_UNSUPPORTED_MEDIA_TYPE.html.var +# ErrorDocument 500 /error/HTTP_INTERNAL_SERVER_ERROR.html.var +# ErrorDocument 501 /error/HTTP_NOT_IMPLEMENTED.html.var +# ErrorDocument 502 /error/HTTP_BAD_GATEWAY.html.var +# ErrorDocument 503 /error/HTTP_SERVICE_UNAVAILABLE.html.var +# ErrorDocument 506 /error/HTTP_VARIANT_ALSO_VARIES.html.var + + +# +# The following directives modify normal HTTP response behavior to +# handle known problems with browser implementations. +# +BrowserMatch "Mozilla/2" nokeepalive +BrowserMatch "MSIE 4\.0b2;" nokeepalive downgrade-1.0 force-response-1.0 +BrowserMatch "RealPlayer 4\.0" force-response-1.0 +BrowserMatch "Java/1\.0" force-response-1.0 +BrowserMatch "JDK/1\.0" force-response-1.0 + +# +# The following directive disables redirects on non-GET requests for +# a directory that does not include the trailing slash. This fixes a +# problem with Microsoft WebFolders which does not appropriately handle +# redirects for folders with DAV methods. +# Same deal with Apple's DAV filesystem and Gnome VFS support for DAV. +# +BrowserMatch "Microsoft Data Access Internet Publishing Provider" redirect-carefully +BrowserMatch "^WebDrive" redirect-carefully +BrowserMatch "^WebDAVFS/1.[012]" redirect-carefully +BrowserMatch "^gnome-vfs" redirect-carefully + +# Pisi Linux VHosts +# +# For Pisi Linux we include External Virtual Hosts Files. +# Please see /etc/apache2/vhosts.d/00_default_vhost.conf for the default virtual host. +# +Include /etc/apache2/vhosts.d/*.conf diff --git a/server/web/apache/files/webroot/apache.css b/server/web/apache/files/webroot/apache.css new file mode 100644 index 0000000000..4647e8853e --- /dev/null +++ b/server/web/apache/files/webroot/apache.css @@ -0,0 +1,94 @@ +/* Generated by CaScadeS, a stylesheet editor for Mozilla Composer */ + + body { + width: 96%; + margin-right: 10px; + margin-left: 10px; + padding-right: 0pt; + padding-left: 0pt; + font-size: 0.8em ! important; + padding-top: 0pt ! important; + padding-bottom: 0pt ! important; + background-color: rgb(255, 255, 255); + color: rgb(0, 0, 0); + margin-bottom: 10px ! important; + margin-top: 10px ! important; + text-align: justify ! important; + font-family: "DejaVu Sans",sans-serif ! important;4 + background-image: url(http://www.yakuter.com/wp-content/yuklemeler/jest-promosyon.gif); + background-repeat: repeat; + background-attachment: scroll; + background-color: white; + background-position: top-left; + } + + h1 { + border: 0.5px solid rgb(204, 204, 204); + padding: 10px 10px 4px; + font-family: "DejaVu Sans",Arial,sans-serif; + font-weight: bold; + vertical-align: bottom; + color: rgb(27, 87, 177); + width: 96%; + font-size: 1.75em; + background-color: rgb(247, 247, 247); + text-align: center; + } + + h2 { + padding: 0pt; + font-family: "DejaVu Sans",Arial,sans-serif; + font-size: 1.25em; + font-weight: bold; + vertical-align: bottom; + background-color: rgb(255, 255, 255); + color: rgb(27, 87, 177); + width: 95%; + text-align: left; + } + + h3 { font-size: 1em; + background-color: rgb(48, 48, 48); + color: rgb(27, 87, 177); + text-align: center; + } + + hr { border-style: none none solid; + border-color: rgb(204, 204, 204); + border-width: 0pt 0pt 1px; + text-align: center; + } + + a:link { + background-color: rgb(255, 255, 255); + text-decoration:none; + color: rgb(96, 96, 80); + } + + a:visited { + background-color: rgb(255, 255, 255); + text-decoration:none; + color: rgb(72, 70, 143); + } + + a:hover { + background-color: rgb(255, 255, 255); + color: rgb(255, 34, 0); + } + + .pardus-content { border: 1px solid rgb(240, 240, 240); + margin: 7px 7px; + padding: 24px; + min-width: 140px; + color: rgb(0, 0, 0); + background-color: rgb(252, 252, 252); + font-size: 0.8em; + } + + div.box { border: 0.5px solid rgb(204, 204, 204); + margin: 0.5em ; + padding: 10px; + background-color: rgb(247, 247, 247); + color: rgb(0, 0, 0) + } + diff --git a/server/web/apache/files/webroot/apache_pb.gif b/server/web/apache/files/webroot/apache_pb.gif new file mode 100644 index 0000000000..3a1c139fc4 Binary files /dev/null and b/server/web/apache/files/webroot/apache_pb.gif differ diff --git a/server/web/apache/files/webroot/index-de.html b/server/web/apache/files/webroot/index-de.html new file mode 100644 index 0000000000..5b32298e1b --- /dev/null +++ b/server/web/apache/files/webroot/index-de.html @@ -0,0 +1,41 @@ + + + Pisi Linux Apache Web Server Test Page + + + + + + + + + +
Pisi Linux +

Pisi Linux Webserver Testseite

+

Die gleiche Seite auf [Türkish] [Englisch] +[Spanisch] +[Brasilianisches Portugiesisch] +

+
+ +

Sie haben erfolgreich den Apache Webserver +in Pisi Linux +installiert. +Ab jetzt ist es möglich lokale HTML Webseiten in dieses Verzeichnis +hinzuzufügen. +

+ +
+

Pisi Linux, ist eine +Linux +Distribution, zur freien Nutzung, Änderung und Verbreitung, auf +der der Apache Webserver in einer sicheren Umgebung +ausgeführt werden kann. +Das folgende Apache Logo können Sie für Ihre +Webseiten auf dem Apache Webserver benutzen. 

+ +

Danke für die Benutzung von Pisi Linux und Apache!

+ +
Apache
+ + \ No newline at end of file diff --git a/server/web/apache/files/webroot/index-es.html b/server/web/apache/files/webroot/index-es.html new file mode 100644 index 0000000000..3c4534aaf4 --- /dev/null +++ b/server/web/apache/files/webroot/index-es.html @@ -0,0 +1,37 @@ + + + Pisi Linux Apache Web Server Test Page + + + + + + + + + +
Pisi Linux +

Página de prueba del servidor web de Pisi Linux

+

Ver la misma página en [Turco] +[Inglés] [Alemán] +[Portugués de Brasil] +

+
+ +

Se instaló exitosamente el servirod web Apache +en Pisi Linux. Ahora es +posible agregar páginas HTML locales en este directorio. +

+ +
+

Pisi Linux es una +distribución GNU/Linux, libre para usar, modificar y distribuir, en +la cual se puede ejecutar el servidor web Apache de manera segura. +Puede usar el logo de Apache de abajo en sus páginas web +mientras está usando el servidor Apache. 

+ +

Gracias por usar Pisi Linux y Apache!

+ +
Apache
+ + \ No newline at end of file diff --git a/server/web/apache/files/webroot/index-ptbr.html b/server/web/apache/files/webroot/index-ptbr.html new file mode 100644 index 0000000000..e338a9ff4d --- /dev/null +++ b/server/web/apache/files/webroot/index-ptbr.html @@ -0,0 +1,39 @@ + + + Página de Teste do Servidor Web Apache do Pisi Linux + + + + + + + + + +
Pisi Linux +

Página de Teste do servidor web Apache do Pisi Linux

+

See this page in +[Turkish] +[Inglês] +[German] +[Spanish]
+

+
+ +

Você instalou com sucesso o +servidor web +Apache +no Pisi Linux. Agora é +possível adicionar páginas HTML localizadas neste diretório. +

+ +
+

Pisi Linux é uma +distribuição GNU/Linux livre para ser usada, modificada e distribuída +na qual você pode executar o servidor web Apache de uma forma segura. +Você pode usar o seguinte logo Apache enquanto o utilizar como servidor +nas suas páginas web. Obrigado por utilizar o Pisi Linux e o Apache!

+ +
Apache
+ + \ No newline at end of file diff --git a/server/web/apache/files/webroot/index-tr.html b/server/web/apache/files/webroot/index-tr.html new file mode 100644 index 0000000000..629746b33b --- /dev/null +++ b/server/web/apache/files/webroot/index-tr.html @@ -0,0 +1,38 @@ + + + Pisi Linux Apache Web Sunucusu kurulumu için deneme sayfası + + + + + + + + + +
Pisi Linux +

Pisi Linux Web Sunucusu Deneme Sayfası

+

Bu sayfanın hazırlandığı diğer diller: [İngilizce] +[Almanca] +[İspanyolca] [Brezilya +Portekizcesi]
+

+
+ +

Bu sayfayı gördüğünüze göre Pisi Linux üzerine Apache +Web Sunucusu'nu +başarılı bir şekilde kurdunuz demektir. Bu sayfanın bulunduğu dizine +kendi sayfalarınızı ekleyip hemen yayımlamaya başlayabilirsiniz.

+ +
+

Pisi Linux, Apache Web +Sunucusu'nun güvenli bir şekilde çalışabileceği özgür bir GNU/Linux +dağıtımıdır.

+ +

Apache Web Sunucusu'nu kullanırken aşağıdaki Apache logosunu +kullanabilirsiniz. Pisi Linux ve Apache'yi kullandığınız için teşekkür +ederiz!

+ +
Apache
+ + diff --git a/server/web/apache/files/webroot/index.html b/server/web/apache/files/webroot/index.html new file mode 100644 index 0000000000..87ce7b19b9 --- /dev/null +++ b/server/web/apache/files/webroot/index.html @@ -0,0 +1,38 @@ + + + Pisi Linux Apache Web Server Test Page + + + + + + + + + +
Pisi Linux +

Pisi Linux Web Server Test Page

+

See this page in [Turkish] [German] [Spanish] +[Brazilian +Portuguese]
+

+
+ +

You have successfully installed Apache web server +under Pisi Linux. Now +it's +possible to add HTML pages located in this directory. +

+ +
+

Pisi Linux, is a free +to use, +modify and distribute GNU/Linux distribution on which you can run +Apache +web server in a secure manner. +You can use the following Apache logo while using Apache web server in +your web pages. Thanks for using Pisi Linux and Apache!

+ +
Apache
+ + \ No newline at end of file diff --git a/server/web/apache/files/webroot/pisi-linux.png b/server/web/apache/files/webroot/pisi-linux.png new file mode 100644 index 0000000000..8aacc57bac Binary files /dev/null and b/server/web/apache/files/webroot/pisi-linux.png differ diff --git a/server/web/apache/pspec.xml b/server/web/apache/pspec.xml new file mode 100644 index 0000000000..904922d8c2 --- /dev/null +++ b/server/web/apache/pspec.xml @@ -0,0 +1,172 @@ + + + + + apache + http://httpd.apache.org/ + + Pisi Linux Admins + admins@pisilinux.org + + Apache-2.0 + server.web + service + Apache web server + Apache HTTP Server is a free software/open source web server for Unix-like systems, Microsoft Windows, Novell NetWare and other operating systems. Apache is notable for playing a key role in the initial growth of the World Wide Web, and continues to be the most popular web server in use, serving as the de facto reference platform against which other web servers are designed and judged. + http://archive.apache.org/dist/httpd/httpd-2.4.16.tar.bz2 + + apr-devel + nss-devel + lua-devel + zlib-devel + openssl-devel + libxml2-devel + db-devel + expat-devel + libpcre-devel + apr-util-devel + cyrus-sasl-devel + + + + + apache + + nss + apr + lua + apr-util + cyrus-sasl + openldap-client + zlib + openssl + libxml2 + libpcre + db + expat + + + /etc + /usr/sbin + /usr/bin + /usr/include + /var/log/apache2 + /var/www + /run/apache2 + /var/cache + /usr/share/doc + /usr/share/man + /usr/lib + /lib/systemd/system + + + + apache.service + + apache2.confd + + httpd.conf + + 00_default_vhost.conf + + 00_apache_manual.conf + 40_mod_ssl.conf + 41_mod_ssl.default-vhost.conf + 45_mod_dav.conf + 46_mod_ldap.conf + + webroot/apache.css + webroot/apache_pb.gif + webroot/index.html + webroot/index-tr.html + webroot/index-ptbr.html + webroot/index-es.html + webroot/index-de.html + webroot/pisi-linux.png + + + System.Package + System.Service + + + + + + 2015-09-04 + 2.4.16 + Version bump. + Ertuğrul Erata + ertugrulerata@gmail.com + + + 2015-02-01 + 2.4.12 + Version bump. + Hakan Yıldız + hknyldz93@gmail.com + + + 2014-12-20 + 2.4.10 + Rebuild for lua. + Aydın Demirel + aydin.demirel@pisilinux.org + + + 2014-10-02 + 2.4.10 + Version bump. + Aydın Demirel + aydin.demirel@pisilinux.org + + + 2014-05-30 + 2.4.9 + Version bump. + Alihan Öztürk + alihan@pisilinux.org + + + 2014-01-11 + 2.4.6 + Rebuild for cyrus-sasl + Kamil Atlı + suvarice@gmail.com + + + 2013-12-30 + 2.4.6 + Rebuild + Aydın Demirel + aydin.demirel@pisilinux.org + + + 2013-11-16 + 2.4.6 + Version Bump + Aydın Demirel + aydin.demirel@pisilinux.org + + + 2013-04-23 + 2.4.3 + Dep fixed + Osman Erkan + osman.erkan@pisilinux.org + + + 2013-02-17 + 2.4.3 + Cosmetic corrections + Ertan Güven + ertan@pisilinux.org + + + 2012-10-07 + 2.4.3 + First release + Erdem Artan + admins@pisilinux.org + + + diff --git a/server/web/apache/translations.xml b/server/web/apache/translations.xml new file mode 100644 index 0000000000..28a1cf2ad4 --- /dev/null +++ b/server/web/apache/translations.xml @@ -0,0 +1,9 @@ + + + + apache + Apache web sunucusu + Apache Webserver + Dünyanın en çok tercih edilen web sunucu olan Apache artık diğer genelağ sunucularının standartlarını belirlemek için takip ettiği hızlı, güçlü, esnek ve yüksek özelleştirilebilirliğe sahip bir genelağ sunucusudur. + + diff --git a/server/web/component.xml b/server/web/component.xml new file mode 100644 index 0000000000..e7499a12fe --- /dev/null +++ b/server/web/component.xml @@ -0,0 +1,3 @@ + + server.web +