Compare commits

..

1 Commits

Author SHA1 Message Date
Michal Hlavinka
d00ee3c952 fix leaking mailboxes if virtual mailbox can't be opened (#2231408) 2023-08-16 01:22:12 +00:00
3 changed files with 1 additions and 39 deletions

View File

@ -1,17 +0,0 @@
diff --git a/src/lib-index/mail-index-sync.c b/src/lib-index/mail-index-sync.c
index 6322ee1869..c847f1cc01 100644
--- a/src/lib-index/mail-index-sync.c
+++ b/src/lib-index/mail-index-sync.c
@@ -544,6 +544,12 @@ static bool mail_index_sync_view_have_any(struct mail_index_view *view,
return TRUE;
mail_transaction_log_get_head(view->index->log, &log_seq, &log_offset);
+ if (log_seq < view->map->hdr.log_file_seq ||
+ ((log_seq == view->map->hdr.log_file_seq &&
+ log_offset < view->map->hdr.log_file_tail_offset))) {
+ /* invalid offsets - let the syncing handle the error */
+ return TRUE;
+ }
if (mail_transaction_log_view_set(view->log_view,
view->map->hdr.log_file_seq,
view->map->hdr.log_file_tail_offset,

View File

@ -6,7 +6,7 @@ Name: dovecot
Epoch: 1 Epoch: 1
Version: 2.3.16 Version: 2.3.16
%global prever %{nil} %global prever %{nil}
Release: 11%{?dist} Release: 10%{?dist}
#dovecot itself is MIT, a few sources are PD, pigeonhole is LGPLv2 #dovecot itself is MIT, a few sources are PD, pigeonhole is LGPLv2
License: MIT and LGPLv2 License: MIT and LGPLv2
@ -55,9 +55,6 @@ Patch21: dovecot-2.3.19.1-7bad6a24.patch
Patch22: dovecot-2.3.18-bdf447e4.patch Patch22: dovecot-2.3.18-bdf447e4.patch
Patch23: dovecot-2.3.18-9f300239..4596d399.patch Patch23: dovecot-2.3.18-9f300239..4596d399.patch
# from upstream, for < 2.3.21, RHEL-25434
Patch24: dovecot-2.3.16-d7705bc6.patch
BuildRequires: gcc, gcc-c++, openssl-devel, pam-devel, zlib-devel, bzip2-devel, libcap-devel BuildRequires: gcc, gcc-c++, openssl-devel, pam-devel, zlib-devel, bzip2-devel, libcap-devel
BuildRequires: libtool, autoconf, automake, pkgconfig BuildRequires: libtool, autoconf, automake, pkgconfig
BuildRequires: sqlite-devel BuildRequires: sqlite-devel
@ -155,7 +152,6 @@ This package provides the development files for dovecot.
%patch -P 20 -p1 -b .ftbfsbigend %patch -P 20 -p1 -b .ftbfsbigend
%patch -P 21 -p1 -b .7bad6a24 %patch -P 21 -p1 -b .7bad6a24
%patch -P 22 -p1 -b .bdf447e4 %patch -P 22 -p1 -b .bdf447e4
%patch -P 24 -p1 -b .d7705bc6
cp run-test-valgrind.supp dovecot-2.3-pigeonhole-%{pigeonholever}/ cp run-test-valgrind.supp dovecot-2.3-pigeonhole-%{pigeonholever}/
# valgrind would fail with shell wrapper # valgrind would fail with shell wrapper
echo "testsuite" >dovecot-2.3-pigeonhole-%{pigeonholever}/run-test-valgrind.exclude echo "testsuite" >dovecot-2.3-pigeonhole-%{pigeonholever}/run-test-valgrind.exclude
@ -494,9 +490,6 @@ make check
%{_libdir}/%{name}/dict/libdriver_pgsql.so %{_libdir}/%{name}/dict/libdriver_pgsql.so
%changelog %changelog
* Fri Feb 16 2024 Michal Hlavinka <mhlavink@redhat.com> - 1:2.3.16-11
- fixes assert-crash when IMAP client uses QRESYNC (#RHEL-25434)
* Tue Aug 15 2023 Michal Hlavinka <mhlavink@redhat.com> - 1:2.3.16-10 * Tue Aug 15 2023 Michal Hlavinka <mhlavink@redhat.com> - 1:2.3.16-10
- fix leaking mailboxes if virtual mailbox can't be opened (#2231408) - fix leaking mailboxes if virtual mailbox can't be opened (#2231408)

View File

@ -1,14 +0,0 @@
---
runpath:
allowed_paths:
# dovecot only plugins
- /usr/lib/dovecot/old-stats
- /usr/lib64/dovecot/old-stats
badfuncs:
ignore:
# used: inet_aton in explicitely ipv4 code path
# gethostbyname as a debug mesage with fallback
# removed from next major version already
- /usr/lib/dovecot/libdovecot.so.0.0.0
- /usr/lib64/dovecot/libdovecot.so.0.0.0