%define version 0.2.16 %define release 2 %define name smeserver-webfilter Summary: web filtering proxy for SME Server Name: %{name} Version: %{version} Release: %{release}%{?dist} Epoch: 9 License: GPL Group: Networking/Daemons Source: %{name}-%{version}.tar.gz BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot BuildArchitectures: noarch BuildRequires: e-smith-devtools Requires: squidGuard >= 1.4 Requires: squidclamav Requires: perl(File::Tail) Requires: perl(Getopt::Long) Requires: perl(DBI) Requires: perl(URI) Obsoletes: smeserver-squidguard Provides: smeserver-squidguard %description Web proxy filtering based on squidguard and squidclamav %changelog * Wed May 25 2022 Jean-Philippe Pialasse 0.2.16-2.sme - import to SME 10 and Koozali buildsys [SME: 11978] * Thu Nov 19 2015 Daniel Berteaud 0.2.16-1 - Add pt-br localization (by Jáder Marasca) * Fri May 15 2015 Daniel Berteaud 0.2.15-1 - Add Danish localization (by Jan B Thygesen) * Wed Jun 25 2014 Daniel Berteaud 0.2.14-1 - fix cleanup cronjob on EL6 - Pre-create log files to prevent warnings * Tue Nov 12 2013 Daniel Berteaud 0.2.13-1 - New branch for SME9 * Fri Sep 6 2013 Daniel Berteaud 0.2.12-1 - Correctly handle more than two unrestricted IP or network * Wed Jan 23 2013 Daniel Berteaud 0.2.11-1 - It's now possible to log on a remote MySQL server * Wed Oct 24 2012 Daniel Berteaud 0.2.10-1 - Don't rotate tables, just purge old entries * Wed Oct 24 2012 Daniel Berteaud 0.2.9-1 - Handle error:unsupported-request-method in squid logs * Wed Oct 24 2012 Daniel Berteaud 0.2.8-1 - Add it locale for the panel, thanks to Nicola Tiana * Mon Oct 22 2012 Daniel Berteaud 0.2.7-1 - Use UTF-8 for de locale file * Mon Oct 22 2012 Daniel Berteaud 0.2.6-1 - Add de locale to the panel, thanks to Daniel Schiffer * Fri Oct 19 2012 Daniel Berteaud 0.2.5-1 - Fix processing of denied CONNECT in squidGuard logs - Properly escape domain names * Fri Oct 19 2012 Daniel Berteaud 0.2.4-1 - Use larger varchar for URL and domain names * Thu Oct 18 2012 Daniel Berteaud 0.2.3-1 - Optimize database inserts - Log stderr to stdout in squid-db-logd run script - Add missing dbuser option in squid-db-logd * Wed Oct 17 2012 Daniel Berteaud 0.2.2-1 - Fix processing CONNECT lines * Sun Oct 14 2012 Daniel Berteaud 0.2.1-1 - Ignore stats requests from squidclient * Sun Oct 7 2012 Daniel Berteaud 0.2.0-1 - Include Squid Database Logging Daemon (squid-db-logd) * Sun Oct 7 2012 Daniel Berteaud 0.1.4-1 - Fix hidding disabled caegories * Tue Sep 11 2012 Daniel Berteaud 0.1.3-1 - Add whitelists to squidclamav * Mon Aug 27 2012 Daniel Berteaud 0.1.2-1 - Fix en-us locale (label AV Filtering) * Fri Jul 6 2012 Daniel Berteaud 0.1.1-1 - Spawn more redirect children * Mon Apr 16 2012 Daniel Berteaud 0.1.0-1 - Rename to smeserver-webfilter - Add AV filtering with squidclamav - Simplified panel - Log cron job to dev null - Use quiet rsync arg * Tue Apr 03 2012 Daniel Berteaud 0.1.2-1 - Fix ownership of log files * Tue Mar 27 2012 Daniel Berteaud 0.1.1-1 - Add .log suffix to log files * Tue Mar 27 2012 Daniel Berteaud 0.1.0-1 - Move to git * Tue Feb 21 2012 Daniel Berteaud 0.1-1 - initial release %prep %setup -q -n %{name}-%{version} %build %{__mkdir_p} root/var/log/squid-db-logd perl createlinks %install /bin/rm -rf $RPM_BUILD_ROOT (cd root ; /usr/bin/find . -depth -print | /bin/cpio -dump $RPM_BUILD_ROOT) /bin/rm -f %{name}-%{version}-filelist /sbin/e-smith/genfilelist $RPM_BUILD_ROOT \ --dir /var/squidGuard/blacklists 'attr(0750,squid,squid)' \ --dir /var/log/squid-db-logd 'attr(0770,smelog,smelog)' \ --file /usr/bin/squid-db-logd 'attr(0755,root,root)' \ --file /var/service/squid-db-logd/run 'attr(0755,root,root)' \ --file /var/service/squid-db-logd/log/run 'attr(0755,root,root)' \ --file /var/squidGuard/blacklists/black/domains 'attr(0640,squid,squid) %config(noreplace)' \ --file /var/squidGuard/blacklists/black/urls 'attr(0640,squid,squid) %config(noreplace)' \ --file /var/squidGuard/blacklists/white/domains 'attr(0640,squid,squid) %config(noreplace)' \ --file /var/squidGuard/blacklists/white/urls 'attr(0640,squid,squid) %config(noreplace)' \ --file /etc/cron.daily/squid-db-cleanup 'attr(0755,root,root)' \ --file /var/log/squidGuard/deny.log 'attr(0640,squid,squid) %config(noreplace)' \ --file /var/log/squidGuard/white.log 'attr(0640,squid,squid) %config(noreplace)' \ --file /var/log/squidGuard/squidGuard.log 'attr(0640,squid,squid) %config(noreplace)' \ > %{name}-%{version}-filelist echo "%doc CHANGELOG.git" >> %{name}-%{version}-filelist echo "%doc squid_log.sql" >> %{name}-%{version}-filelist %files -f %{name}-%{version}-filelist %defattr(-,root,root) %clean rm -rf $RPM_BUILD_ROOT %post %preun