]> git.ipfire.org Git - thirdparty/dovecot/core.git/log
thirdparty/dovecot/core.git
18 months ago.clang-tidy: Silence some lints
Fred Morcos [Mon, 6 Jan 2025 13:40:01 +0000 (14:40 +0100)] 
.clang-tidy: Silence some lints

18 months agolib: connection - Make connection_list_deinit(NULL) no-op
Aki Tuomi [Thu, 30 Jan 2025 17:18:40 +0000 (19:18 +0200)] 
lib: connection - Make connection_list_deinit(NULL) no-op

18 months agoconfigure: Default to main if asset version is empty
Aki Tuomi [Tue, 28 Jan 2025 07:36:09 +0000 (09:36 +0200)] 
configure: Default to main if asset version is empty

18 months agolib-auth-client: auth-master - Fix crash if failing to connect to socket
Timo Sirainen [Thu, 16 Jan 2025 13:44:50 +0000 (15:44 +0200)] 
lib-auth-client: auth-master - Fix crash if failing to connect to socket

auth_master_unset_io() would be called twice: once by
auth_master_run_cmd_pre() and again by auth_master_run_cmd_post(), which
attempts to add the idle timeout again.

Fixes:
Panic: file auth-master.c: line 440 (auth_master_unset_io): assertion failed: (conn->to == NULL)

18 months agolib-mail: message_skip_virtual() - Optimize with memchr()
Timo Sirainen [Mon, 13 Jan 2025 14:46:59 +0000 (16:46 +0200)] 
lib-mail: message_skip_virtual() - Optimize with memchr()

18 months agolib-mail: message_skip_virtual() - Fix handling plain CRs in message body
Timo Sirainen [Mon, 13 Jan 2025 13:58:29 +0000 (15:58 +0200)] 
lib-mail: message_skip_virtual() - Fix handling plain CRs in message body

The plain CRs should be handled like any other character, not returning
last_cr_r=TRUE.

This fixes partial IMAP FETCHes where body contains e.g. "\rfoo" and
doing a partial FETCH BODY[TEXT]<1> to skip over the CR.

Fixes errors like:
Deleting corrupted cache record: Broken virtual size in mailbox .. FETCH BODY[]<1> got too little data: 2 vs 3

19 months agodovecot-config: Propagate mail utf-8 presence properly
Aki Tuomi [Wed, 8 Jan 2025 14:12:11 +0000 (16:12 +0200)] 
dovecot-config: Propagate mail utf-8 presence properly

19 months agolib: test-data-stack - Explicitly ignore result from t_malloc_no0() when neeeded
Aki Tuomi [Mon, 30 Dec 2024 05:35:32 +0000 (07:35 +0200)] 
lib: test-data-stack - Explicitly ignore result from t_malloc_no0() when neeeded

Satisfies static analysers

19 months agolib: test-data-stack - Drop bogus assertion
Sam James [Sat, 28 Dec 2024 13:17:24 +0000 (13:17 +0000)] 
lib: test-data-stack - Drop bogus assertion

This assertion goes back to 992a1726a41b42fa47204565ff17f7c635fcb421 when
test-data-stack.c was added.

It starts to fail with (upcoming) GCC 15 which has improvements for
optimising out redundant pointer-vs-pointer comparisons, specifically
r15-580-gf3e5f4c58591f5 for gcc bug PR13962.

Anyway, this is a problem for this assertion because t_malloc_no0
is marked with `__attribute__((malloc))` which guarantees that the
returned pointer doesn't alias, hence a == b must be false.

Bug: https://bugs.gentoo.org/939857

19 months agolib-imap: Fail parsing on impossible imap-dates/times
Timo Sirainen [Sat, 13 May 2023 21:25:20 +0000 (00:25 +0300)] 
lib-imap: Fail parsing on impossible imap-dates/times

For example 32-Jan-2023 was converted into a max-timestamp before instead of
being rejected.

19 months agolib-index: Fix handling indexid change in dovecot.index file
Timo Sirainen [Fri, 13 Dec 2024 10:26:56 +0000 (12:26 +0200)] 
lib-index: Fix handling indexid change in dovecot.index file

Depending on the situation the dovecot.index should be either deleted or
the mailbox reopened.

19 months agolib-index: Split off mail_transaction_log_has_changed()
Timo Sirainen [Fri, 13 Dec 2024 10:26:27 +0000 (12:26 +0200)] 
lib-index: Split off mail_transaction_log_has_changed()

19 months agolib-index: Don't delete dovecot.index.log when finding that indexid changes
Timo Sirainen [Fri, 13 Dec 2024 08:53:16 +0000 (10:53 +0200)] 
lib-index: Don't delete dovecot.index.log when finding that indexid changes

The indexes were recreated, so the new indexes should be used instead of
deleting them.

19 months agolib-storage: Fix duplicate mailbox name detection in list index rebuild
Timo Sirainen [Tue, 17 Dec 2024 08:31:45 +0000 (10:31 +0200)] 
lib-storage: Fix duplicate mailbox name detection in list index rebuild

19 months agolib-storage: Split off mailbox_name_add_random_suffix()
Timo Sirainen [Tue, 17 Dec 2024 08:31:29 +0000 (10:31 +0200)] 
lib-storage: Split off mailbox_name_add_random_suffix()

19 months agolib-index: mail_transaction_log_view_mark() - Fix crash when log view is empty
Timo Sirainen [Sat, 14 Dec 2024 19:20:40 +0000 (21:20 +0200)] 
lib-index: mail_transaction_log_view_mark() - Fix crash when log view is empty

This happened when IMAP NOTIFY was used and syncing was delayed enough for
dovecot.list.index to have become rotated twice and gotten missing
transactions.

19 months agoimap-hibernate: Add local and remote port as variables to mail_log_prefix
Aki Tuomi [Mon, 16 Dec 2024 10:53:23 +0000 (12:53 +0200)] 
imap-hibernate: Add local and remote port as variables to mail_log_prefix

19 months agolib-storage: Add local and remote port as variables to mail_log_prefix
Aki Tuomi [Mon, 16 Dec 2024 10:53:06 +0000 (12:53 +0200)] 
lib-storage: Add local and remote port as variables to mail_log_prefix

19 months agolib-ldap: Rename libldap.la to libdldap.la
Timo Sirainen [Mon, 16 Dec 2024 11:38:10 +0000 (13:38 +0200)] 
lib-ldap: Rename libldap.la to libdldap.la

Using libldap.la caused some strange compiling issues at times.

20 months agolib: Move i_faccessat2() to lib.c
Aki Tuomi [Fri, 29 Dec 2023 13:19:04 +0000 (15:19 +0200)] 
lib: Move i_faccessat2() to lib.c

20 months agoimap: Fix ifdef location
Fred Morcos [Wed, 4 Dec 2024 13:24:41 +0000 (14:24 +0100)] 
imap: Fix ifdef location

20 months agolib,doveadm: Add missing includes
Fred Morcos [Tue, 3 Dec 2024 18:36:30 +0000 (19:36 +0100)] 
lib,doveadm: Add missing includes

20 months agolib: Add NOLINT clang-tidy directives for some helpers
Fred Morcos [Tue, 3 Dec 2024 18:17:00 +0000 (19:17 +0100)] 
lib: Add NOLINT clang-tidy directives for some helpers

20 months agolib-smtp: Remove duplicate function declaration
Aki Tuomi [Fri, 29 Dec 2023 14:09:55 +0000 (16:09 +0200)] 
lib-smtp: Remove duplicate function declaration

20 months agodoveadm: Remove duplicate extern
Aki Tuomi [Fri, 29 Dec 2023 14:09:44 +0000 (16:09 +0200)] 
doveadm: Remove duplicate extern

20 months agolib-fs,lib-storage: Fix posix_fadvise usage
Aki Tuomi [Fri, 29 Dec 2023 14:05:27 +0000 (16:05 +0200)] 
lib-fs,lib-storage: Fix posix_fadvise usage

Return value is non-zero on error, not negative.

20 months agoauth: Remove duplicate extern
Aki Tuomi [Fri, 29 Dec 2023 13:20:48 +0000 (15:20 +0200)] 
auth: Remove duplicate extern

20 months agoauth: auth-cache - Remove duplicate include
Aki Tuomi [Fri, 29 Dec 2023 13:20:27 +0000 (15:20 +0200)] 
auth: auth-cache - Remove duplicate include

20 months agolib: time-util - Fix implicit casts
Aki Tuomi [Fri, 29 Dec 2023 13:20:06 +0000 (15:20 +0200)] 
lib: time-util - Fix implicit casts

20 months agolib-index: Remove duplicate function declaration
Aki Tuomi [Fri, 29 Dec 2023 13:19:52 +0000 (15:19 +0200)] 
lib-index: Remove duplicate function declaration

20 months agoglobal: Add NOLINT for noisy macros
Aki Tuomi [Fri, 29 Dec 2023 10:52:48 +0000 (12:52 +0200)] 
global: Add NOLINT for noisy macros

Remove warnings with clang-tidy

20 months agoglobal: Fix whitespace -> tabs
Fred Morcos [Mon, 2 Dec 2024 07:05:29 +0000 (08:05 +0100)] 
global: Fix whitespace -> tabs

20 months agoglobal: Add clangd config file
Fred Morcos [Thu, 12 Dec 2024 11:13:54 +0000 (12:13 +0100)] 
global: Add clangd config file

20 months agoglobal: Add clang-tidy config file
Aki Tuomi [Tue, 12 Nov 2024 08:27:19 +0000 (10:27 +0200)] 
global: Add clang-tidy config file

20 months agoglobal: Add clang-format config file
Fred Morcos [Mon, 2 Dec 2024 07:04:10 +0000 (08:04 +0100)] 
global: Add clang-format config file

20 months agogitignore: Ignore clangd and emacs directories
Aki Tuomi [Tue, 12 Nov 2024 08:29:09 +0000 (10:29 +0200)] 
gitignore: Ignore clangd and emacs directories

20 months agoglobal: Add dovecot-style editor config
Aki Tuomi [Tue, 12 Nov 2024 08:18:12 +0000 (10:18 +0200)] 
global: Add dovecot-style editor config

20 months agoconfigure: Replace "if" with AS_IF
Timo Sirainen [Wed, 11 Dec 2024 12:37:18 +0000 (14:37 +0200)] 
configure: Replace "if" with AS_IF

20 months agoconfigure: Fix config version checks for x.y versioning (without .z)
Timo Sirainen [Wed, 11 Dec 2024 08:42:27 +0000 (10:42 +0200)] 
configure: Fix config version checks for x.y versioning (without .z)

20 months agolib-smtp: smtp-command-parser - Explicitly disallow 8-bit characters for AUTH response
Stephan Bosch [Tue, 10 Dec 2024 14:45:12 +0000 (15:45 +0100)] 
lib-smtp: smtp-command-parser - Explicitly disallow 8-bit characters for AUTH response

Later Base64 parsing would catch that, but command parser errors become clearer
when this is caught early. Also, this fixes a unit test failure when
experimental SMTPUTF8 support is enabled.

When SMTPUTF8 support is disabled, smtp_char_is_textstr() disallows 8-bit
implicitly, but when SMTPUTF8 is enabled 8-bit octets will be let through.
This caused the invalidity unit test to fail.

20 months agolib-smtp: test-smtp-command-parser - Fail invalidity tests properly in case of valid...
Stephan Bosch [Tue, 10 Dec 2024 14:35:16 +0000 (15:35 +0100)] 
lib-smtp: test-smtp-command-parser - Fail invalidity tests properly in case of valid result

20 months agolib-smtp: test-smtp-command-parser - Properly test bad parameter characters vs. missi...
Stephan Bosch [Tue, 10 Dec 2024 13:59:13 +0000 (14:59 +0100)] 
lib-smtp: test-smtp-command-parser - Properly test bad parameter characters vs. missing EOL

20 months agolib-smtp: test-smtp-address - Vary tests based on SMTPUTF8 support
Aki Tuomi [Thu, 5 Dec 2024 08:04:39 +0000 (10:04 +0200)] 
lib-smtp: test-smtp-address - Vary tests based on SMTPUTF8 support

20 months agolib-sql: cassandra - Add data stack frame
Timo Sirainen [Thu, 5 Dec 2024 08:45:11 +0000 (10:45 +0200)] 
lib-sql: cassandra - Add data stack frame

20 months agolib-fs: Add fs_get_root_fs()
Timo Sirainen [Wed, 4 Dec 2024 11:51:47 +0000 (13:51 +0200)] 
lib-fs: Add fs_get_root_fs()

20 months agodoveadm auth: Fix potential crash when auth is aborted with a signal
Timo Sirainen [Thu, 5 Dec 2024 18:23:28 +0000 (20:23 +0200)] 
doveadm auth: Fix potential crash when auth is aborted with a signal

20 months agodict-ldap: Avoid linking to a dovecot-ldap shared library
Timo Sirainen [Mon, 2 Dec 2024 10:11:48 +0000 (12:11 +0200)] 
dict-ldap: Avoid linking to a dovecot-ldap shared library

The dict-ldap itself is the plugin, which is dynamically loaded.
There's no need for dovecot-ldap shared library to be used. This
changes the lib-ldap linking behavior to same as lib-sql.

20 months agolib-dns: dnc_client_lookup*() - Add data stack frames
Timo Sirainen [Mon, 2 Dec 2024 22:11:41 +0000 (00:11 +0200)] 
lib-dns: dnc_client_lookup*() - Add data stack frames

20 months agodoveadm: Use a separate memory pool for parsing doveadm command line parameters
Timo Sirainen [Mon, 2 Dec 2024 22:10:06 +0000 (00:10 +0200)] 
doveadm: Use a separate memory pool for parsing doveadm command line parameters

This avoids spending a lot of the data stack for the actual command
processing, causing them to grow the data stack.

20 months agodoc: Replace html documentation with redirect to documentation
Aki Tuomi [Fri, 29 Nov 2024 10:41:06 +0000 (12:41 +0200)] 
doc: Replace html documentation with redirect to documentation

20 months agoNEWS: Add news for 2.3.21.1
Aki Tuomi [Thu, 8 Aug 2024 12:13:19 +0000 (15:13 +0300)] 
NEWS: Add news for 2.3.21.1

20 months agolib-http: Add http_client_request_retrieve_headers()
Vincent Kenbeek [Thu, 10 Oct 2024 09:38:56 +0000 (11:38 +0200)] 
lib-http: Add http_client_request_retrieve_headers()

20 months agolib-sql: Link test binaries to libdovecot.la
Aki Tuomi [Thu, 28 Nov 2024 07:33:05 +0000 (09:33 +0200)] 
lib-sql: Link test binaries to libdovecot.la

Otherwise it tries to use installed one, if available.

20 months agoconfigure: Use $SED and $GREP to make sure we get correct tools
Aki Tuomi [Thu, 28 Nov 2024 07:14:48 +0000 (09:14 +0200)] 
configure: Use $SED and $GREP to make sure we get correct tools

20 months agoimap: Don't try to hibernate if it's not enabled
Aki Tuomi [Thu, 28 Nov 2024 07:53:22 +0000 (09:53 +0200)] 
imap: Don't try to hibernate if it's not enabled

20 months agoimap-hibernate: If not enabled, do not include in settings either
Kirill A. Korinsky [Thu, 26 Sep 2024 20:08:47 +0000 (22:08 +0200)] 
imap-hibernate: If not enabled, do not include in settings either

20 months agonet: net_connect_ip*() - Handle OpenBSD errors similarly to FreeBSD
Kirill A. Korinsky [Sun, 13 Oct 2024 09:07:00 +0000 (11:07 +0200)] 
net: net_connect_ip*() - Handle OpenBSD errors similarly to FreeBSD

20 months agoauth: Replace random() with proper i_rand_minmax()
Aki Tuomi [Wed, 27 Nov 2024 07:04:36 +0000 (09:04 +0200)] 
auth: Replace random() with proper i_rand_minmax()

20 months agodsync: Use correct format for time_t in dsync_brain_recv_mailbox_tree_deletes()
Aki Tuomi [Wed, 27 Nov 2024 07:04:22 +0000 (09:04 +0200)] 
dsync: Use correct format for time_t in dsync_brain_recv_mailbox_tree_deletes()

20 months agoconfigure: Split grep into multiple -e expressions
Aki Tuomi [Tue, 26 Nov 2024 20:44:35 +0000 (22:44 +0200)] 
configure: Split grep into multiple -e expressions

This is more portable.

20 months agolib-ssl-iostream,lib-dcrypt: Raise minimum OpenSSL compatibility level to 1.1.1
Aki Tuomi [Tue, 26 Nov 2024 12:32:08 +0000 (14:32 +0200)] 
lib-ssl-iostream,lib-dcrypt: Raise minimum OpenSSL compatibility level to 1.1.1

But retain compatibility with LibreSSL.

20 months agolib: mkdir_parents() - Avoid unnecessary syscalls when uid/gid doesn't change
Timo Sirainen [Tue, 26 Nov 2024 20:35:02 +0000 (22:35 +0200)] 
lib: mkdir_parents() - Avoid unnecessary syscalls when uid/gid doesn't change

There's no need to open() + fchown() the directory after mkdir(), if neither
uid nor gid changes.

20 months agolib-settings: Fix variable type mismatches
Timo Sirainen [Tue, 26 Nov 2024 14:57:01 +0000 (16:57 +0200)] 
lib-settings: Fix variable type mismatches

Just use size_t everywhere since it points to mmap()ed memory.

20 months agoauth: Fix userdb auth cache with username changes
Timo Sirainen [Thu, 21 Nov 2024 10:23:46 +0000 (12:23 +0200)] 
auth: Fix userdb auth cache with username changes

The problem was for example when userdb lookup uses only the username part
of the username@domain lookup. Then:

 * "username" lookup caches the results for "username". Since the username
   didn't change, it doesn't store in the cache the "user" field.
 * "username@domain" lookup looks up "username" from cache. Since there is
   no "user" field, the code didn't think the username had changed.

Fix this by saving the "user" field to auth cache, regardless of whether
it's the same as the current username.

20 months agomdbox: Fix crash if resync fails because of an early failure
Timo Sirainen [Wed, 20 Nov 2024 13:16:00 +0000 (15:16 +0200)] 
mdbox: Fix crash if resync fails because of an early failure

This mainly happened if dovecot.map.index.log was locked and resync timed
out waiting for it.

20 months agolib-lua: test-lua-http-client - Prevent HTTP client context from traversing fork
Stephan Bosch [Tue, 19 Nov 2024 22:21:54 +0000 (23:21 +0100)] 
lib-lua: test-lua-http-client - Prevent HTTP client context from traversing fork

The children will start fighting over the connection FDs and the test will
panic out:

DNS: Panic: epoll_ctl(mod, 8) failed: No such file or directory
CLIENT: Panic: epoll_ctl(mod, 8) failed: No such file or directory

This happens very infrequently.

21 months agoconfigure.ac: Fix generating DOVECOT_CONFIG_VERSION
Timo Sirainen [Mon, 11 Nov 2024 12:45:39 +0000 (14:45 +0200)] 
configure.ac: Fix generating DOVECOT_CONFIG_VERSION

21 months agoconfigure.ac, config: Change supported config versions to work based on PACKAGE_VERSION
Timo Sirainen [Fri, 8 Nov 2024 08:59:10 +0000 (10:59 +0200)] 
configure.ac, config: Change supported config versions to work based on PACKAGE_VERSION

For git this means 0.0.0, but the supported versions still include hardcoded
2.4.0 / 3.0.0, which can be used.

21 months agolib-lua: Fix lua library dependencies when building --without-shared-libs
Timo Sirainen [Wed, 30 Oct 2024 07:59:10 +0000 (09:59 +0200)] 
lib-lua: Fix lua library dependencies when building --without-shared-libs

Linking against libdlua didn't automatically link with liblua, causing
lua plugin loading to fail.

21 months agolib: istream-concat - Fix potential hang when reaching max buffer size
Timo Sirainen [Tue, 29 Oct 2024 09:25:32 +0000 (11:25 +0200)] 
lib: istream-concat - Fix potential hang when reaching max buffer size

21 months agoimap: Fix potential hang when client sends too long line
Timo Sirainen [Tue, 29 Oct 2024 09:22:27 +0000 (11:22 +0200)] 
imap: Fix potential hang when client sends too long line

21 months agoimap: Fix potential hang when client sends too long APPEND line
Timo Sirainen [Tue, 29 Oct 2024 09:20:02 +0000 (11:20 +0200)] 
imap: Fix potential hang when client sends too long APPEND line

21 months agoimap: Fix potential hang/assert-crash when client sends too long line
Timo Sirainen [Tue, 29 Oct 2024 08:36:43 +0000 (10:36 +0200)] 
imap: Fix potential hang/assert-crash when client sends too long line

If client sent some commands pipelined, followed by a command with too long
line, the previous commands' tagged replies weren't sent. This caused it to
hang until more input was received. After that it crashed.

Fixes:
Panic: file imap-client.c: line 1098 (client_check_command_hangs): assertion failed: (!have_wait_unfinished || unfinished_count > 0)

21 months agolib-smtp: Fix UTF-8 local-parts
Arnt Gulbrandsen [Thu, 5 Sep 2024 06:35:13 +0000 (09:35 +0300)] 
lib-smtp: Fix UTF-8 local-parts

21 months agoconfigure: Explicitly check for icu-uc
fundawang [Sun, 27 Oct 2024 14:11:21 +0000 (22:11 +0800)] 
configure: Explicitly check for icu-uc

Ensure we link against libicu-uc when it's split in v76.

21 months agolib-index: Fix potential crash after resetting index
Timo Sirainen [Wed, 23 Oct 2024 07:42:35 +0000 (10:42 +0300)] 
lib-index: Fix potential crash after resetting index

The log's sync_offset wasn't updated after the reset if there were no other
changes. This ended up in a broken state in
mail_transaction_log_append_locked() where it thought there was garbage at
the end of the transaction log, and crashed trying to truncate it.

21 months agoimapc: If a shared namespace INBOX is listed as \Noselect enforce it
Markus Valentin [Wed, 2 Oct 2024 08:18:07 +0000 (10:18 +0200)] 
imapc: If a shared namespace INBOX is listed as \Noselect enforce it

In specific configurations a shared namespace INBOX is listed as
\Noselect
* LIST (\HasChildren) "/" shared/user
* LIST (\HasChildren \Noselect) "/" shared/user/INBOX

This is fixed by adding this extra check.

21 months agodsync: Fix potential crash when handling mailbox renames
Timo Sirainen [Thu, 17 Oct 2024 09:15:08 +0000 (12:15 +0300)] 
dsync: Fix potential crash when handling mailbox renames

Fixes:
Panic: file dsync-mailbox-tree-sync.c: line 575 (node_mailbox_trees_cmp): assertion failed: (ret != 0)

21 months agolib-storage: Mailbox list rebuild - avoid opening mailbox on recovery name collision
Timo Sirainen [Mon, 14 Oct 2024 05:49:37 +0000 (08:49 +0300)] 
lib-storage: Mailbox list rebuild - avoid opening mailbox on recovery name collision

If recovered-lost-folder-$guid already unexpectedly exists, there's no need
to open it (at this point) to try to recover its name. This didn't really harm
anything, so it mainly fixes the code logic to make sense.

21 months agoimap: Fix potential hang/crash when unhibernating
Timo Sirainen [Mon, 14 Oct 2024 09:53:33 +0000 (12:53 +0300)] 
imap: Fix potential hang/crash when unhibernating

This fixes two potential bugs:

a) Unhibernation is triggered by new mailbox changes. While sending these
to IMAP client, Dovecot notices that the client has disconnected. The
process will stay IDLEing for 30 minutes until it gets disconnected with
"Disconnected: Inactivity - no input for 1800 secs"

b) Unhibernation is triggered by DONE command with some further pipelined
commands. During unhibernation new mailbox changes are noticed, and
again IMAP client is found to be disconnected while sending the changes.
This causes a segfault.

22 months agodoveadm: doveadm-print-json - Prevent crash on subsequent user prints
Karl Fleischmann [Thu, 10 Oct 2024 14:41:25 +0000 (16:41 +0200)] 
doveadm: doveadm-print-json - Prevent crash on subsequent user prints

Move closing the final json array delimiter to the deinitialization
routine instead of on flush.

22 months agolib-dcrypt: Ensure bd is not used uninitialized in store_jwk_key()
Aki Tuomi [Wed, 9 Oct 2024 06:22:00 +0000 (09:22 +0300)] 
lib-dcrypt: Ensure bd is not used uninitialized in store_jwk_key()

22 months agoMakefile: Fix LIBDOVECOT_OPENSSL for installed dovecot-config file
Timo Sirainen [Tue, 8 Oct 2024 08:58:22 +0000 (11:58 +0300)] 
Makefile: Fix LIBDOVECOT_OPENSSL for installed dovecot-config file

22 months agolib-http, lib-smtp: unit tests - Make sure expected DNS lookup failures will fail
Timo Sirainen [Fri, 4 Oct 2024 07:39:07 +0000 (10:39 +0300)] 
lib-http, lib-smtp: unit tests - Make sure expected DNS lookup failures will fail

Use ".invalid" suffix just to be safe. More importantly, use a trailing
dot to disable search domains.

22 months agodoc: Remove strict library version requirement from solr-config-9.xml
Aki Tuomi [Tue, 1 Oct 2024 09:33:32 +0000 (12:33 +0300)] 
doc: Remove strict library version requirement from solr-config-9.xml

22 months agodoc: Use solr.install.dir in solr-config-9.xml
Aki Tuomi [Mon, 30 Sep 2024 05:58:53 +0000 (08:58 +0300)] 
doc: Use solr.install.dir in solr-config-9.xml

Removes hardcoded path

22 months agolib: test_hash - Reduce loop counts with valgrind to save time
Timo Sirainen [Tue, 1 Oct 2024 07:58:38 +0000 (10:58 +0300)] 
lib: test_hash - Reduce loop counts with valgrind to save time

22 months agolib: test_hash - Add missing test_begin()/test_end()
Timo Sirainen [Tue, 1 Oct 2024 07:57:32 +0000 (10:57 +0300)] 
lib: test_hash - Add missing test_begin()/test_end()

22 months agolib: istream-multiplex tests - Reduce loop counts with valgrind to save time
Timo Sirainen [Tue, 1 Oct 2024 07:53:33 +0000 (10:53 +0300)] 
lib: istream-multiplex tests - Reduce loop counts with valgrind to save time

22 months agolib: base64 tests - Reduce loop counts with valgrind to save time
Timo Sirainen [Tue, 1 Oct 2024 07:51:00 +0000 (10:51 +0300)] 
lib: base64 tests - Reduce loop counts with valgrind to save time

22 months agolib: test-hash-method - Skip "large input" test with valgrind to save time
Timo Sirainen [Tue, 1 Oct 2024 07:50:41 +0000 (10:50 +0300)] 
lib: test-hash-method - Skip "large input" test with valgrind to save time

22 months agorun-test-valgrind.supp: Add leak suppression for fatal_ostream_file test
Timo Sirainen [Tue, 1 Oct 2024 07:40:24 +0000 (10:40 +0300)] 
run-test-valgrind.supp: Add leak suppression for fatal_ostream_file test

The test is supposed to panic while destroying ostream, so there's no way to
prevent the leak.

22 months agoauth: Fix typo in ssl_ja3_hash field name
Aki Tuomi [Mon, 23 Sep 2024 21:03:40 +0000 (00:03 +0300)] 
auth: Fix typo in ssl_ja3_hash field name

Fixes passing ssl_ja3_hash to a blocking passdb

Broken in 70baf893e85222d071d21cdd5ead546a905d477a

22 months agolib: test-ostream-file - Make sure lack of error handling panics
Timo Sirainen [Mon, 9 Jul 2018 14:29:31 +0000 (17:29 +0300)] 
lib: test-ostream-file - Make sure lack of error handling panics

22 months agolib: o_stream_close() - Don't reset error checking on automatic flush
Timo Sirainen [Mon, 9 Jul 2018 13:23:10 +0000 (16:23 +0300)] 
lib: o_stream_close() - Don't reset error checking on automatic flush

Otherwise it will be difficult to find missing o_stream_flush() calls.
The missing error handling would be found only when the flushing fails,
which would result in assert-crash.

This is how the code was originally intended to behave. Broken by
5ec4fc44e8d4e2160f07b1a7f4fce1ccfec3f6c1

22 months agoimap: Ignore error handling for side channel output
Timo Sirainen [Tue, 24 Sep 2024 06:54:52 +0000 (09:54 +0300)] 
imap: Ignore error handling for side channel output

22 months agolib-index: Ignore ostream errors when cache purging is aborted due to file too large
Timo Sirainen [Tue, 24 Sep 2024 06:56:49 +0000 (09:56 +0300)] 
lib-index: Ignore ostream errors when cache purging is aborted due to file too large

22 months agolib-smtp: test-smtp-client-errors - Add missing ostream finish
Timo Sirainen [Tue, 21 Sep 2021 21:26:26 +0000 (00:26 +0300)] 
lib-smtp: test-smtp-client-errors - Add missing ostream finish

22 months agombox: Fix ostream error handling in mbox_move()
Timo Sirainen [Mon, 9 Jul 2018 14:41:57 +0000 (17:41 +0300)] 
mbox: Fix ostream error handling in mbox_move()

o_stream_nsend_send_istream() needs to be followed by o_stream_flush().
It also detects the istream error.

22 months agovirtual: Fix copying storage error on mail_precache() failure
Timo Sirainen [Mon, 9 Sep 2024 15:46:56 +0000 (18:46 +0300)] 
virtual: Fix copying storage error on mail_precache() failure