LogoopenSUSE Build Service > Projects
Sign Up | Log In

View File proxsmtp.spec of Package proxsmtp (Project home:bastianfriedrich)

Name:           proxsmtp
Group:		Productivity/Networking/Email/Servers
BuildRequires:	libcap-devel, sed, pwdutils
Requires:	pwdutils
Url:            http://thewalter.net/stef/software/proxsmtp/
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
Version:        1.10
Release:        1
Summary:        A flexible and powerful yet simple mail filtering proxy
License:	Other free
Source:		http://thewalter.net/stef/software/proxsmtp/proxsmtp-%{version}.tar.gz
Source1:	proxsmtpd.init
Patch1:		001-fix-strncat.patch
Patch2:		002-remove-unused-retvar.patch
Patch3:		003-various-fixes.patch
Patch4:		004-handle-write-error-during-failure.patch
Patch5:		005-uninitialized-header_len.patch
Patch6:		006-uninitialized-pid.patch
Patch7:		007-pseudo-handling-failing-fwrite.patch

ProxSMTP is a flexible tool that allows you to reject, change or log email
based on arbitrary critera. It accepts SMTP connections and forwards the SMTP
commands and responses to another SMTP server. The 'DATA' email body is
intercepted and filtered before forwarding.

You need to be able to write the filtering scripts that integrate it with
your particular needs.

ProxSMTP was written with the Postfix mail server in mind.

ProxSMTP can also be used as a transparent proxy to filter an entire network's
SMTP traffic at the router.

    Stefan Walter

%patch1 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p1
%patch5 -p1
%patch6 -p1
%patch7 -p1
%if %{defined suse_version}
%if 0%{?suse_version} > 1140
%configure \
	--prefix=%{_prefix} \
	--enable-capabilities \

make %{?jobs:-j%jobs}
%{__sed} -i -e 's/^#User:.*$/User: proxsmtp/' doc/%{name}d.conf

%{__mkdir} -p \
	%{buildroot}%{_initrddir} \
	%{buildroot}%{_sysconfdir}/%{name} \

%{__install} -m 0644 -p doc/%{name}d.conf %{buildroot}%{_sysconfdir}/%{name}/%{name}.conf
%{__install} -m 0755 -p %{SOURCE1} %{buildroot}%{_initrddir}/%{name}d
ln -s ../../%{_initrddir}/%{name}d %{buildroot}/usr/sbin/rc%{name}d

%attr(0755,root,root) %{_sbindir}/*
%attr(0750,proxsmtp,root) /var/lib/proxsmtp

%dir %{_sysconfdir}/%{name}/
%attr(0644,root,root) %config(noreplace) %{_sysconfdir}/%{name}/proxsmtp.conf

%doc AUTHORS ChangeLog COPYING NEWS README scripts/{add_header.sh,spamassassin.sh}

/usr/sbin/groupadd -r proxsmtp 2> /dev/null || :

if id proxsmtp 2>/dev/null; then
	usermod -d /var/lib/proxsmtp proxsmtp
	/usr/sbin/useradd -r -g proxsmtp -s /bin/false -c "ProxSMTP account" -d /var/lib/proxsmtp proxsmtp

chown proxsmtp:root /var/lib/proxsmtp
chmod 0750 /var/lib/proxsmtp

if [ $1 -eq 0 ]; then
	/sbin/insserv -r proxsmtpd
	/etc/init.d/proxsmtpd stop > /dev/null 2>&1 || :

* Mon Oct 24 2011 Bastian Friedrich <bastian@bastian-friedrich.de> 1.10
- Update to newest release 1.10
* Wed Feb 02 2011 Bastian Friedrich <bastian@bastian-friedrich.de> 1.9
- Initial package