diff options
author | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 13:49:04 -0700 |
---|---|---|
committer | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 17:38:18 -0700 |
commit | 56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch) | |
tree | 3f91093cdb475e565ae857f1c5a7fd339e2d781e /www-servers/webfs | |
download | gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2 gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip |
proj/gentoo: Initial commit
This commit represents a new era for Gentoo:
Storing the gentoo-x86 tree in Git, as converted from CVS.
This commit is the start of the NEW history.
Any historical data is intended to be grafted onto this point.
Creation process:
1. Take final CVS checkout snapshot
2. Remove ALL ChangeLog* files
3. Transform all Manifests to thin
4. Remove empty Manifests
5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$
5.1. Do not touch files with -kb/-ko keyword flags.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests
X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project
X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration
X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn
X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts
X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration
X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging
X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'www-servers/webfs')
-rw-r--r-- | www-servers/webfs/Manifest | 1 | ||||
-rw-r--r-- | www-servers/webfs/files/webfs-1.21-CVE-2013-0347.patch | 15 | ||||
-rw-r--r-- | www-servers/webfs/files/webfs-1.21-Variables.mk-dont-strip-binaries-on-install.patch | 12 | ||||
-rw-r--r-- | www-servers/webfs/files/webfs.confd | 27 | ||||
-rw-r--r-- | www-servers/webfs/files/webfs.initd-r1 | 30 | ||||
-rw-r--r-- | www-servers/webfs/metadata.xml | 7 | ||||
-rw-r--r-- | www-servers/webfs/webfs-1.21-r3.ebuild | 49 |
7 files changed, 141 insertions, 0 deletions
diff --git a/www-servers/webfs/Manifest b/www-servers/webfs/Manifest new file mode 100644 index 000000000000..1c6359059546 --- /dev/null +++ b/www-servers/webfs/Manifest @@ -0,0 +1 @@ +DIST webfs-1.21.tar.gz 44249 SHA256 98c1cb93473df08e166e848e549f86402e94a2f727366925b1c54ab31064a62a SHA512 68b9b3163a21be8a549e395295b27dd8ce9b575183d6c36b05b98bdc310917cf2dc653ff73bdb78a8c063674a8e9480211ec5c28b8a676f9cee41fa962cfd473 WHIRLPOOL 6d5b1d079c98d2125b6a57d56f4c8fa7693c43bc20c1c29a1ff64db9c9217c85a13f9ae784eee2505b580260d72919970fa875d93c3d31d9c0d10d6307309d9e diff --git a/www-servers/webfs/files/webfs-1.21-CVE-2013-0347.patch b/www-servers/webfs/files/webfs-1.21-CVE-2013-0347.patch new file mode 100644 index 000000000000..26e225def360 --- /dev/null +++ b/www-servers/webfs/files/webfs-1.21-CVE-2013-0347.patch @@ -0,0 +1,15 @@ +--- ./webfsd.c ++++ ./webfsd.c +@@ -918,8 +918,11 @@ + } else { + if (NULL == (logfh = fopen(logfile,"a"))) + xperror(LOG_WARNING,"open access log",NULL); +- else ++ else { + close_on_exec(fileno(logfh)); ++ if (0 != chmod(logfile,S_IRUSR|S_IWUSR)) ++ xperror(LOG_WARNING,"chmod access log",NULL); ++ } + } + } + diff --git a/www-servers/webfs/files/webfs-1.21-Variables.mk-dont-strip-binaries-on-install.patch b/www-servers/webfs/files/webfs-1.21-Variables.mk-dont-strip-binaries-on-install.patch new file mode 100644 index 000000000000..03f2f5c59816 --- /dev/null +++ b/www-servers/webfs/files/webfs-1.21-Variables.mk-dont-strip-binaries-on-install.patch @@ -0,0 +1,12 @@ +diff -Naur webfs-1.21.orig/mk/Variables.mk webfs-1.21/mk/Variables.mk +--- webfs-1.21.orig/mk/Variables.mk 2009-02-03 01:14:18.000000000 +0100 ++++ webfs-1.21/mk/Variables.mk 2009-02-03 01:16:01.000000000 +0100 +@@ -23,7 +23,7 @@ + CXX ?= g++ + MOC ?= $(if $(QTDIR),$(QTDIR)/bin/moc,moc) + INSTALL ?= install +-INSTALL_BINARY := $(INSTALL) -s ++INSTALL_BINARY := $(INSTALL) + INSTALL_SCRIPT := $(INSTALL) + INSTALL_DATA := $(INSTALL) -m 644 + INSTALL_DIR := $(INSTALL) -d diff --git a/www-servers/webfs/files/webfs.confd b/www-servers/webfs/files/webfs.confd new file mode 100644 index 000000000000..5c4de3ad9b74 --- /dev/null +++ b/www-servers/webfs/files/webfs.confd @@ -0,0 +1,27 @@ +# Configuration for webfsd init script + +WEBFS_PORT=80 +WEBFS_DOCROOT=/var/www/localhost/htdocs +WEBFS_INDEX=index.html +WEBFS_LOG=/var/log/webfsd.log + +# set server name +#WEBFS_SERVNAME= + +# uncomment to chroot to specified dir +#WEBFS_CHROOT="/var/www/localhost" + +# max allowed connections (defaults to 32) +#WEBFS_MAXCONN=50 + +# uncomment to enable directory listings +#WEBFS_DIR_LIST=true + +# uncomment to enable SSL (you'll need to add -C <cert> -P <pass> to WEBFS_OPTS) +#WEBFS_SSL=true + +# uncomment to enable ipv6 +#WEBFS_IPV6=true + +# Add any extra options here. See webfsd for more information. +#WEBFS_OPTS="" diff --git a/www-servers/webfs/files/webfs.initd-r1 b/www-servers/webfs/files/webfs.initd-r1 new file mode 100644 index 000000000000..1327756145aa --- /dev/null +++ b/www-servers/webfs/files/webfs.initd-r1 @@ -0,0 +1,30 @@ +#!/sbin/runscript +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +depend() { + need net +} + +start() { + WEBFS_OPTS="-p ${WEBFS_PORT:-80} -f ${WEBFS_INDEX:-index.html} ${WEBFS_OPTS}" + [ -n "${WEBFS_DOCROOT}" ] && WEBFS_OPTS="${WEBFS_OPTS} -r ${WEBFS_DOCROOT}" + [ -n "${WEBFS_CHROOT}" ] && WEBFS_OPTS="${WEBFS_OPTS} -R ${WEBFS_CHROOT}" + [ -n "${WEBFS_LOG}" ] && WEBFS_OPTS="${WEBFS_OPTS} -L ${WEBFS_LOG}" + [ -n "${WEBFS_MAXCONN}" ] && WEBFS_OPTS="${WEBFS_OPTS} -c ${WEBFS_MAXCONN}" + [ -n "${WEBFS_IPV6}" ] && WEBFS_OPTS="${WEBFS_OPTS} -6" + [ -n "${WEBFS_SSL}" ] && WEBFS_OPTS="${WEBFS_OPTS} -S" + [ -n "${WEBFS_SERVNAME}" ] && WEBFS_OPTS="${WEBFS_OPTS} -n ${WEBFS_SERVNAME}" + [ -n "${WEBFS_DIR_LIST}" ] || WEBFS_OPTS="${WEBFS_OPTS} -j" + + ebegin "Starting webfsd" + start-stop-daemon --start --quiet --exec /usr/bin/webfsd -- ${WEBFS_OPTS} + eend $? "Failed to start webfsd" +} + +stop() { + ebegin "Stopping webfsd" + start-stop-daemon --stop --quiet --exec /usr/bin/webfsd + eend $? "Failed to stop webfsd" +} diff --git a/www-servers/webfs/metadata.xml b/www-servers/webfs/metadata.xml new file mode 100644 index 000000000000..a40624fba8f0 --- /dev/null +++ b/www-servers/webfs/metadata.xml @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<maintainer> + <email>maintainer-needed@gentoo.org</email> +</maintainer> +</pkgmetadata> diff --git a/www-servers/webfs/webfs-1.21-r3.ebuild b/www-servers/webfs/webfs-1.21-r3.ebuild new file mode 100644 index 000000000000..3b88eaed9af2 --- /dev/null +++ b/www-servers/webfs/webfs-1.21-r3.ebuild @@ -0,0 +1,49 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=5 +inherit eutils + +DESCRIPTION="Lightweight HTTP server for static content" +SRC_URI="http://dl.bytesex.org/releases/${PN}/${P}.tar.gz" +HOMEPAGE="http://linux.bytesex.org/misc/webfs.html" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 ppc x86 ~arm-linux ~x86-linux" +IUSE="ssl threads" + +DEPEND="ssl? ( dev-libs/openssl:0= )" + +RDEPEND="${DEPEND} + app-misc/mime-types" + +src_prepare() { + epatch "${FILESDIR}/${P}-Variables.mk-dont-strip-binaries-on-install.patch" + epatch "${FILESDIR}/${P}-CVE-2013-0347.patch" + sed -e "s:/etc/mime.types:${EPREFIX}\\0:" -i GNUmakefile || die "sed failed" +} + +src_compile() { + local myconf + use ssl || myconf="${myconf} USE_SSL=no" + use threads && myconf="${myconf} USE_THREADS=yes" + + emake prefix="${EPREFIX}/usr" ${myconf} +} + +src_install() { + local myconf + use ssl || myconf="${myconf} USE_SSL=no" + use threads && myconf="${myconf} USE_THREADS=yes" + einstall ${myconf} mandir="${ED}/usr/share/man" + newinitd "${FILESDIR}"/${PN}.initd-r1 ${PN} + newconfd "${FILESDIR}"/${PN}.confd ${PN} + dodoc README +} + +pkg_preinst() { + # Fix existing log permissions for bug #458892. + chmod 0600 "${EROOT}/var/log/webfsd.log" 2>/dev/null +} |