]> git.ipfire.org Git - thirdparty/dovecot/core.git/log
thirdparty/dovecot/core.git
4 years agoconfigure.ac: Update to v2.3.14.1 release-2.3.14 2.3.14.1
Timo Sirainen [Mon, 14 Jun 2021 09:44:08 +0000 (12:44 +0300)] 
configure.ac: Update to v2.3.14.1

4 years agoNEWS: Add news for 2.3.14.1
Aki Tuomi [Mon, 24 May 2021 11:03:57 +0000 (14:03 +0300)] 
NEWS: Add news for 2.3.14.1

4 years agolib-dict-extra: dict-fs - Escape unsafe paths
Aki Tuomi [Tue, 8 Jun 2021 06:13:25 +0000 (09:13 +0300)] 
lib-dict-extra: dict-fs - Escape unsafe paths

Change any path components that are `.` or `..` to `...` and `....`.
Prevents path traversal attacks.

4 years agolib-oauth2: Do not escape '.'
Aki Tuomi [Tue, 8 Jun 2021 06:04:21 +0000 (09:04 +0300)] 
lib-oauth2: Do not escape '.'

This is not really needed and just makes things difficult.

4 years agolib-oauth2: Add missing test_begin/test_end to token escape
Aki Tuomi [Mon, 3 May 2021 06:58:29 +0000 (09:58 +0300)] 
lib-oauth2: Add missing test_begin/test_end to token escape

4 years agolib-smtp: smtp-server-connection - Fix STARTTLS command injection vulnerability.
Stephan Bosch [Fri, 21 May 2021 22:16:38 +0000 (00:16 +0200)] 
lib-smtp: smtp-server-connection - Fix STARTTLS command injection vulnerability.

The input handler kept reading more commands even though the input was locked by
the STARTTLS command, thereby causing it to read the command pipelined beyond
STARTTLS. This causes a STARTTLS command injection vulerability.

4 years agolib-imap: imap_bodystructure_write() - Return error on corruption instead of assert...
Timo Sirainen [Thu, 1 Apr 2021 17:39:27 +0000 (20:39 +0300)] 
lib-imap: imap_bodystructure_write() - Return error on corruption instead of assert-crash

This could happen if broken message_parts came from cache and
message_part->data was newly read from the mail input.

4 years agolib-storage: Split off index_mail_parse_bodystructure_full()
Timo Sirainen [Thu, 8 Apr 2021 12:04:42 +0000 (15:04 +0300)] 
lib-storage: Split off index_mail_parse_bodystructure_full()

4 years agolib-imap: fuzz-imap-bodystructure - Change failures to i_panic() instead of i_fatal()
Timo Sirainen [Fri, 9 Apr 2021 11:09:17 +0000 (14:09 +0300)] 
lib-imap: fuzz-imap-bodystructure - Change failures to i_panic() instead of i_fatal()

4 years agoimap: Fix using SETMETADATA NIL to unset value
Timo Sirainen [Mon, 3 May 2021 10:15:17 +0000 (13:15 +0300)] 
imap: Fix using SETMETADATA NIL to unset value

Broken by 923362d27d9b2428e301614673cb0efba3bf928f

4 years agolib-oauth2: test-oauth2-jwt - Fix linkage for openssl
Aki Tuomi [Wed, 14 Apr 2021 16:17:30 +0000 (19:17 +0300)] 
lib-oauth2: test-oauth2-jwt - Fix linkage for openssl

Without whole archive option ssl_iostream_unref isn't
included in linkage, which will prevent libdcrypt from
loading openssl backend.

4 years agolib-oauth2: Ensure azp is escaped too
Aki Tuomi [Thu, 19 Nov 2020 17:55:42 +0000 (19:55 +0200)] 
lib-oauth2: Ensure azp is escaped too

4 years agolib-oauth2: Add test for token escape
Aki Tuomi [Wed, 14 Apr 2021 10:47:16 +0000 (13:47 +0300)] 
lib-oauth2: Add test for token escape

4 years agolib-oauth2: Improve identifier escaping function
Aki Tuomi [Wed, 14 Apr 2021 11:12:16 +0000 (14:12 +0300)] 
lib-oauth2: Improve identifier escaping function

4 years agolib-oauth2: Move identifier escaping to own function
Aki Tuomi [Sat, 10 Apr 2021 14:54:45 +0000 (17:54 +0300)] 
lib-oauth2: Move identifier escaping to own function

4 years agolib-compression: Get error with i_stream_get_error() so it's recursive
Markus Valentin [Mon, 22 Mar 2021 12:04:15 +0000 (13:04 +0100)] 
lib-compression: Get error with i_stream_get_error() so it's recursive

In some cases the iostream.error was NULL so the errno default message
was used. This fixes an regression introduced by 8b6142f9ba9.

4 years agoNEWS: Mention XZ/LZMA removal. 2.3.14
Aki Tuomi [Thu, 4 Mar 2021 07:52:40 +0000 (09:52 +0200)] 
NEWS: Mention XZ/LZMA removal.

4 years agoNEWS: Update news for 2.3.14
Aki Tuomi [Tue, 2 Mar 2021 08:55:53 +0000 (10:55 +0200)] 
NEWS: Update news for 2.3.14

4 years agolib-compression: Remove xz/lzma write support
Josef 'Jeff' Sipek [Fri, 22 Jan 2021 19:00:21 +0000 (14:00 -0500)] 
lib-compression: Remove xz/lzma write support

For now, we keep the read support to allow for a more gradual migration from
lzma/xz.

The code has bugs.  Additionally, there is no benefit in keeping it around.
bzip2 or zstd (at maximum compression level) are likely better choices for
archival.  For non-archival usecases, a light compression algorithm like
zstd (at low to medium compression level) or lz4 are better choices.

4 years agodoc/example: 10-metrics.conf - Add metrics related settings
Aki Tuomi [Tue, 16 Feb 2021 11:39:02 +0000 (13:39 +0200)] 
doc/example: 10-metrics.conf - Add metrics related settings

4 years agodoc/eaxmple: 10-logging.conf - Update syntax example to point to online documentation
Aki Tuomi [Tue, 16 Feb 2021 11:25:40 +0000 (13:25 +0200)] 
doc/eaxmple: 10-logging.conf - Update syntax example to point to online documentation

4 years agolib-mail: message-parser - Always properly finish parsed input
Timo Sirainen [Wed, 24 Feb 2021 15:51:19 +0000 (17:51 +0200)] 
lib-mail: message-parser - Always properly finish parsed input

If the caller hadn't called message_parser_parse_next_block() after
seeing EOF in the istream, the deinit could have crashed with:

Panic: file message-parser.c: line 802 (message_parser_deinit_from_parts): assertion failed: (ctx->nested_parts_count == 0 || i_stream_have_bytes_left(ctx->input))

4 years agostats: openmetrics: Do microsecond to seconds conversion only for duration values
Siavash Tavakoli [Thu, 18 Feb 2021 16:25:50 +0000 (16:25 +0000)] 
stats: openmetrics: Do microsecond to seconds conversion only for duration values

Other metrics should be exported with their values unchanged.

4 years agostats: openmentrics: Change histogram bucket unit to seconds
Martin Michaelis [Tue, 16 Feb 2021 20:06:50 +0000 (21:06 +0100)] 
stats: openmentrics: Change histogram bucket unit to seconds

In ae678116a79fff609cdf4fb1eb7eb3db2975bf1c the unit of durations was changed
from microseconds to seconds, but the `le` field in histograms is still in
microseconds.

4 years agostats: refactor duration field name into a macro
Siavash Tavakoli [Thu, 18 Feb 2021 21:39:09 +0000 (21:39 +0000)] 
stats: refactor duration field name into a macro

4 years agoplugins: fts-solr: Use a private HTTP client.
Stephan Bosch [Fri, 4 Jan 2019 08:57:37 +0000 (09:57 +0100)] 
plugins: fts-solr: Use a private HTTP client.

This is a workaround for problems with the http_client_request_send_payload()
API that occur when several shared HTTP clients use this API at the same time
and payload sending gets interleaved.

4 years agoplugins: fts: tika: Use a private HTTP client.
Stephan Bosch [Fri, 4 Jan 2019 08:55:20 +0000 (09:55 +0100)] 
plugins: fts: tika: Use a private HTTP client.

This is a workaround for problems with the http_client_request_send_payload()
API that occur when several shared HTTP clients use this API at the same time
and payload sending gets interleaved.

4 years agoNEWS: Change 2.3.14 to release candidate 2.3.14.rc1
Aki Tuomi [Wed, 17 Feb 2021 09:16:58 +0000 (11:16 +0200)] 
NEWS: Change 2.3.14 to release candidate

4 years agoconfig: test-config-parser - Change filename to match .gitignore pattern
Aki Tuomi [Fri, 12 Feb 2021 12:45:39 +0000 (14:45 +0200)] 
config: test-config-parser - Change filename to match .gitignore pattern

4 years agoconfig: test-config-parser - Cleanup input file after test
Aki Tuomi [Fri, 12 Feb 2021 12:32:01 +0000 (14:32 +0200)] 
config: test-config-parser - Cleanup input file after test

4 years agoNEWS: Add news for 2.3.14
Aki Tuomi [Wed, 10 Feb 2021 13:20:13 +0000 (15:20 +0200)] 
NEWS: Add news for 2.3.14

4 years agolib-settings: test-settings-parser - Use ULL suffix
Aki Tuomi [Mon, 8 Feb 2021 08:05:47 +0000 (10:05 +0200)] 
lib-settings: test-settings-parser - Use ULL suffix

Some of the sizes do not fit to UL in 32 bit systems.

4 years agolib-mail: test-message-snippet - Add unit tests for multipart messages
Aki Tuomi [Thu, 28 Jan 2021 15:04:37 +0000 (17:04 +0200)] 
lib-mail: test-message-snippet - Add unit tests for multipart messages

4 years agolib-mail: test-message-snippet - Use test_assert_strcmp
Aki Tuomi [Wed, 3 Feb 2021 15:22:07 +0000 (17:22 +0200)] 
lib-mail: test-message-snippet - Use test_assert_strcmp

Makes it easier to see what failed.

4 years agolib-mail: Reformat test-message-snippet.c
Aki Tuomi [Thu, 28 Jan 2021 14:52:10 +0000 (16:52 +0200)] 
lib-mail: Reformat test-message-snippet.c

4 years agolib-mail: message-snippet - Stop building snippet on first non-empty part
Aki Tuomi [Thu, 28 Jan 2021 15:01:38 +0000 (17:01 +0200)] 
lib-mail: message-snippet - Stop building snippet on first non-empty part

When we have gotten some snippet out of first eligible part,
we can stop.

4 years agolib-mail: message-snippet - Do not stop on first non-text part
Aki Tuomi [Thu, 28 Jan 2021 14:48:05 +0000 (16:48 +0200)] 
lib-mail: message-snippet - Do not stop on first non-text part

Some mail structures would break snippet generation because
the code would stop on multipart.

4 years agolib-mail: message-snippet - Free html parser before making new
Aki Tuomi [Thu, 28 Jan 2021 09:07:32 +0000 (11:07 +0200)] 
lib-mail: message-snippet - Free html parser before making new

If html parser has already been initialized, free it before restarting
the parser.

Fixes memory leak introduced by 7f7be2cbf68f8a202a688d5bc50f82483d461643

4 years agoconfigure: Update version to 2.3.14
Aki Tuomi [Thu, 4 Feb 2021 09:25:22 +0000 (11:25 +0200)] 
configure: Update version to 2.3.14

4 years agostats: stats-service-openmetrics - Use PRIdTIME_T for startup time
Aki Tuomi [Thu, 4 Feb 2021 06:59:29 +0000 (08:59 +0200)] 
stats: stats-service-openmetrics - Use PRIdTIME_T for startup time

4 years agologin: login-proxy - Fix type conflict
Aki Tuomi [Thu, 4 Feb 2021 06:57:24 +0000 (08:57 +0200)] 
login: login-proxy - Fix type conflict

4 years agolib-mail: test-message-header-decode - Use ptrdiff_t for rep_char_len
Aki Tuomi [Thu, 4 Feb 2021 06:54:59 +0000 (08:54 +0200)] 
lib-mail: test-message-header-decode - Use ptrdiff_t for rep_char_len

The length is compared to a pointer difference, so using ptrdiff_t
squashes a warning.

4 years agolib-settings: test-setting-parser - Use correct type in test
Aki Tuomi [Thu, 4 Feb 2021 06:46:51 +0000 (08:46 +0200)] 
lib-settings: test-setting-parser - Use correct type in test

SIZE uses uoff_t.

4 years agolib: backtrace - Use correct format modifier
Aki Tuomi [Thu, 4 Feb 2021 06:45:37 +0000 (08:45 +0200)] 
lib: backtrace - Use correct format modifier

Matches size_t correctly.

4 years agolib: test-time-util - Use correct types for test case
Aki Tuomi [Thu, 4 Feb 2021 06:44:46 +0000 (08:44 +0200)] 
lib: test-time-util - Use correct types for test case

Fixes type mismatch on 32-bit systems.

4 years agomaster: Fix reopening log files on SIGUSR1
Timo Sirainen [Tue, 19 Jan 2021 18:11:47 +0000 (19:11 +0100)] 
master: Fix reopening log files on SIGUSR1

4 years agoman: Clarify how doveadm log reopen works
Timo Sirainen [Tue, 19 Jan 2021 18:11:20 +0000 (19:11 +0100)] 
man: Clarify how doveadm log reopen works

4 years agodovecot.service.in: Update documentation URL
Timo Sirainen [Thu, 28 Jan 2021 15:45:45 +0000 (16:45 +0100)] 
dovecot.service.in: Update documentation URL

4 years agolib-master: test-event-stats - Fix unit test when compiling using build directory
Timo Sirainen [Fri, 22 Jan 2021 11:19:05 +0000 (13:19 +0200)] 
lib-master: test-event-stats - Fix unit test when compiling using build directory

When using build directory __FILE__ expands to
"../../../src/lib-master/test-event-stats.c", which doesn't match
"test-event-stats.c" what is normally used.

4 years agolib-master: test-event-stats - Cast test value to uint64_t
Aki Tuomi [Mon, 18 Jan 2021 16:14:47 +0000 (18:14 +0200)] 
lib-master: test-event-stats - Cast test value to uint64_t

4 years agolib: Fix timeval_cmp_margin for 32-bit systems
Paul Howarth [Mon, 4 Jan 2021 16:31:03 +0000 (16:31 +0000)] 
lib: Fix timeval_cmp_margin for 32-bit systems

The test suite compares times with seconds values of -INT_MAX and
INT_MAX. The result of this comparison does not fit in a value of
type int and so the test suite fails on 32-bit systems where time_t
is an int. To fix this, calculations on seconds values are done
using long long integers.

Broken by 16ab5542

4 years agodsync: Use a better default vname escape character
Timo Sirainen [Tue, 26 Jan 2021 15:44:46 +0000 (17:44 +0200)] 
dsync: Use a better default vname escape character

A control character was a bit unreadable in strings.

4 years agodsync: Replace escape characters in outgoing mailbox names with alt_char
Timo Sirainen [Tue, 26 Jan 2021 16:55:22 +0000 (18:55 +0200)] 
dsync: Replace escape characters in outgoing mailbox names with alt_char

Especially when dsync is used for migration, we don't want to end up having
invalid mUTF7 mailbox names locally. Also, remote might not even be
configured to use the same escape character.

4 years agodsync: Send alt_char also to slave brain
Timo Sirainen [Tue, 26 Jan 2021 16:54:53 +0000 (18:54 +0200)] 
dsync: Send alt_char also to slave brain

4 years agolib-storage: mailbox_list_escape_name_params() - Assert that escape_char isn't NUL
Timo Sirainen [Mon, 18 Jan 2021 21:53:50 +0000 (23:53 +0200)] 
lib-storage: mailbox_list_escape_name_params() - Assert that escape_char isn't NUL

4 years agoimapc: Add comment explaining various mailbox names
Timo Sirainen [Fri, 15 Jan 2021 17:27:00 +0000 (19:27 +0200)] 
imapc: Add comment explaining various mailbox names

4 years agoimapc: fs mailbox_list - Remove vname_escape_char
Timo Sirainen [Mon, 18 Jan 2021 21:31:28 +0000 (23:31 +0200)] 
imapc: fs mailbox_list - Remove vname_escape_char

This isn't necessary.

4 years agoimapc: Add IMAPC_LIST_FS_NAME_ESCAPE_CHAR
Timo Sirainen [Mon, 18 Jan 2021 21:30:28 +0000 (23:30 +0200)] 
imapc: Add IMAPC_LIST_FS_NAME_ESCAPE_CHAR

This clarifies how the escape characters are used.

4 years agoimapc: Add a default vname_escape_char
Timo Sirainen [Mon, 18 Jan 2021 21:23:37 +0000 (23:23 +0200)] 
imapc: Add a default vname_escape_char

Having vname_escape_char guarantees that all the remote mailbox names are
accessible by escaping them as necessary.

4 years agoimapc: Fix local filesystem directory name escaping
Timo Sirainen [Mon, 18 Jan 2021 21:19:01 +0000 (23:19 +0200)] 
imapc: Fix local filesystem directory name escaping

Use the remote mailbox name as the base. Convert the hierarchy separator
and add escaping as necessary.

The old method was based on storage_name, and it's a bit unclear if it
worked correctly in all situations.

4 years agoimapc: Add imapc_list_remote_to_storage_name()
Timo Sirainen [Sat, 16 Jan 2021 15:20:46 +0000 (17:20 +0200)] 
imapc: Add imapc_list_remote_to_storage_name()

4 years agoimapc: Fix remote/storage mailbox name mismatches
Timo Sirainen [Sat, 16 Jan 2021 13:03:59 +0000 (15:03 +0200)] 
imapc: Fix remote/storage mailbox name mismatches

4 years agoimapc: Use more explicit mailbox name variable names
Timo Sirainen [Sat, 16 Jan 2021 13:00:06 +0000 (15:00 +0200)] 
imapc: Use more explicit mailbox name variable names

Clearly specify which type of a mailbox name it is to avoid
misunderstandings.

4 years agoimapc: Rename imapc_list_get_fs_name() to imapc_list_storage_to_fs_name()
Timo Sirainen [Sat, 16 Jan 2021 12:44:00 +0000 (14:44 +0200)] 
imapc: Rename imapc_list_get_fs_name() to imapc_list_storage_to_fs_name()

4 years agoimapc: Rename imapc_list_to_vname() to imapc_list_remote_to_vname()
Timo Sirainen [Sat, 16 Jan 2021 12:41:24 +0000 (14:41 +0200)] 
imapc: Rename imapc_list_to_vname() to imapc_list_remote_to_vname()

4 years agoimapc: Rename imapc_list_to_remote() to imapc_list_storage_to_remote_name()
Timo Sirainen [Sat, 16 Jan 2021 12:40:54 +0000 (14:40 +0200)] 
imapc: Rename imapc_list_to_remote() to imapc_list_storage_to_remote_name()

4 years agolib-storage: mailbox_list_default_get_storage_name() - Escape ns_prefix/INBOX if...
Timo Sirainen [Thu, 14 Jan 2021 15:45:07 +0000 (17:45 +0200)] 
lib-storage: mailbox_list_default_get_storage_name() - Escape ns_prefix/INBOX if possible

If storage_name_escape_char is set, escape the "I" letter in the
storage_name if the namespace also has inbox=yes. This way it's possible to
distinguish between the actual INBOX and ns_prefix/INBOX.

4 years agolib-storage: Update mailbox_list_settings.{vname|storage_name}_escape_char comments
Timo Sirainen [Thu, 14 Jan 2021 15:33:13 +0000 (17:33 +0200)] 
lib-storage: Update mailbox_list_settings.{vname|storage_name}_escape_char comments

Also add the examples in the comments to unit tests to make sure they really
work.

4 years agolib-storage: Fix mailbox name escape/unescape ordering
Timo Sirainen [Thu, 14 Jan 2021 15:27:03 +0000 (17:27 +0200)] 
lib-storage: Fix mailbox name escape/unescape ordering

This fixes some cases like not properly escaping '/' in storage_name if it
was also the namespace separator. This also allows using the same character
for both vname_escape_char and storage_name_escape_char.

4 years agolib-storage: mailbox_list_default_get_vname() - Fix escaping namespace separator...
Timo Sirainen [Thu, 14 Jan 2021 15:07:34 +0000 (17:07 +0200)] 
lib-storage: mailbox_list_default_get_vname() - Fix escaping namespace separator in storage_name

For example if { storage_name="foo/bar", storage_sep=".", ns_sep="/" }
the "/" in the name shouldn't be treated as a namespace separator.
If vname_escape_char is set, it should be returned escaped instead.

4 years agolib-storage: Use imap_escaped_utf8_to_utf7()
Timo Sirainen [Thu, 14 Jan 2021 14:38:04 +0000 (16:38 +0200)] 
lib-storage: Use imap_escaped_utf8_to_utf7()

4 years agolib-storage: Use imap_escaped_utf8_hex_to_char()
Timo Sirainen [Thu, 14 Jan 2021 14:32:25 +0000 (16:32 +0200)] 
lib-storage: Use imap_escaped_utf8_hex_to_char()

4 years agolib-storage: Use mailbox_list_settings.vname_escape_char also with utf8 storage names
Timo Sirainen [Thu, 14 Jan 2021 14:23:24 +0000 (16:23 +0200)] 
lib-storage: Use mailbox_list_settings.vname_escape_char also with utf8 storage names

mailbox_list_default_get_storage_name() was already unescaping with utf8,
so mailbox_list_default_get_vname() should also be escaping with utf8.

4 years agolib-storage: mailbox_list_default_get_vname() - Use imap_utf7_to_utf8_escaped()
Timo Sirainen [Thu, 14 Jan 2021 13:40:44 +0000 (15:40 +0200)] 
lib-storage: mailbox_list_default_get_vname() - Use imap_utf7_to_utf8_escaped()

This changes the output a bit for broken mUTF7 names. Previously if any
part of the string had broken mUTF7 input, none of it was converted.
Now it's instead trying to convert as much as it can.

4 years agolib-storage: mailbox_list_default_get_vname() - Escape each hierarchical name separately
Timo Sirainen [Thu, 14 Jan 2021 13:09:34 +0000 (15:09 +0200)] 
lib-storage: mailbox_list_default_get_vname() - Escape each hierarchical name separately

Same reasoning as for the similar change for
mailbox_list_default_get_storage_name().

4 years agolib-storage: Split off mailbox_list_storage_name_prepare()
Timo Sirainen [Thu, 14 Jan 2021 10:47:55 +0000 (12:47 +0200)] 
lib-storage: Split off mailbox_list_storage_name_prepare()

4 years agolib-storage: mailbox_list_default_get_storage_name() - Escape each hierarchical name...
Timo Sirainen [Thu, 14 Jan 2021 10:34:48 +0000 (12:34 +0200)] 
lib-storage: mailbox_list_default_get_storage_name() - Escape each hierarchical name separately

This makes it possible in the following commits to allow unescaping to
write namespace hierarchy separator character without converting it into
the mailbox_list separator.

4 years agolib-storage: mailbox_list_default_get_storage_name() - Cleanup shared namespace root...
Timo Sirainen [Thu, 14 Jan 2021 10:30:54 +0000 (12:30 +0200)] 
lib-storage: mailbox_list_default_get_storage_name() - Cleanup shared namespace root handling

4 years agolib-storage: Split off mailbox_list_vname_prepare()
Timo Sirainen [Thu, 14 Jan 2021 10:03:58 +0000 (12:03 +0200)] 
lib-storage: Split off mailbox_list_vname_prepare()

This also slightly changes the code logic. mailbox_list_escape_name() is
now called also for INBOX, but that doesn't actually matter.

4 years agolib-storage: Remove mailbox_list_unescape_name() by moving its code inline
Timo Sirainen [Thu, 14 Jan 2021 13:22:20 +0000 (15:22 +0200)] 
lib-storage: Remove mailbox_list_unescape_name() by moving its code inline

There was only a single caller for this function. It doesn't need to exist.

4 years agolib-storage: Remove mailbox_list_escape_name() by moving its code inline
Timo Sirainen [Thu, 14 Jan 2021 13:20:13 +0000 (15:20 +0200)] 
lib-storage: Remove mailbox_list_escape_name() by moving its code inline

There was only a single caller for this function. It doesn't need to exist.

4 years agolib-storage: Add unit tests for mailbox_list_default_get_{storage_name|vname}()
Timo Sirainen [Wed, 13 Jan 2021 18:55:43 +0000 (20:55 +0200)] 
lib-storage: Add unit tests for mailbox_list_default_get_{storage_name|vname}()

4 years agolib-storage: Rename mailbox_list_settings.broken_char to vname_escape_char
Timo Sirainen [Wed, 13 Jan 2021 16:50:38 +0000 (18:50 +0200)] 
lib-storage: Rename mailbox_list_settings.broken_char to vname_escape_char

This clarifies that it's only used in vnames.

4 years agolib-storage: Rename mailbox_list_settings.escape_char to storage_name_escape_char
Timo Sirainen [Wed, 13 Jan 2021 16:47:11 +0000 (18:47 +0200)] 
lib-storage: Rename mailbox_list_settings.escape_char to storage_name_escape_char

This clarifies that it's only used in storage_names.

4 years agolib-imap: Add imap_utf7_to_utf8_escaped() and imap_escaped_utf8_to_utf7()
Timo Sirainen [Wed, 13 Jan 2021 17:50:50 +0000 (19:50 +0200)] 
lib-imap: Add imap_utf7_to_utf8_escaped() and imap_escaped_utf8_to_utf7()

These can be used to convert invalid mUTF-7 to escaped UTF-8 and back to the
original invalid input.

4 years agolib-imap: test-imap-utf7 - Simplify test_imap_utf7_non_utf16()
Timo Sirainen [Wed, 13 Jan 2021 17:48:15 +0000 (19:48 +0200)] 
lib-imap: test-imap-utf7 - Simplify test_imap_utf7_non_utf16()

4 years agolib-imap: Move unnecessary shift check to mbase64_decode_to_utf8()
Timo Sirainen [Wed, 13 Jan 2021 17:19:37 +0000 (19:19 +0200)] 
lib-imap: Move unnecessary shift check to mbase64_decode_to_utf8()

4 years agolib-imap: test-imap-utf7 - Improve/clarify testing '&'
Timo Sirainen [Wed, 13 Jan 2021 17:17:18 +0000 (19:17 +0200)] 
lib-imap: test-imap-utf7 - Improve/clarify testing '&'

& is never base64-encoded.

4 years agoconfig: Add unit test for config parser
Aki Tuomi [Mon, 25 Jan 2021 11:32:18 +0000 (13:32 +0200)] 
config: Add unit test for config parser

4 years agoconfig: Extract sources to libconfig.la
Aki Tuomi [Wed, 20 Jan 2021 08:07:56 +0000 (10:07 +0200)] 
config: Extract sources to libconfig.la

Makes unit testing possible

4 years agolib-settings: test-settings - Add tests for settings file
Aki Tuomi [Tue, 19 Jan 2021 09:54:15 +0000 (11:54 +0200)] 
lib-settings: test-settings - Add tests for settings file

4 years agotest-settings-parser: Add test for size
Aki Tuomi [Mon, 18 Jan 2021 13:43:06 +0000 (15:43 +0200)] 
test-settings-parser: Add test for size

4 years agolib-settings: test-settings-parser - Add test for settings parser
Aki Tuomi [Mon, 18 Jan 2021 13:32:51 +0000 (15:32 +0200)] 
lib-settings: test-settings-parser - Add test for settings parser

4 years agolib-settings: Add support for $ENV:name
Aki Tuomi [Mon, 18 Jan 2021 12:11:28 +0000 (14:11 +0200)] 
lib-settings: Add support for $ENV:name

Expands into given environment variable

4 years agoconfig: Add support for $ENV:name
Aki Tuomi [Wed, 22 Jan 2020 12:34:15 +0000 (14:34 +0200)] 
config: Add support for $ENV:name

Expands into given environment variable

4 years agoconfig: Expand multiple variables per line
Aki Tuomi [Wed, 22 Jan 2020 12:33:38 +0000 (14:33 +0200)] 
config: Expand multiple variables per line

Needed to properly support environment variables.

4 years agoconfig: config-parser - Add config_write_keyvariable
Aki Tuomi [Wed, 20 Jan 2021 08:49:23 +0000 (10:49 +0200)] 
config: config-parser - Add config_write_keyvariable

Move code handling key variable expansion to separate function.
Simplifies next commit.

4 years agolib-storage: Make lua methods and functions use the passed in lua_State * directly
Josef 'Jeff' Sipek [Tue, 12 Jan 2021 18:53:19 +0000 (13:53 -0500)] 
lib-storage: Make lua methods and functions use the passed in lua_State * directly

4 years agolib-storage: Make dlua_push_mail() take lua_State * directly
Josef 'Jeff' Sipek [Tue, 12 Jan 2021 19:27:31 +0000 (14:27 -0500)] 
lib-storage: Make dlua_push_mail() take lua_State * directly

4 years agolib-storage: Make dlua_push_mail_user() take lua_State * directly
Josef 'Jeff' Sipek [Tue, 12 Jan 2021 19:26:07 +0000 (14:26 -0500)] 
lib-storage: Make dlua_push_mail_user() take lua_State * directly