Sophie

Sophie

distrib > Mandriva > 10.2 > x86_64 > by-pkgid > a625c2e0a83f6257de1cb16f6e383556 > files > 6

privoxy-3.0.3-6mdk.src.rpm

%define privoxyconf %{_sysconfdir}/%{name}

Summary:	Privoxy - privacy enhancing HTTP proxy
Name:		privoxy
Version:	3.0.3
Release:	6mdk
License:	GPL
BuildRoot:	%{_tmppath}/%{name}-%{version}-buildroot
Group:		Networking/Other
URL:		http://www.privoxy.org/

Source0:	http://prdownloads.sf.net/ijbswa/%{name}-%{version}-stable-src.tar.bz2
# privoxy should belong to section 8 of manpage, not section 1
Patch0:		privoxy-3.0.3-manpage.patch.bz2
# use daemon user to run privoxy
Patch1:		privoxy-2.9.13-daemon.patch.bz2
# (fc) 3.0.3-2mdk fix some defaults (don't deanimate gif, allow auto-refresh)
Patch2:		privoxy-3.0.3-defaults.patch.bz2
# (fc) 3.0.3-6mdk fix ie-exploits filter with Amazon
Patch3:		privoxy-3.0.3-amazon.patch.bz2

Prereq:		rpm-helper
Obsoletes:	junkbuster
Provides:	junkbuster = %{version}-%{release}
BuildRequires:	docbook-style-dsssl
BuildRequires:	docbook-dtd31-sgml
BuildRequires:	lynx
BuildRequires:	man
BuildRequires:	pcre-devel

%description
Privoxy is a web proxy with advanced filtering
capabilities for protecting privacy, filtering web page content,
managing cookies, controlling access, and removing ads, banners,
pop-ups and other obnoxious Internet Junk. Privoxy has a very
flexible configuration and can be customized to suit individual needs
and tastes. Privoxy has application for both stand-alone
systems and multi-user networks.

Privoxy was previously called Internet Junkbuster.

To configure privoxy, go to http://config.privoxy.org/

Privoxy proxy is running on port 8118

%prep
%setup -n %{name}-%{version}-stable -q
%patch0 -p1 -b .manpage
%patch1 -p1 -b .daemon
%patch2 -p1 -b .defaults
%patch3 -p1 -b .amazon

# Remove various CVS files
find -name 'CVS' -type d |xargs -r rm -rf
find -name '.cvsignore' |xargs -r rm -rf

autoheader
autoconf

# clean build
rm -f doc/source/ldpOK.dsl

%build

%serverbuild
%configure2_5x
%make
make redhat-dok

%install
rm -rf %{buildroot}
mkdir -p %{buildroot}%{_sbindir} \
         %{buildroot}%{_mandir}/man8 \
         %{buildroot}/var/log/privoxy \
         %{buildroot}%{privoxyconf}/templates \
         %{buildroot}%{_sysconfdir}/logrotate.d \
         %{buildroot}%{_initrddir}

install -m 755 privoxy %{buildroot}%{_sbindir}/privoxy
install -m 644 privoxy.1 %{buildroot}%{_mandir}/man8/privoxy.8

perl -pi -e "s|/etc/junkbuster/|/etc/privoxy/|g" privoxy.{monthly,weekly}
# Install various config files
for i in *.action default.filter trust; do
	install -m 644 $i %{buildroot}%{privoxyconf}/
done
for i in templates/*; do
	install -m 644 $i %{buildroot}%{privoxyconf}/templates/
done
install -m 644 privoxy.logrotate %{buildroot}%{_sysconfdir}/logrotate.d/%{name}
install -m 755 privoxy.init %{buildroot}%{_initrddir}/%{name}

# verify all file locations, etc. in the config file
# don't start with ^ or commented lines are not replaced
sed -e 's!^confdir.*!confdir /etc/privoxy!g' \
    -e 's!^logdir.*!logdir /var/log/privoxy!g' \
    < config  > %{buildroot}%{privoxyconf}/config

%triggerin -- msec < 0.17
for i in 0 1 2 3 4 5; do
  permfile="%{_sysconfdir}/security/msec/perm.$i"
  if grep -q '^/var/log/privoxy' $permfile; then
    perl -pi -e 's|^/var/log/privoxy\s.*|/var/log/prixovy\t\t\t\tdaemon.daemon\t700|' $permfile
  else
    echo -e "/var/log/prixovy\t\t\t\tdaemon.daemon\t700" >> $permfile
  fi
done

%post
%_post_service privoxy

%preun
%_preun_service privoxy


%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-,root,root)
%doc AUTHORS ChangeLog README  
%doc doc/text doc/webserver
%attr (0700,daemon,daemon) /var/log/privoxy
%config(noreplace) %{_sysconfdir}/logrotate.d/%{name}
%{_sbindir}/*
%{_mandir}/man8/*
%config %{_initrddir}/%{name}

%defattr(664,daemon,daemon,755)
%dir %{privoxyconf}
%config(noreplace) %{privoxyconf}/config
%config            %{privoxyconf}/default.action
%config(noreplace) %{privoxyconf}/default.filter
%config            %{privoxyconf}/standard.action
%config(noreplace) %{privoxyconf}/templates
%config(noreplace) %{privoxyconf}/trust
%config(noreplace) %{privoxyconf}/user.action


%changelog
* Mon Jan 10 2005 Frederic Crozat <fcrozat@mandrakesoft.com> 3.0.3-6mdk 
- Patch3 : fix ie-exploit filter to not be triggered by Amazon

* Fri Jul 23 2004 Frederic Crozat <fcrozat@mandrakesoft.com> 3.0.3-5mdk
- Fix perms on privoxy config directory

* Wed Jul 21 2004 Frederic Crozat <fcrozat@mandrakesoft.com> 3.0.3-4mdk
- Fix default perms/owner of configuration file, otherwise privoxy won't
  be able to modify its config files from web interface.

* Fri Feb 06 2004 Frederic Crozat <fcrozat@mandrakesoft.com> 3.0.3-3mdk
- Works better when applying patch :)

* Fri Feb 06 2004 Frederic Crozat <fcrozat@mandrakesoft.com> 3.0.3-2mdk
- Patch2: fix some defaults (don't deanimate gif, allow auto-refresh)

* Sat Jan 31 2004 Frederic Crozat <fcrozat@mandrakesoft.com> 3.0.3-1mdk
- Release 3.0.3
- Remove source 1 (merged upstream)
- Regenerate patch0

* Sat Oct 04 2003 Abel Cheung <deaddog@deaddog.org> 3.0.2-2mdk
- Source1: Newer default.action posted on privoxy site
- Don't mark default.action and standard.action as noreplace, because
  sysadmin are expected to add customization to user.action only
- Mark logrotate entry as noreplace
- Config files are read only (not read-write) by daemon user
- Some touches on dependency

* Wed Mar 26 2003 Frederic Crozat <fcrozat@mandrakesoft.com> - 3.0.2-1mdk
- Release 3.0.2
- Regenerate patch0

* Thu Aug 29 2002 Frederic Crozat <fcrozat@mandrakesoft.com> 3.0.0-1mdk
- Release 3.0.0 (stable)
- Regenerate patch0

* Mon Aug 19 2002 Frederic Crozat <fcrozat@mandrakesoft.com> 2.9.20-1mdk
- Release 2.9.20
- Regenerate patch0

* Thu Aug  8 2002 Frederic Crozat <fcrozat@mandrakesoft.com> 2.9.18-1mdk
- Release 2.9.18
- Regenerate patch0
- Remove patch2 (merged upstream)
- Fix BuildRequires

* Thu Aug  1 2002 Frederic Crozat <fcrozat@mandrakesoft.com> 2.9.16-2mdk
- Patch2: fix the webbug regexp (bug 577802) seen on linuxtoday.com page

* Mon Jul 29 2002 Frederic Crozat <fcrozat@mandrakesoft.com> 2.9.16-1mdk
- Release 2.9.16
- Regenerate patch 0

* Tue Jul  2 2002 Frederic Crozat <fcrozat@mandrakesoft.com> 2.9.14-3mdk
- Fix description and summary (Thanks to Andreas Oesterhelt)

* Tue Apr 23 2002 Frederic Crozat <fcrozat@mandrakesoft.com> 2.9.14-2mdk
- Tag config files as noreplace, since they have changed names when junbuster
  became privoxy 

* Fri Apr 19 2002 Frederic Crozat <fcrozat@mandrakesoft.com> 2.9.14-1mdk
- Release 2.9.14
- Regenerate patches 0 & 1
- Fix forgottent references to junkbuster in cron files

* Mon Apr  8 2002 Frederic Crozat <fcrozat@mandrakesoft.com> 2.9.13-1mdk
- Name change : junkbuster is now privoxy
- Release 2.9.13
- WARNING : privoxy is now listening to port 8118

* Tue Mar 19 2002 Frederic Crozat <fcrozat@mandrakesoft.com> 2.9.11-1mdk
- Release 2.9.11
- Patch1: use daemon user to run junkbuster
- Integrate modifications from Abel Cheung <maddog@linux.org.hk>
 - Take description from bundled spec file
 - Add entry to msec perm file to prevent msec changing log directory owner
 - Follow Debian's use of port 5865 instead of 8000
 - Spec rewrite
 - Patch0: fix manpage section
 - Don't add noreplace tag for config files, they just changed format
 - Remove Obsoletes: junkbuster-raw junkbuster-blank

* Mon Sep 17 2001 Lenny Cartier <lenny@mandrakesoft.com> 2.0.2-6mdk
- fix permissions on /etc/junkbuster/* files

* Wed Aug 08 2001 Lenny Cartier <lenny@mandrakesoft.com> 2.0.2-5mdk
- rebuild

* Fri Jan 12 2001 Lenny Cartier <lenny@mandrakesoft.com> 2.0.2-4mdk
- rebuild

* Wed Jul 05 2000 Lenny Cartier <lenny@mandrakesoft.com> 2.0.2-3mdk
- fix permission on /var/log/junkbuster

* Fri Apr 28 2000 Lenny Cartier <lenny@mandrakesoft.com> 2.0.2-2mdk
- fix group
- fix permission on sources

* Thu Mar 02 2000 Lenny Cartier <lenny@mandrakesoft.com>
- mandrake build

* Sun Sep 12 1999 Stefan Waldherr <stefan@waldherr.org>
       Jan Willamowius (jan@janhh.shnet.org) fixed a bug in the 
       code which prevented the JB from handling URLs of the form
       user:password@www.foo.com. Fixed.

* Mon Aug  2 1999 Stefan Waldherr <stefan@waldherr.org>
	Blank images are no longer cached, thanks to a hint from Markus 
        Breitenbach <breitenb@rbg.informatik.tu-darmstadt.de>. The user 
        agent is NO longer set by the Junkbuster. Sadly, many sites depend 
        on the correct browser version nowadays. Incorporated many 
	suggestions from Jan "Yenya" Kasprzak <kas@fi.muni.cz> for the
        spec file. Fixed logging problem and since runlevel 2 does not 
        use networking, I replaced /etc/rc.d/rc2.d/S84junkbuster with
        /etc/rc.d/rc2.d/K09junkbuster thanks to Shaw Walker 
        <walker@netgate.net>. You should now be able to build this RPM as 
        a non-root user (mathias@weidner.sem.lipsia.de).

* Sun Jan 31 1999 Stefan Waldherr <stefan@waldherr.org>
	/var/log/junkbuster set to nobody. Added /etc/junkbuster/imagelist
	to allow more sophisticated matching of blocked images. Logrotate
	logfile. Added files for auto-updating the blocklist et al.

* Wed Dec 16 1998 Stefan Waldherr <stefan@waldherr.org>
	Configure blank version via config file. No separate blank
	version anymore. Added Roland's <roland@spinnaker.rhein.de>
	patch to show a logo instead of a blank area. Added a suggestion
	from Alex <alex@cocoa.demon.co.uk>: /var/lock/subsys/junkbuster.
	More regexps in the blocklist. Prepared the forwardfile for
	squid. Extended image regexp with help from gabriel 
	<somlo@CS.ColoState.EDU>.

* Thu Nov 19 1998 Stefan Waldherr <stefan@waldherr.org>
	All RPMs now identify themselves in the show-proxy-args page.
	Released Windoze version. Run junkbuster as nobody instead of
	root. 

* Fri Oct 30 1998 Stefan Waldherr <stefan@waldherr.org>
	Newest version. First release (hence the little version number
	mixture -- 2.0.2-0 instead of 2.0-7). This version tightens 
	security over 2.0.1; some multi-user sites will need to change 
	the listen-address in the configuration file. The blank version of
        the Internet Junkbuster has a more sophisticated way of replacing
	images. All RPMs identify themselves in the show-proxy-args page.

* Thu Sep 23 1998 Stefan Waldherr <stefan@waldherr.org>
	Modified the blocking feature, so that only GIFs and JPEGs are
	blocked and replaced but not HTML pages. Thanks to 
	"Gerd Flender" <plgerd@informatik.uni-siegen.de> for this nice
	idea. Added numerous stuff to the blocklist. Keep patches in
        seperate files and no longer in diffs (easier to maintain).

* Tue Jun 16 1998 Stefan Waldherr <swa@cs.cmu.edu>
        Moved config files to /etc/junkbuster directory, moved man page,
	added BuildRoot directive (Thanks to Alexey Nogin <ayn2@cornell.edu>)
        Made new version junkbuster-raw (which is only a stripped version of 
        the junkuster rpm, i.e. without my blocklist, etc.)

* Tue Jun 16 1998 (2.0-1)
	Uhm, not that much. Just a new junkbuster version that
	fixes a couple of bugs ... and of course a bigger 
	blocklist with the unique Now-less-ads-than-ever(SM)
	feature.
	Oh, one thing: I changed the default user agent to Linux -- no 
	need anymore to support Apple.

* Tue Jun 16 1998 (2.0-0)
	Now-less-ads-than-ever (SM)
	compiled with gcc instead of cc
	compiled with -O3, thus it should be a little faster
	show-proxy-args now works
	/etc/junkbuster.init wasn't necessary

* Tue Jun 16 1998 (1.4)
	some more config files were put into /etc
	The junkbuster-blank rpm returns a 1x1 pixel image, that gets 
	displayed by Netscape instead of the blocked image.
	Read http://www.waldherr.org/junkbuster/ for
	further info.

* Tue Jun 16 1998 (1.3)
	The program has been moved to /usr/sbin (from /usr/local/bin)
	Init- and stopscripts (/etc/rc.d/rc*) have been added so
	that the junkbuster starts automatically during bootup.
	The /etc/blocklist file is much more sophisticated. Theoretically
	one should e.g. browse all major US and German newspapers without
	seeing one annoying ad.
	junkbuster.init was modified. It now starts junkbuster with an
	additional "-r @" flag.