From bb32cd54e80fc4317625276601f75d231548fd1e2d98705984e28377dd58a657 Mon Sep 17 00:00:00 2001 From: Peter Wullinger Date: Wed, 7 Sep 2022 06:58:15 +0000 Subject: [PATCH 1/4] Accepting request 1001404 from home:lnussel:branches:server:mail - Own /var/spool/mail (boo#1179574) OBS-URL: https://build.opensuse.org/request/show/1001404 OBS-URL: https://build.opensuse.org/package/show/server:mail/exim?expand=0&rev=263 --- exim.changes | 5 +++++ exim.spec | 3 +++ 2 files changed, 8 insertions(+) diff --git a/exim.changes b/exim.changes index 8594063..1f706f2 100644 --- a/exim.changes +++ b/exim.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Tue Sep 6 09:19:57 UTC 2022 - Ludwig Nussel + +- Own /var/spool/mail (boo#1179574) + ------------------------------------------------------------------- Wed Jun 29 14:20:50 UTC 2022 - Stefan Schubert diff --git a/exim.spec b/exim.spec index 7b0e10a..460b743 100644 --- a/exim.spec +++ b/exim.spec @@ -315,6 +315,7 @@ mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/logrotate.d mkdir -p $RPM_BUILD_ROOT/usr/{bin,sbin,lib} mkdir -p $RPM_BUILD_ROOT/var/log/exim mkdir -p $RPM_BUILD_ROOT/var/spool/mail/ +ln -s spool/mail $RPM_BUILD_ROOT/var mkdir -p $RPM_BUILD_ROOT%{_fillupdir} mkdir -p $RPM_BUILD_ROOT%{_mandir}/man8 mkdir -p $RPM_BUILD_ROOT/usr/bin @@ -504,6 +505,8 @@ exit 0 /usr/lib/sendmail %{_fillupdir}/sysconfig.exim %dir %attr(750,mail,mail) /var/log/exim +%dir %attr(1777,root,root) /var/spool/mail +/var/mail %files -n eximon %defattr(-,root,root) From 390576486d61cfe1f4c0c3eb0f9bbb117041c46cb467e2d40c9778c1136a47a0 Mon Sep 17 00:00:00 2001 From: Peter Wullinger Date: Wed, 7 Sep 2022 06:59:43 +0000 Subject: [PATCH 2/4] Accepting request 1000599 from home:schubi2 - Migration to /usr/etc: Saving user changed configuration files in /etc and restoring them while an RPM update. OBS-URL: https://build.opensuse.org/request/show/1000599 OBS-URL: https://build.opensuse.org/package/show/server:mail/exim?expand=0&rev=264 --- exim.changes | 6 ++++++ exim.spec | 14 ++++++++++++++ 2 files changed, 20 insertions(+) diff --git a/exim.changes b/exim.changes index 1f706f2..7d8cf74 100644 --- a/exim.changes +++ b/exim.changes @@ -3,6 +3,12 @@ Tue Sep 6 09:19:57 UTC 2022 - Ludwig Nussel - Own /var/spool/mail (boo#1179574) +------------------------------------------------------------------- +Thu Sep 1 07:43:11 UTC 2022 - Stefan Schubert + +- Migration to /usr/etc: Saving user changed configuration files + in /etc and restoring them while an RPM update. + ------------------------------------------------------------------- Wed Jun 29 14:20:50 UTC 2022 - Stefan Schubert diff --git a/exim.spec b/exim.spec index 460b743..53aed49 100644 --- a/exim.spec +++ b/exim.spec @@ -414,6 +414,20 @@ end %if 0%{?suse_version} > 1220 %service_add_pre exim.service %endif +%if 0%{?suse_version} > 1500 +# Prepare for migration to /usr/etc; save any old .rpmsave +for i in logrotate.d/exim ; do + test -f %{_sysconfdir}/${i}.rpmsave && mv -v %{_sysconfdir}/${i}.rpmsave %{_sysconfdir}/${i}.rpmsave.old ||: +done +%endif + +%if 0%{?suse_version} > 1500 +%posttrans +# Migration to /usr/etc, restore just created .rpmsave +for i in logrotate.d/exim ; do + test -f %{_sysconfdir}/${i}.rpmsave && mv -v %{_sysconfdir}/${i}.rpmsave %{_sysconfdir}/${i} ||: +done +%endif %post %if 0%{?suse_version} < 1131 From c9e5a39bde987a654a8f4fced1beda4b94aeb36482c7f7e90383e80ffcb35993 Mon Sep 17 00:00:00 2001 From: Peter Wullinger Date: Thu, 29 Sep 2022 14:00:47 +0000 Subject: [PATCH 3/4] Accepting request 1006962 from home:pwcau:branches:server:mail - add (patch-no-exit-on-rewrite-malformed-address.patch) Fix exit on attempt to rewrite a malformed address (Bug 2903) OBS-URL: https://build.opensuse.org/request/show/1006962 OBS-URL: https://build.opensuse.org/package/show/server:mail/exim?expand=0&rev=265 --- exim.changes | 6 ++++ exim.spec | 3 +- ...no-exit-on-rewrite-malformed-address.patch | 29 +++++++++++++++++++ 3 files changed, 37 insertions(+), 1 deletion(-) create mode 100644 patch-no-exit-on-rewrite-malformed-address.patch diff --git a/exim.changes b/exim.changes index 7d8cf74..8f2724a 100644 --- a/exim.changes +++ b/exim.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu Sep 29 13:36:20 UTC 2022 - Peter Wullinger + +- add (patch-no-exit-on-rewrite-malformed-address.patch) + Fix exit on attempt to rewrite a malformed address (Bug 2903) + ------------------------------------------------------------------- Tue Sep 6 09:19:57 UTC 2022 - Ludwig Nussel diff --git a/exim.spec b/exim.spec index 53aed49..e0f9fee 100644 --- a/exim.spec +++ b/exim.spec @@ -75,7 +75,7 @@ Requires(pre): group(mail) Requires(pre): fileutils textutils %endif Version: 4.96 -Release: 0 +Release: 1 %if %{with_mysql} BuildRequires: mysql-devel %endif @@ -105,6 +105,7 @@ Source40: exim.service Source41: exim_db.8.gz Patch0: exim-tail.patch Patch1: gnu_printf.patch +Patch2: patch-no-exit-on-rewrite-malformed-address.patch %package -n eximon Summary: Eximon, an graphical frontend to administer Exim's mail queue diff --git a/patch-no-exit-on-rewrite-malformed-address.patch b/patch-no-exit-on-rewrite-malformed-address.patch new file mode 100644 index 0000000..3aa7b91 --- /dev/null +++ b/patch-no-exit-on-rewrite-malformed-address.patch @@ -0,0 +1,29 @@ +From e7ec503729970a03d4509921342bc81313976126 Mon Sep 17 00:00:00 2001 +From: Jeremy Harris +Date: Tue, 12 Jul 2022 22:14:04 +0100 +Subject: [PATCH] Fix exit on attempt to rewrite a malformed address. Bug 2903 + +diff --git a/src/rewrite.c b/src/src/rewrite.c +index bfd78b5f1..90614e626 100644 +--- a/src/rewrite.c ++++ b/src/rewrite.c +@@ -497,15 +497,14 @@ while (*s) + + if (!recipient) + { +- /* Handle unparesable addresses in the header. Slightly ugly because a ++ /* Log unparesable addresses in the header. Slightly ugly because a + null output from the extract can also result from a header without an +- address, "To: undisclosed recpients:;" being the classic case. */ ++ address, "To: undisclosed recpients:;" being the classic case. Ignore ++ this one and carry on. */ + + if ((rewrite_rules || routed_old) && Ustrcmp(errmess, "empty address") != 0) +- { + log_write(0, LOG_MAIN, "rewrite: %s", errmess); +- exim_exit(EXIT_FAILURE); +- } ++ + loop_reset_point = store_reset(loop_reset_point); + continue; + } From b6ac902ba30dcf28070731317a4960f6d6eaa41f909e2988e9ac3717f20c237c Mon Sep 17 00:00:00 2001 From: Peter Wullinger Date: Thu, 29 Sep 2022 14:05:12 +0000 Subject: [PATCH 4/4] actually apply patch OBS-URL: https://build.opensuse.org/package/show/server:mail/exim?expand=0&rev=266 --- exim.spec | 1 + 1 file changed, 1 insertion(+) diff --git a/exim.spec b/exim.spec index e0f9fee..c3d071f 100644 --- a/exim.spec +++ b/exim.spec @@ -149,6 +149,7 @@ once, if at all. The rest is done by logrotate / cron.) %setup -q -n exim-%{version} %patch0 %patch1 -p1 +%patch2 -p1 # build with fPIE/pie on SUSE 10.0 or newer, or on any other platform %if %{?suse_version:%suse_version}%{?!suse_version:99999} > 930 fPIE="-fPIE"