%define _sysconfdir /etc
%define _localstatedir /var

%define contentdir /home/httpd
%define apache_ver 1.3.41
%define mod_ssl_ver 2.8.31
%define mm_ver 1.4.2

Summary: The most widely used Web server on the Internet.
Summary(ja): インターネットで最も広く利用されているウェブサーバ
Name: apache
Version: 1.3.41
Release: 4%{?_dist_release}

Group: System Environment/Daemons
License: Apache License, Version 2.0

Vendor: Project Vine
Distribution: Vine Linux

#Source0: ftp://ftp.apache.org/apache/dist/apache_%{apache_ver}.tar.gz
Source0: http://archive.apache.org/dist/httpd/apache_%{apache_ver}.tar.bz2
Source1: ftp://ftp.modssl.org/source/mod_ssl-%{mod_ssl_ver}-%{apache_ver}.tar.gz
Source2: ftp://ftp.ossp.org/pkg/lib/mm/mm-%{mm_ver}.tar.gz

Source3: http://www.snert.com/Software/Throttle/mod_throttle211.tgz
Source4: spacer48.png
Source5: apache-0vl4-index.html
Source6: PoweredByVine.png
Source7: httpd.init
Source8: apache.logrotate
Source9: apache-access.conf
Source10: apache-0vl4-httpd.conf
Source11: apache-srm.conf
Source12: ftp://ftp.cohprog.com/pub/apache/module/1.3.0/mod_bandwidth.c
Source13: mod_put.c
Source14: SSL-Certificate-Creation
Source20: README-apache.conf.d

# Source100: www.apache.jp-20020317.tgz
Source100: apache-jpdocs-20020327.tgz

# for x86_64 architecture support
Source207: httpd.init.lib64

Patch1: apache-1.3.31-apxs.patch
# Patch2: apache_1.3.14-phhttpd-eapi.patch
Patch4: mod_ssl-2.6.4-tty.patch
Patch5: apache_1.3.12-piranha.patch
# Patch6: mod_ssl-2.8.8-openssl.patch

# Patch for security fix
# Patch200: patch for tmp-file problem from SuSE 8.0 mm-1.1.3-290
# Patch200: mm-tmp-race.dif
# Patch210: patch for htpasswd problem
# Patch210: apache-htpasswd.patch
# Patch290: apache-1.3.33_CVE-2007-5000.patch
# Patch300: apache-1.3.39_CVE-2007-6388.patch
Patch310: apache-1.3.39_CVE-2007-4465.patch
Patch320: apache-1.3.39_CVE-2008-0005.patch
Patch330: apache-1.3.41_CVE-2010-0010.patch

# Patch for Vine
Patch0: apache_1.3.26-vine.patch
# Patch10: apache_1.3.12-disable_iso8859_charset.patch
Patch20: apache_1.3.22-use_expat_lite.patch
Patch30: apache_1.3.26-layout.patch
Patch40: apache-1.3.41-getline.patch

# for x86_64 architecture support
#Patch300: mod_ssl-2.8.28-libssl.lib64.patch
Patch300: mod_ssl-2.8.31-libssl.lib64.patch


BuildRoot: %{_tmppath}/%{name}-%{version}-root
BuildRequires: findutils, openssl-devel, perl
BuildRequires: db4-devel, gdbm-devel
# Requires: /etc/mime.types, gawk, file, /usr/bin/find
# Prereq: /sbin/chkconfig, /bin/mktemp, /bin/rm, mailcap, grep, textutils
# Prereq: /usr/sbin/useradd
Requires: mailcap, gawk, file, findutils
Requires(post): chkconfig, mktemp, coreutils, mailcap, grep
Requires(pre): shadow-utils
Requires(preun): chkconfig
Provides: webserver

%description
Apache is a powerful, full-featured, efficient and freely-available
Web server. Apache is also the most popular Web server on the
Internet.

Install the apache package if you need a Web server.


%description -l ja
Apacheはパワフルで高機能, 有能でいてかつ自由に利用できるウェブサーバです。
Apacheはインターネットで最も広く利用されているウェブサーバです。

ウェブサーバを必要とするならapacheパッケージをインストールしてください。

%package -n mod_ssl
Summary: Cryptography support for the Apache web server.
Version: %{mod_ssl_ver}
Group: System Environment/Daemons
Requires: apache = %{apache_ver}-%{release}
Requires(post): openssl, dev

%description -n mod_ssl
The mod_ssl module provides strong cryptography for the Apache web
server via the Secure Sockets Layer (SSL) and Transport Layer Security
(TLS) protocols.

%description -n mod_ssl -l ja
apache web サーバをSSL経由で動かすための mod_ssl モジュールです．
mod_ssl を始めてインストールしたときにはインストール時には仮のCSR
が作成されますが、正確な情報を記述したCSRを作成してください。

作成方法は rpm -q --scripts mod_ssl によって表示されるコマンドを参考に
することもできます。

%package devel
Summary: Development tools for the Apache Web server.
Summary(ja): Apacheウェブサーバのための開発ツール
Group: Development/Libraries
Obsoletes: secureweb-devel

%description devel
The apache-devel package contains the APXS binary and other files that
you'll need to build Dynamic Shared Objects (DSOs) for Apache.

If you are installing the Apache Web server, and you want to be 
able to compile or develop additional modules for Apache, you'll 
need to install this package.

%description -l ja devel
apache-develパッケージは Apache用のダイナミック共有オブジェクト(DSOs)
を構築するのに必要なApacheウェブサーバのソースコードとAPXSバイナリを含
んでいます。

Apacheウェブサーバをインストールして、かつ、追加モジュールを開発または
コンパイルするには、このパッケージをインストールする必要があります。


%package manual
Summary: Documentation for the Apache Web server.
Summary(ja): Apacheウェブサーバのためマニュアル文章
Group: Applications/Documentation
Requires: apache >= 1.3.26-0vl4

%description manual
The apache-manual package contains the complete manual and reference
guide for the Apache Web server.  If you need Apache documentation
installed on the local machine, install this package.  The information
can also be found on the Web at http://www.apache.org/docs/.

%description -l ja manual
apache-manualパッケージは Apacheウェブサーバの完全なマニュアルとリファ
レンスガイドを含んでいます。もしApacheの文章がローカルマシン上に必要な
ら、このパッケージをインストールしてください。
この情報は、http://www.apache.org/docs/にも見ることができます。

%prep
%setup -q -n apache_%{apache_ver} -a 1 -a 2 -a 3
%ifarch x86_64
%patch300 -p0 -b .lib64
%endif


EAPI_MM=`pwd`/mm-%{mm_ver} ; export EAPI_MM

pushd mm-%{mm_ver}
# %patch200 -p1 -b .mm
#configure --disable-shared
popd

#%patch6 -p0 -b .openssl
pushd mod_ssl-%{mod_ssl_ver}-%{apache_ver}
%patch4 -p2 -b .tty
#configure --with-apache=`cd ..;pwd` --with-mm=$EAPI_MM
popd

%patch0 -p1 -b .redhat
%patch1 -p1 -b .apxs
#%patch3 -p0 -b .eapi
#%patch2 -p1 -b .phhttpd
%patch5 -p1 -b .piranha
#%patch10 -p1 -b .disable_iso8859_charset
%patch20 -p1 -b .use_expat_lite
%patch30 -p1 -b .layout
%patch40 -p0 -b .getline

# %patch210 -p1 -b .htpasswd
# %patch290 -p1 -b .CVE-2007-5000
# %patch300 -p4 -b .CVE-2007-6388
%patch310 -p1 -b .CVE-2007-4465
%patch320 -p1 -b .CVE-2008-0005
%patch330 -p4 -b .CVE-2010-0010

# mv eapi guys
cp -p mod_ssl-%{mod_ssl_ver}-%{apache_ver}/pkg.eapi/*.c src/ap/
cp -p mod_ssl-%{mod_ssl_ver}-%{apache_ver}/pkg.eapi/*.h src/include/

%build
EAPI_MM=`pwd`/mm-%{mm_ver} ; export EAPI_MM

pushd $EAPI_MM
%configure --disable-shared
make
popd

pushd mod_ssl-%{mod_ssl_ver}-%{apache_ver}
%configure --with-apache=`cd ..;pwd` --with-mm=$EAPI_MM
popd

OPTIM="$RPM_OPT_FLAGS -DSTACK=_STACK" \
	./configure --prefix=%{_prefix} \
	--libexecdir=%{_libdir}/apache \
	--mandir=%{_mandir} \
	--with-layout=Vine \
	--add-module=%{SOURCE12} \
	--add-module=%{SOURCE13} \
%if 0
	--activate-module=src/modules/throttle/mod_throttle.o \
%endif
    --add-module=src/modules/throttle/mod_throttle.c \
	--enable-module=all \
	--enable-shared=max \
	--enable-shared=ssl \
	--enable-rule=EAPI \
	--disable-rule=WANTHSREGEX \
	--disable-module=auth_dbm \
	--with-perl=/usr/bin/perl \
	--enable-suexec \
	--suexec-docroot=%{contentdir}/html \
	--suexec-caller=apache
make

%install
rm -rf $RPM_BUILD_ROOT
make install root=$RPM_BUILD_ROOT
strip $RPM_BUILD_ROOT%{_sbindir}/httpd
strip $RPM_BUILD_ROOT%{_libdir}/apache/*so

# remove apachectl; we have our own SYSV init stuff
rm $RPM_BUILD_ROOT%{_sbindir}/apachectl
rm $RPM_BUILD_ROOT%{_mandir}/man8/apachectl.8

# install SYSV init stuff
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d
%ifarch x86_64
install -m755 %{SOURCE207} $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/httpd
%else
install -m755 %{SOURCE7} $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/httpd
%endif

for I in 0 1 2 6; do
	mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/rc$I.d
	ln -s ../init.d/httpd $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/rc$I.d/K15httpd
done
for I in 3 5; do
	mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/rc$I.d
	ln -s ../init.d/httpd $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/rc$I.d/S85httpd
done

# install log rotation stuff
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d
install -m644 %{SOURCE8} $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d/apache

ln -s ../..%{_var}/log/httpd $RPM_BUILD_ROOT%{_sysconfdir}/httpd/logs
ln -s ../..%{_libdir}/apache $RPM_BUILD_ROOT%{_sysconfdir}/httpd/modules

mkdir -p $RPM_BUILD_ROOT%{contentdir}/html
rm -f $RPM_BUILD_ROOT%{contentdir}/html/index.html.ja.*
install -m644 %{SOURCE5} $RPM_BUILD_ROOT%{contentdir}/html/index.html.ja
install -m644 %{SOURCE5} $RPM_BUILD_ROOT%{contentdir}/html/index.html.html
install -m644 %{SOURCE6} $RPM_BUILD_ROOT%{contentdir}/html

# jpdocs
tar xzf %{SOURCE100}
cp -r apache-jpdocs/httpd-docs-1.3-ja/htdocs/manual $RPM_BUILD_ROOT%{contentdir}/html/manual-ja
mkdir -p $RPM_BUILD_ROOT%{_mandir}/ja/man1
cp apache-jpdocs/httpd-docs-1.3-ja/man/*.1 $RPM_BUILD_ROOT%{_mandir}/ja/man1
mkdir -p $RPM_BUILD_ROOT%{_mandir}/ja/man8
cp apache-jpdocs/httpd-docs-1.3-ja/man/*.8 $RPM_BUILD_ROOT%{_mandir}/ja/man8
rm $RPM_BUILD_ROOT%{_mandir}/ja/man8/apachectl.8
pushd $RPM_BUILD_ROOT%{_mandir}/ja/man1 ; gzip -9 * ; popd
pushd $RPM_BUILD_ROOT%{_mandir}/ja/man8 ; gzip -9 * ; popd

# replace Apache's default config files with our own versions
install -m644 %{SOURCE9} $RPM_BUILD_ROOT/etc/httpd/conf/access.conf
install -m644 %{SOURCE10} $RPM_BUILD_ROOT/etc/httpd/conf/httpd.conf
install -m644 %{SOURCE11} $RPM_BUILD_ROOT/etc/httpd/conf/srm.conf

# install conf.d directory
install -d $RPM_BUILD_ROOT/%{_sysconfdir}/httpd/conf.d
install -m 644 %{SOURCE20} $RPM_BUILD_ROOT/%{_sysconfdir}/httpd/conf.d/README

# Remove default keys and certs, install docs, and point to the right makefile.
mkdir -p $RPM_BUILD_ROOT%{contentdir}/html/manual/mod/mod_ssl/
install -m644 mod_ssl-%{mod_ssl_ver}-%{apache_ver}/pkg.ssldoc/*.{html,gif,jpg} \
        $RPM_BUILD_ROOT%{contentdir}/html/manual/mod/mod_ssl/
rm -f $RPM_BUILD_ROOT/etc/httpd/conf/ssl.*/server.*
ln -s ../../../usr/share/ssl/certs/Makefile $RPM_BUILD_ROOT/etc/httpd/conf

# install apache source code for devel package
#mkdir -p $RPM_BUILD_ROOT/usr/src
#tar xzf $RPM_SOURCE_DIR/apache_%{version}.tar.gz -C $RPM_BUILD_ROOT/usr/src
find $RPM_BUILD_ROOT -type f | \
	xargs grep -l "/usr/local/bin/perl5" | \
	xargs perl -pi -e "s|/usr/local/bin/perl5|/usr/bin/perl|g;"
find $RPM_BUILD_ROOT -type f | \
	xargs grep -l "/usr/local/bin/perl" | \
	xargs perl -pi -e "s|/usr/local/bin/perl|/usr/bin/perl|g;"


# clean up apxs
sed "s^$RPM_BUILD_ROOT^^g" $RPM_BUILD_ROOT%{_sbindir}/apxs > apxs.tmp && \
cat apxs.tmp > $RPM_BUILD_ROOT%{_sbindir}/apxs

# create a prototype session cache
mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/cache/
touch $RPM_BUILD_ROOT%{_localstatedir}/cache/ssl_gcache_data.{dir,pag,sem}

# fixup the documentation file naming
#find $RPM_BUILD_ROOT%{contentdir} -name "*.html.html" | xargs rename .html.html .html

%clean
rm -rf $RPM_BUILD_ROOT

%post
/sbin/chkconfig --add httpd
/etc/rc.d/init.d/httpd condrestart
[ -f %{_sysconfdir}/mime.types ] || exit 0
# safely add .htm to mime types if it is not already there
TEMPTYPES=`/bin/mktemp /tmp/mimetypes.XXXXXX`
[ -z "$TEMPTYPES" ] && {
  echo "could not make temporary file, htm not added to /etc/mime.types" >&2
  exit 1
}
( grep -v "^text/html"  %{_sysconfdir}/mime.types
  types=$(grep "^text/html" %{_sysconfdir}/mime.types | cut -f2-)
  echo -en "text/html\t\t\t"
  for val in $types ; do
      if [ "$val" = "htm" ] ; then
          continue
      fi
      echo -n "$val "
  done
  echo "htm"
) > $TEMPTYPES
cat $TEMPTYPES > %{_sysconfdir}/mime.types && /bin/rm -f $TEMPTYPES

%pre
# Add the "apache" user
/usr/sbin/useradd -c "Apache" -u 48 \
	-s /bin/false -r -d %{contentdir} apache 2> /dev/null || :
exit 0

%preun
if [ $1 = 0 ]; then
   %{_sysconfdir}/rc.d/init.d/httpd stop > /dev/null 2>&1
   /sbin/chkconfig --del httpd
fi

%post -n mod_ssl
/sbin/ldconfig
umask 077

if [ ! -f %{_sysconfdir}/httpd/conf/ssl.key/server.key ] ; then
%{_bindir}/openssl genrsa -rand /proc/apm:/proc/cpuinfo:/proc/dma:/proc/filesystems:/proc/interrupts:/proc/ioports:/proc/pci:/proc/rtc:/proc/uptime 1024 > %{_sysconfdir}/httpd/conf/ssl.key/server.key 2> /dev/null
fi

if [ ! -f %{_sysconfdir}/httpd/conf/ssl.crt/server.crt ] ; then
cat << EOF | %{_bindir}/openssl req -new -key %{_sysconfdir}/httpd/conf/ssl.key/server.key -x509 -days 365 -out %{_sysconfdir}/httpd/conf/ssl.crt/server.crt 2>/dev/null
--
SomeCountry
SomeState
SomeCity
SomeOrganization
SomeOrganizationalUnit
localhost.localdomain
root@localhost.localdomain
EOF
fi

  
%files
%defattr(-,root,root)
%doc ABOUT_APACHE LICENSE README cgi-bin
%dir %{_sysconfdir}/httpd/
%dir %{_sysconfdir}/httpd/conf
%dir %{_sysconfdir}/httpd/conf.d
%{_sysconfdir}/httpd/conf.d/README
%config(noreplace) %{_sysconfdir}/httpd/conf/access.conf
%config(noreplace) %{_sysconfdir}/httpd/conf/srm.conf
%config(noreplace) %{_sysconfdir}/httpd/conf/httpd.conf
%config(noreplace) %{_sysconfdir}/httpd/conf/magic

%{_sysconfdir}/httpd/logs
%{_sysconfdir}/httpd/modules
%config(noreplace) %{_sysconfdir}/logrotate.d/apache
%config %{_sysconfdir}/rc.d/init.d/httpd

%config(missingok) /etc/rc.d/rc3.d/S85httpd
%config(missingok) /etc/rc.d/rc5.d/S85httpd
%config(missingok) /etc/rc.d/rc0.d/K15httpd
%config(missingok) /etc/rc.d/rc1.d/K15httpd
%config(missingok) /etc/rc.d/rc2.d/K15httpd
%config(missingok) /etc/rc.d/rc6.d/K15httpd

%dir %{contentdir}
%dir %{contentdir}/cgi-bin
%dir %{contentdir}/html
%config(noreplace) %{contentdir}/html/index.html*
%{contentdir}/html/*.png
%{contentdir}/html/*.gif
%{contentdir}/icons

%dir %{_libdir}/apache
%{_libdir}/apache/httpd.exp
%{_libdir}/apache/libproxy.so
%{_libdir}/apache/mod*.so

%{_mandir}/man1/*
%{_mandir}/man8/ab.8*
%{_mandir}/man8/httpd.8*
%{_mandir}/man8/logresolve.8*
%{_mandir}/man8/rotatelogs.8*
%{_mandir}/man8/suexec.8*

%{_mandir}/ja/*/*

%{_sbindir}/ab
%{_sbindir}/httpd
%{_sbindir}/logresolve
%{_sbindir}/rotatelogs
#%attr(4510,root,apache) %{_sbindir}/suexec
%attr(0711,root,root) %{_sbindir}/suexec
%{_bindir}/*

#%attr(-,nobody,nobody) %dir %{_var}/cache/httpd
%attr(0755,apache,root) %dir %{_var}/cache/httpd
%dir %{_var}/log/httpd

%files manual
%defattr(-,root,root)
%{contentdir}/html/manual
%{contentdir}/html/manual-ja

%files devel
%defattr(-,root,root)
%{_includedir}/apache
%{_sbindir}/apxs
%{_mandir}/man8/apxs.8*

%files -n mod_ssl
%defattr(-,root,root)
%doc $RPM_SOURCE_DIR/SSL-Certificate-Creation
%doc mod_ssl-%{mod_ssl_ver}-%{apache_ver}/{README*,LICENSE,NEWS,CHANGES,CREDITS}
%{contentdir}/html/manual/mod/mod_ssl/
%{_libdir}/apache/libssl.so
%{_sysconfdir}/httpd/conf/Makefile
%attr(0700,root,root) %dir %{_sysconfdir}/httpd/conf/ssl.*
%attr(0600,root,root) %ghost %{_localstatedir}/cache/ssl_gcache_data.dir
%attr(0600,root,root) %ghost %{_localstatedir}/cache/ssl_gcache_data.pag
%attr(0600,root,root) %ghost %{_localstatedir}/cache/ssl_gcache_data.sem
%dir %{_sysconfdir}/httpd
%{_sysconfdir}/httpd/conf/ssl.*/*

%changelog
* Sun Mar 20 2011 Yoji TOYODA <bsyamato@sea.plala.or.jp> 1.3.41-4
- rebuild with openssl-1.0.0d
- fix OPTIM

* Thu Jul 29 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.3.41-3
- added Patch330 for CVE-2010-0010
- added Patch40 for building currnet toolchain
- added BR: db4-devel, gdbm-devel
- updated mm to 1.4.2

* Sat Aug 23 2008 Shu KONNO <owa@bg.wakwak.com> 1.3.41-2vl5
- updated mod_ssl-2.8.28-libssl.lib64.patch to 2.8.31
- spec in utf-8

* Wed Jun 18 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.3.41-1vl5
- rebuilt with db4-4.6.21
- applied new versioning policy
- sync with VinePlus/4.0 package
  * Tue Feb 12 2008 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 1.3.41-0vl1
  - build for VinePlus 4.x
  - new upstream release with security fix
  - drop unnessary unnecessary patches (patch 290,300)
  * Wed Jan 16 2008 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 1.3.39-0vl2
  - add patch310 for fix CVE-2007-4465
  - add patch320 for fix CVE-2008-0005
  * Thu Jan 10 2008 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 1.3.39-0vl1
  - new upstream release with security fix
  - add patch290 CVE-2007-5000
  - add patch300 CVE-2007-6388

* Sat Jun  9 2007 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.3.37-0vl6
- rebuilt with openssl-0.9.8e

* Thu May 10 2007 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 1.3.37-0vl5
- rebuilt with new toolchain and db4-4.3.x

* Tue Mar 27 2007 Shu KONNO <owa@bg.wakwak.com> 1.3.37-0vl4
- added Patch300: mod_ssl-2.8.28-libssl.lib64.patch

* Sat Oct 21 2006 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.3.37-0vl3
- changed apache-manual Group to Applications/Documentation

* Mon Jul 31 2006 Shu KONNO <owa@bg.wakwak.com> 1.3.37-0vl2
- updated apache to 1.3.37 (CVE-2006-3747)
- updated mod_ssl to 2.8.28-1.3.37
- changed URLs

* Fri Mar 03 2006 Shu KONNO <owa@bg.wakwak.com> 1.3.34-0vl2
- added option '--libexecdir=%%{_libdir}/apache' to configure
- added httpd.init.lib64

* Wed Nov 09 2005 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 1.3.34-0vl1
- rebuild for VineSeed 
- blush up doc section

* Mon Oct 24 2005 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 1.3.34-0vl0.1
- Test package
- new upstream release
  - update to 1.3.34
  - update to mod_ssl 2.8.25-1.3.34
  - update to mm 1.4.0

* Sat Nov 27 2004 IKEDA Katsumi <ikeda@webmasters.gr.jp> 1.3.33-0vl2
- Added a security patch for buffer overflow in the htpasswd utility.
  - Patch210: apache-htpasswd.patch
- Moved %%patch4 above %%configure in mod_ssl-* directory.

* Sun Oct 31 2004 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.33-0vl1
- new upstream release
  - update to 1.3.33
  - update mod_ssl to 2.8.22-1.3.33
- drop obsolete patch (Patch100)

* Sat Oct 30 2004 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.32-0vl2
- add Patch100 to fix buffer overflow in mod_include (CAN-2004-0940).

* Sun Oct 24 2004 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.32-0vl1
- new upstream release
  - update to 1.3.32
  - update mod_ssl to 2.8.21-1.3.32
- drop obsolete patch (Patch210)

* Wed Oct 13 2004 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 1.3.31-0vl6
- rebuilt with db4-4.2.25

* Fri Jul 23 2004 NISHIMURA Daisuke <nishi@graco.c.u-tokyo.ac.jp> 1.3.31-0vl5
- Patch210: fix buffer overflow in mod_proxy (CVE CAN-2004-0492)
- update License
- apache-manual requires apache for %{contentdir} and MultiViews

* Sun Jul 18 2004 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.31-0vl4
- update mod_ssl to 2.8.19-1.3.31
  - Changes with mod_ssl 2.8.19 (27-May-2004 to 16-Jul-2004)
     *) Fix ssl_log() related format string vulnerability in mod_proxy
        hook functions.

* Sun Jul 11 2004 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.31-0vl3
- add %%{_sysconfdir}/httpd/conf.d for additional configuration file (conf.d/*.conf)
  thanks to HOTTA Michihide <hotta AT net-newbie DOT com>

* Sat May 29 2004 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.31-0vl2
- update mod_ssl to 2.8.18-1.3.31
  - Changes with mod_ssl 2.8.18 (11-May-2004 to 27-May-2004)
     *) Fix buffer overflow in "SSLOptions +FakeBasicAuth" implementation
        if the Subject-DN in the client certificate exceeds 6KB in length.
        (CVE CAN-2004-0488).
     *) Handle the case of OpenSSL retry requests after interrupted system
        calls during the SSL handshake phase.
     *) Remove some unused functions.

* Thu May 13 2004 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.31-0vl1
- new upstream release
- update mod_ssl to 2.8.17-1.3.31

* Fri Mar 26 2004 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.29-0vl2
- rebuild with openssl-0.9.7d

* Mon Nov 10 2003 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.29-0vl1
- new upstream release 1.3.29
- update mod_ssl to 2.8.16-1.3.29

* Sun Jul 20 2003 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.28-0vl1
- new upstream release 1.3.28
- update mod_ssl to 2.8.15-1.3.28

* Sat Mar 29 2003 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.27-0vl3
- update mod_ssl to 2.8.14-1.3.27
  - Changes with mod_ssl 2.8.14 (18-Mar-2002 to 21-Mar-2003)
    *) Fixed logic in the destruction of a temporary certificate
       structure and this way avoid a crash due to freeing NULL object.
    *) Removed one newly introduced X509_free() call in the context of
       SSL_get_certificate(), because this function does not increment a
       reference count (although SSL_get_peer_certificate() does).
    *) Fixed hash-table based shared memory session cache (shmht)
       implementation by making sure that the underlying hash table
       library does not crash if memory cannot be allocated.
  - Changes with mod_ssl 2.8.13 (23-Oct-2002 to 18-Mar-2003)
    *) Always enforce RSA blinding on RSA private keys in order to be
       resistent to timing attacks.
    *) Added timeout also to the "pre-sucking" of the trailing data in
       POST request handling.
    *) Correctly shutdown shared memory pools on fork+exec situations.
    *) Bugfix SSL client certificate verification: OpenSSL was not
       informed with SSL_set_verify_result(ssl, X509_V_OK) in case
       mod_ssl forced the verification to be ok.
    *) Consistently use OPENSSL_free() instead of plain free() to
       deallocate memory chunks allocated inside OpenSSL.
    *) Fixed various memory leaks related to X509 certificates.

* Sat Oct 26 2002 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.27-0vl2
- update mod_ssl to 2.8.12-1.3.27
  - security bug fix.
    - Fixed potential Cross-Site-Scripting bug.
    - Allow also 8192 bytes of shared memory data size.

* Sat Oct 5 2002 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.27-0vl1
- new upstream release 1.3.27 for security fix
- update mod_ssl to 2.8.11-1.3.27

* Thu Aug 8 2002 Masaki Shinomiya <shino@pos.to>  1.3.26-0vl4
- MultiViews manual (see [VineSeed:06745] )
- condrestart in %post
- allow to rebuild on Vine 2.0/2.1/2.5

* Wed Jul 31 2002 IWAI Masaharu <iwai@alib.jp> 1.3.26-0vl3
- SECURITY: fixed for tmp-file problem
  - from SuSE 8.0 mm-1.1.3-290
    * Fri Jul 26 2002 - poeml@suse.de
    - security fix for tmp-file problem

* Sun Jun 30 2002 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.26-0vl2
- update mod_ssl to 2.8.10-1.3.26
- update patch0,
  do not show distribution name, when ServerTokens was set.

* Wed Jun 19 2002 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.26-0vl1
- new upstream release 1.3.24
  - fixed security hole
- update mod_ssl to 2.8.9-1.3.26
- add patch30 to use Vine Linux layout

* Wed Mar 27 2002 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.24-0vl1
- new upstream release 1.3.24
- update mod_ssl 2.8.8-1.3.24
- fixed missing tag "</a>" in apache-vine-index.html
- added manual-ja to %%files manual

* Wed Mar 27 2002 Shoji Matsumoto <shom@vinelinux.org> 1.3.23-0vl5
- update Japanese Document (www.apache.jp to CVS tree)
- update apache-vine-index.html

* Sun Mar 17 2002 Shoji Matsumoto <shom@vinelinux.org> 1.3.23-0vl4
- add www.apache.jp-20020317.tgz (Japanese Document Mirror)
- update apache-vine-index.html

* Wed Feb 27 2002 Toru Sagami <sagami@vinelinux.org> 1.3.23-0vl3
- use --add-module for mod_throttle.c instead of --activate-module
- make configtest exits with RETVAL
- remove missing doc

* Wed Feb 27 2002 Satoshi MACHINO <machino@vinelinux.org> 1.3.23-0vl2
- added patch2 for openssl patch(updated ;p)

* Thu Feb 26 2002 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.23-0vl1
- new upstream release 1.3.23
- update mod_throttle 2.11
- update mod_ssl 2.8.7-1.3.23
- drop patch2, patch6

* Wed Jan 23 2002 Toru Sagami <sagami@vinelinux.org> 1.3.22-0vl3
- added %%{_localstatedir} definition as /var (%%{_var})
- added pre script to add user "apache" and prereq for /usr/sbin/useradd
- change owner/group of cache directory to "apache" from "nobody"
- changed httpd.conf to run httpd as user/owner "apache"
- added more mod_ssl docs
- typo fixed in default index.html
- added graceful/configtest in httpd.init (courtesy of [vine-users:038237])
- set NameWidth=* by default
- don't put "noreplace" to httpd.init 

* Thu Oct 25 2001 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 1.3.22-0vl2
- added patch20 to force using libexpat-lite in the source
  even if external expat packages (found in VineSeedPlus) are installed

* Wed Oct 17 2001 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.22-0vl1
- upstream release 1.3.22
- update mod_ssl to 2.8.5-1.3.22
- remove waste files..

* Thu Oct  4 2001 IWAI Masaharu <iwaim@cc.mbn.or.jp> 1.3.20-0vl7
- added noreplace flag (%%config file is not replaced)

* Thu Sep 13 2001 Tomoya TAKA <tomoya@olive.plala.or.jp>
- 1.3.20-0vl6
- fix a typo in Prereq

* Wed Sep 12 2001 Shoji Matsumoto <shom@vinelinux.org> 1.3.20-0vl5
- replace filenames in *Req: to packagenames (for apt)

* Wed Aug 29 2001 Jun Nishii <jun@vinelinux.org> 1.3.20-0vl4
- restore index.html and poweredby.png for Vine

* Mon Jul 16 2001 MATSUBAYASHI 'Shaolin' Kohji <shaolin@vinelinux.org>
- 1.3.20-0vl3
- rebuilt with openssl-0.9.6b

* Tue Jul  3 2001 Jun Nishii <jun@vinelinux.org> 1.3.20-0vl2
- added mod_ssl subpackage

* Thu Mar  1 2001 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.20-0vl1
- update to 1.3.20

* Thu Mar  1 2001 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.19-0vl1
- update to 1.3.19

* Fri Feb  2 2001 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.17-0vl1
- update to 1.3.17-fix

* Wed Dec 27 2000 Tomoya TAKA <tomoya@olive.plala.or.jp> 1.3.14-0vl4
- fix to handle man pages correctly with _mandir

* Sun Nov 19 2000 Satoshi MACHINO <machino@vinelinux.org> 1.3.14-0vl3
- build with gcc-2.95.3
- partially used rpmmacros

* Sat Nov  7 2000 Kazuhisa TAKEI <takei@vinelinux.org> 1.3.14-0vl2
- change from file depend to package name depend. (Requires: )

* Sat Oct 14 2000 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.14-0vl1
- update to 1.3.14

* Thu Jul 20 2000 Yasuyuki Furukawa <furukawa@vinelinux.org>
- fixed typo at default index.html.

* Thu Jun  8 2000 Yasuyuki Furukawa <furukawa@vinelinux.org>
- remove '"' of path from default httpd.conf for linuxconf.

* Thu Apr 20 2000 Yasuyuki Furukawa <furukawa@vinelinux.org>
- added disable_iso8859_charset patch for character turnning depend on server side.

* Wed Apr 19 2000 Yasuyuki Furukawa <furukawa@vinelinux.org>
- modified default httpd.conf about LanguageProc
- use vine-patch instead of RedHat.
- modified default index.html for Vine.

* Wed Apr 19 2000 Yasuyuki Furukawa <furukawa@vinelinux.org>
- added japanese summary and descriptions

* Wed Mar 01 2000 Nalin Dahyabhai <nalin@redhat.com>
- make suexec limit UIDs and GIDs to < 51 instead of 100

* Fri Feb 25 2000 Nalin Dahyabhai <nalin@redhat.com>
- update to 1.3.12
- add EAPI patch

* Thu Feb 17 2000 Preston Brown <pbrown@redhat.com>
- ifmodule directive for php stuff.
- load mod_perl before mod_php (#8169)

* Tue Feb 14 2000 Zach Brown <zab@redhat.com>
- minor fix to phhttpd patch

* Thu Feb 10 2000 Preston Brown <pbrown@redhat.com>
- improved default index.html.

* Thu Feb 03 2000 Preston Brown <pbrown@redhat.com>
- strip dynamically loadable modules.

* Mon Feb 02 2000 Zach Brown <zab@redhat.com>
- add phhttpd 'Tunnel' directive and code to use it

* Mon Jan 31 2000 Cristian Gafton <gafton@redhat.com>
- rebuild to fix depenencies

* Tue Jan 25 2000 Bernhard Rosenkraenzer <bero@redhat.com>
- 1.3.11
- deal with the fact that RPM now gzips man pages

* Wed Jan 12 2000 Preston Brown <pbrown@redhat.com>
- new poweredby.png w/new logo
- apxs.8 man page moved to devel archive (#6661)
- don't remove old logfiles on package de-install (#8268)
- more updates to logrotate to avoid spurious cron mail (#8110)

* Mon Jan 10 2000 Preston Brown <pbrown@redhat.com>
- mod_throttle added; mod_bandwidth updated.

* Mon Dec 17 1999 Dale Lovelace <dale@redhat.com>
- Add configuration for mod_put to httpd.conf

* Mon Dec 06 1999 Preston Brown <pbrown@redhat.com>
- documentation cleanups in httpd.conf (#5357, #6655)
- fixed logrotate script to ignore error if no apache running (#7074)

* Wed Nov 10 1999 Jeff Johnson <jbj@redhat.com>
- add put module.

* Thu Nov 04 1999 Preston Brown <pbrown@redhat.com>
- make suexec non-suid.  People can enable it if they wish themselves.
- somehow the unified httpd.conf got trashed.  fixed.
- manual is now a subpackage
- point to /usr/share/magic as the magic file location; don't use the
  apache-specific one.
- fix apxs module installation issues (#5650)


* Tue Sep 21 1999 Bill Nottingham <notting@redhat.com>
- move DSO in httpd.conf to after ServerRoot

* Mon Sep 20 1999 Preston Brown <pbrown@redhat.com>
- it is httpd stop, not httpsd stop (# 5254)
- suexec added (# 5257)

* Thu Sep 09 1999 Preston Brown <pbrown@redhat.com>
- remove apachectl man page (# 4459)

* Fri Aug 27 1999 Preston Brown <pbrown@redhat.com>
- upgraded to 1.3.9
- fix bug # 3680 (suexec docroot was wrong)
- fix bug # 2378 (logrotate with -USR1 not -HUP)
- fix bug # 3548 (logrotate complains if apache not running)
- httpd.conf is now in the unified apache format as distributed

* Mon Aug 16 1999 Bill Nottingham <notting@redhat.com>
- initscript munging

* Sat May 21 1999 Bill Nottingham <notting@redhat.com>
- fix broken link in index.html

* Wed Apr 07 1999 Bill Nottingham <notting@redhat.com>
- allow indexes in /doc

* Tue Apr 06 1999 Preston Brown <pbrown@redhat.com>
- strip binaries

* Mon Apr 05 1999 Preston Brown <pbrown@redhat.com>
- prerequire /bin/rm, added /doc path pointing to /usr/doc for localhost

* Fri Mar 26 1999 Preston Brown <pbrown@redhat.com>
- updated log rotating scripts to not complain if logs aren't present.

* Thu Mar 25 1999 Preston Brown <pbrown@redhat.com>
- fixed up path to perl

* Wed Mar 24 1999 Preston Brown <pbrown@redhat.com>
- updated init script to conform to new standards
- upgraded to 1.3.6, fixed apxs patch

* Mon Mar 22 1999 Preston Brown <pbrown@redhat.com>
- clean up logfiles on deinstallation

* Sun Mar 21 1999 Cristian Gafton <gafton@redhat.com> 
- auto rebuild in the new build environment (release 4)

* Fri Mar 12 1999 Cristian Gafton <gafton@redhat.com>
- added mod_bandwidth
- updated to 1.3.4
- prereq mailcap

* Fri Dec 18 1998 Cristian Gafton <gafton@redhat.com>
- added patch to disable building support for ndbm
- build against glibc 2.1

* Mon Oct 12 1998 Cristian Gafton <gafton@redhat.com>
- updated to 1.3.3 to catch up with bug fixes
- added the /usr/bin/* binaries to the spec file list

* Fri Sep 25 1998 Cristian Gafton <gafton@redhat.com>
- change ownership of cache dir to nobody
- added "Red Hat" to the server string
- updated to version 1.3.2
- fixed all references to httpsd in config files

* Fri Sep 04 1998 Cristian Gafton <gafton@redhat.com>
- small fixes to the spec file
- patch to handle correctly the -d <newroot> option
- leave out the .usr.src.apache_%{version} for now

* Thu Sep 03 1998 Preston Brown <pbrown@redhat.com>
- patched apxs not to bomb out if it can't find httpd

* Wed Sep 02 1998 Preston Brown <pbrown@redhat.com>
- upgraded to apache 1.3.1.
- Heavy rewrite.
- changed providing a_web_server to just webserver.  Humor is not an option.

* Mon Aug 10 1998 Erik Troan <ewt@redhat.com>
- updated to build as non-root user
- added patch to defeat header dos attack

* Thu May 07 1998 Prospector System <bugs@redhat.com>
- translations modified for de, fr, tr

* Wed May 06 1998 Cristian Gafton <gafton@redhat.com>
- fixed the default config files to be more paranoid about security

* Sat May 02 1998 Cristian Gafton <gafton@redhat.com>
- fixed init script
- added index.htm to the list of acceptable indexes

* Sat May 02 1998 Cristian Gafton <gafton@redhat.com>
- updated to 1.2.6
- added post script to install htm extension for text/html into
  /etc/mime.types

* Wed Apr 22 1998 Michael K. Johnson <johnsonm@redhat.com>
- enhanced sysv init script

* Tue Jan 06 1998 Erik Troan <ewt@redhat.com>
- updated to 1.2.5, which includes many security fixes

* Wed Dec 31 1997 Otto Hammersmith <otto@redhat.com>
- fixed overkill on http.init stop

* Wed Dec 31 1997 Erik Troan <ewt@redhat.com>
- added patch for backslash DOS attach

* Thu Nov 06 1997 Donnie Barnes <djb@redhat.com>
- added htdigest binary to file list

* Mon Nov 03 1997 Donnie Barnes <djb@redhat.com>
- made the default index.html be config(noreplace) so we no longer
  blow away other folks' index.html

* Wed Oct 29 1997 Donnie Barnes <djb@redhat.com>
- added chkconfig support
- added restart|status options to initscript
- renamed httpd.init to httpd

* Tue Oct 07 1997 Elliot Lee <sopwith@redhat.com>
- Redid spec file, patches, etc. from scratch.
