]> git.ipfire.org Git - thirdparty/dovecot/core.git/log
thirdparty/dovecot/core.git
3 years agoindexer, global: Change protocol names in VERSION line
Timo Sirainen [Tue, 25 Jan 2022 14:53:14 +0000 (15:53 +0100)] 
indexer, global: Change protocol names in VERSION line

Dovecot IPC protocols generally use the -server and -client suffix.

3 years agoindexer: Fix handling indexing requests while the request is being worked on
Timo Sirainen [Tue, 25 Jan 2022 22:11:13 +0000 (23:11 +0100)] 
indexer: Fix handling indexing requests while the request is being worked on

The request was always prepended to the head of the queue, even if it wasn't
asked for.

3 years agofts: fts_indexer_cmd() - Fix wrong handshake
Timo Sirainen [Tue, 25 Jan 2022 17:12:56 +0000 (18:12 +0100)] 
fts: fts_indexer_cmd() - Fix wrong handshake

This was used only by fts-lucene to send OPTIMIZE command.

Broken by b4827bc2f2c99029e8524e0c57228124dd22de52

3 years agolib-storage: If mailbox list index refresh fails due to I/O error, don't try to handl...
Timo Sirainen [Wed, 15 Dec 2021 02:02:57 +0000 (03:02 +0100)] 
lib-storage: If mailbox list index refresh fails due to I/O error, don't try to handle corruption

The list index may not have the latest state, so corruption handling could
be breaking it further.

3 years agolib-storage: Fix caching mailbox list index refresh failure
Timo Sirainen [Wed, 15 Dec 2021 01:58:37 +0000 (02:58 +0100)] 
lib-storage: Fix caching mailbox list index refresh failure

If refresh fails (e.g. lock timeout), the following refresh within the same
ioloop_timeval succeeded. This could have resulted wrongly thinking a
mailbox didn't exist when it actually did.

3 years agolib-storage: Fix error handling if metadata lookup fails from mailbox list index
Timo Sirainen [Tue, 14 Dec 2021 21:47:50 +0000 (22:47 +0100)] 
lib-storage: Fix error handling if metadata lookup fails from mailbox list index

The error was handled as success. Fixes at least:
Panic: file mail-storage.c: line 2207 (mailbox_get_metadata): assertion failed: ((items & MAILBOX_METADATA_GUID) == 0 || !guid_128_is_empty(metadata_r->guid))

3 years agoimap: Remove X-CANCEL command
Karl Fleischmann [Wed, 9 Feb 2022 09:10:11 +0000 (10:10 +0100)] 
imap: Remove X-CANCEL command

This was a Dovecot-specific extension that was never used by any
clients. Having it available might expose bugs, so it's better to just
remove it.

3 years agoimap: Remove X-STATE command
Karl Fleischmann [Wed, 9 Feb 2022 09:04:36 +0000 (10:04 +0100)] 
imap: Remove X-STATE command

This was a Dovecot-specific extension that never even worked. It simply
answered "NO Command is disabled for now."

3 years agoindexer: indexer_client_status_callback() - Fix accessing freed memory
Marco Bettini [Fri, 11 Feb 2022 08:17:58 +0000 (09:17 +0100)] 
indexer: indexer_client_status_callback() - Fix accessing freed memory

Broken by a9683d7b3

3 years agolib-storage: imapc_mailbox_close() - Remove unprocessed untagged_fetch_contexts
Marco Bettini [Thu, 10 Feb 2022 16:37:59 +0000 (17:37 +0100)] 
lib-storage: imapc_mailbox_close() - Remove unprocessed untagged_fetch_contexts

3 years agolib-storage: Remove trainling spaces
Marco Bettini [Thu, 10 Feb 2022 15:26:10 +0000 (16:26 +0100)] 
lib-storage: Remove trainling spaces

3 years agodoveadm deduplicate: Simplify code by using doveadm_mail_iter_deinit_sync()
Timo Sirainen [Thu, 29 Apr 2021 18:09:01 +0000 (21:09 +0300)] 
doveadm deduplicate: Simplify code by using doveadm_mail_iter_deinit_sync()

3 years agodoveadm deduplicate: Optimize by deduplicating in a single transaction
Timo Sirainen [Thu, 29 Apr 2021 18:05:40 +0000 (21:05 +0300)] 
doveadm deduplicate: Optimize by deduplicating in a single transaction

3 years agoimapc: imapc_sync_handle_untagged_fetches() - Commit after adding the untagged fetch...
Markus Valentin [Wed, 2 Feb 2022 15:58:24 +0000 (16:58 +0100)] 
imapc: imapc_sync_handle_untagged_fetches() - Commit after adding the untagged fetch messages

The absence of the commit could have caused issues when
imapc_sync_finish() was not called as it left mbox->delayed_sync_trans
initialized but mbox->delayed_sync_view was NULL.

Broken by 55a8c2d294bb2f764209c7ce455d258b2b7506f5

3 years agodoveadm kick: Run anvil commands in a sub-ioloop
Timo Sirainen [Wed, 9 Feb 2022 08:04:01 +0000 (10:04 +0200)] 
doveadm kick: Run anvil commands in a sub-ioloop

Running in main ioloop can cause unexpected IO to happen, which can lead to
crashes.

3 years agoindexer: Fix memory leak on indexer timeout
Marco Bettini [Mon, 7 Feb 2022 15:04:41 +0000 (16:04 +0100)] 
indexer: Fix memory leak on indexer timeout

3 years agodoveadm: doveadm_who_iter_init() - Fix for handle leak on the fail path
Marco Bettini [Wed, 9 Feb 2022 13:20:47 +0000 (14:20 +0100)] 
doveadm: doveadm_who_iter_init() - Fix for handle leak on the fail path

3 years agoman: Update kick/who/proxy man pages
Timo Sirainen [Wed, 2 Feb 2022 13:31:39 +0000 (15:31 +0200)] 
man: Update kick/who/proxy man pages

3 years agoconfig: Log a warning if service ipc is used in config
Timo Sirainen [Tue, 1 Feb 2022 15:42:02 +0000 (16:42 +0100)] 
config: Log a warning if service ipc is used in config

3 years agolib-master, global: anvil_client_query() - Add type safety to callback's context
Timo Sirainen [Tue, 1 Feb 2022 15:39:57 +0000 (16:39 +0100)] 
lib-master, global: anvil_client_query() - Add type safety to callback's context

3 years agoglobal: Write pid_t as unsigned number where it might end up used with kill()
Timo Sirainen [Fri, 21 Jan 2022 09:27:47 +0000 (10:27 +0100)] 
global: Write pid_t as unsigned number where it might end up used with kill()

pid_t is signed, so usually it's been written to strings as signed long.
The actual pid values should never be negative, so practically it shouldn't
matter if it's written as signed or unsigned. However, due to bugs it's
theoretically possible that some garbage value gets written out.

kill() handles negative PIDs by killing entire process groups. By writing
pid_t as unsigned number we can prevent any (theoretical) issues where
kill() ends up killing entire process groups.

Change only some of the places to unsigned where the value might end up
used for kill(). Usually the signed writing is used only for log messages
where it might be more useful to see the negative numbers clearly
(especially -1 as unknown/unset might be used somewhere).

3 years agoanvil: Add command, user-kick and user-list counts to ps title
Timo Sirainen [Tue, 18 Jan 2022 14:34:25 +0000 (15:34 +0100)] 
anvil: Add command, user-kick and user-list counts to ps title

This may be useful in debugging any potential performance issues with the
anvil process.

3 years agolib-master, global: anvil_client_query() - Add timeout parameter
Timo Sirainen [Mon, 17 Jan 2022 14:29:41 +0000 (15:29 +0100)] 
lib-master, global: anvil_client_query() - Add timeout parameter

The default kick command timeout should be larger than the lookup timeout.

3 years agolib-master: anvil-client - Change timeout to be query-specific
Timo Sirainen [Mon, 17 Jan 2022 14:23:47 +0000 (15:23 +0100)] 
lib-master: anvil-client - Change timeout to be query-specific

3 years agoimap: Add client.unhibernated boolean
Timo Sirainen [Thu, 13 Jan 2022 14:54:18 +0000 (16:54 +0200)] 
imap: Add client.unhibernated boolean

3 years agolib-master, ipc: Remove all code related to ipc process
Timo Sirainen [Sun, 10 Oct 2021 00:23:13 +0000 (03:23 +0300)] 
lib-master, ipc: Remove all code related to ipc process

3 years agologin-common: Optimize kicking proxy connections by username
Timo Sirainen [Tue, 11 Jan 2022 09:40:27 +0000 (11:40 +0200)] 
login-common: Optimize kicking proxy connections by username

Track proxy connections by username in a hash table. Kicking only needs to
do a hash lookup from there to find the user's all sessions. Only detached
proxies are tracked this way. It's likely not worth the trouble to track
non-detached pending proxies in this way, since normally there shouldn't be
many of them.

3 years agologin-common: Remove support for ipc process commands
Timo Sirainen [Sun, 10 Oct 2021 00:24:54 +0000 (03:24 +0300)] 
login-common: Remove support for ipc process commands

These commands are now accessible via anvil / admin-client.

3 years agodirector: Kick users via anvil
Timo Sirainen [Sun, 10 Oct 2021 22:44:02 +0000 (01:44 +0300)] 
director: Kick users via anvil

3 years agodirector: Add user_director_hash field to passdb lookup replies
Timo Sirainen [Tue, 4 Jan 2022 16:03:41 +0000 (18:03 +0200)] 
director: Add user_director_hash field to passdb lookup replies

This can be used as alt-username to kick users by the hash.

3 years agodoveadm: Change "proxy list/kick" to be aliases to "who/kick" commands
Timo Sirainen [Sun, 10 Oct 2021 00:21:10 +0000 (03:21 +0300)] 
doveadm: Change "proxy list/kick" to be aliases to "who/kick" commands

3 years agodoveadm who: Rename "proto" field to "service"
Timo Sirainen [Tue, 18 Jan 2022 12:36:45 +0000 (13:36 +0100)] 
doveadm who: Rename "proto" field to "service"

That's what it now actually contains.

3 years agodoveadm kick: Add -h <dest-host> parameter
Timo Sirainen [Mon, 17 Jan 2022 11:18:00 +0000 (12:18 +0100)] 
doveadm kick: Add -h <dest-host> parameter

3 years agodoveadm who/kick: Handle number parameter as a username rather than IP address
Timo Sirainen [Wed, 12 Jan 2022 15:40:37 +0000 (17:40 +0200)] 
doveadm who/kick: Handle number parameter as a username rather than IP address

3 years agodoveadm kick: Print usage on bad parameters
Timo Sirainen [Wed, 12 Jan 2022 15:37:30 +0000 (17:37 +0200)] 
doveadm kick: Print usage on bad parameters

3 years agodoveadm kick: Change output format to only print number of connections kicked
Timo Sirainen [Thu, 13 Jan 2022 16:52:22 +0000 (18:52 +0200)] 
doveadm kick: Change output format to only print number of connections kicked

Having the list of usernames kicked is a bit excessive and it also hides
how many connections were kicked.

The output also wasn't correct when kicking based on alt-username, because
it only printed the alt-username rather than the real usernames.

3 years agodoveadm kick: Avoid listing all connections for simple kick filters
Timo Sirainen [Tue, 11 Jan 2022 12:25:18 +0000 (14:25 +0200)] 
doveadm kick: Avoid listing all connections for simple kick filters

3 years agodoveadm who/kick: Add support for -f <passdb-field> parameter
Timo Sirainen [Tue, 11 Jan 2022 12:17:46 +0000 (14:17 +0200)] 
doveadm who/kick: Add support for -f <passdb-field> parameter

This is similar to what "doveadm proxy kick" has, i.e. list/kick users
based on their alternative usernames (user_* passdb fields).

3 years agodoveadm kick: Rewrite to use anvil KICK-USER command
Timo Sirainen [Tue, 11 Jan 2022 10:25:18 +0000 (12:25 +0200)] 
doveadm kick: Rewrite to use anvil KICK-USER command

Removed the "force" parameter, because it's no longer necessary.

3 years agoimap-hibernate: Change anvil service from imap to imap-hibernate
Timo Sirainen [Tue, 25 Jan 2022 12:49:15 +0000 (13:49 +0100)] 
imap-hibernate: Change anvil service from imap to imap-hibernate

This is better now that anvil can internally separate the service from
protocol.

3 years agoanvil: Track service and protocol separately
Timo Sirainen [Tue, 18 Jan 2022 12:42:51 +0000 (13:42 +0100)] 
anvil: Track service and protocol separately

This way anvil can track e.g. "imap" and "imap-hibernate" services
separately, but still count them in the same "imap" protocol towards
mail_max_userip_connections.

3 years agoanvil: Add optional conn-guid parameter to KICK-USER command
Timo Sirainen [Tue, 11 Jan 2022 10:11:31 +0000 (12:11 +0200)] 
anvil: Add optional conn-guid parameter to KICK-USER command

3 years agoanvil: Implement KICK-USER and KICK-ALT-USER commands
Timo Sirainen [Wed, 8 Dec 2021 00:35:37 +0000 (02:35 +0200)] 
anvil: Implement KICK-USER and KICK-ALT-USER commands

3 years agoanvil: Change to run the process as root and without chroot
Timo Sirainen [Wed, 8 Dec 2021 00:05:46 +0000 (02:05 +0200)] 
anvil: Change to run the process as root and without chroot

The KICK-USER command needs to be able to connect to other processes' admin
sockets and to send signals to other processes.

3 years agoanvil: Add admin_cmd_send()
Timo Sirainen [Mon, 3 Jan 2022 17:38:54 +0000 (19:38 +0200)] 
anvil: Add admin_cmd_send()

This can use either incoming or outgoing connections for sending the
command.

3 years agoanvil: Add admin-client API with connection pooling
Timo Sirainen [Mon, 27 Dec 2021 15:03:37 +0000 (17:03 +0200)] 
anvil: Add admin-client API with connection pooling

3 years agoanvil: Add support for sending commands to anvil client connections
Timo Sirainen [Mon, 3 Jan 2022 16:43:04 +0000 (18:43 +0200)] 
anvil: Add support for sending commands to anvil client connections

3 years agoanvil: Add anvil_connection_find()
Timo Sirainen [Mon, 27 Dec 2021 15:42:27 +0000 (17:42 +0200)] 
anvil: Add anvil_connection_find()

3 years agologin-common: Implement KICK-USER incoming anvil command
Timo Sirainen [Wed, 5 Jan 2022 22:17:42 +0000 (00:17 +0200)] 
login-common: Implement KICK-USER incoming anvil command

3 years agolib-master: anvil-client - Add support for handling incoming commands
Timo Sirainen [Tue, 4 Jan 2022 16:28:22 +0000 (18:28 +0200)] 
lib-master: anvil-client - Add support for handling incoming commands

3 years agolib-master, login-common: anvil_client_init() - Change callback to struct of callbacks
Timo Sirainen [Thu, 13 Jan 2022 15:17:28 +0000 (17:17 +0200)] 
lib-master, login-common: anvil_client_init() - Change callback to struct of callbacks

3 years agoanvil: Change VERSION line to be bidirectional and add -client/server suffix
Timo Sirainen [Wed, 5 Jan 2022 21:36:45 +0000 (23:36 +0200)] 
anvil: Change VERSION line to be bidirectional and add -client/server suffix

This makes it more similar to other internal protocols, and allows using
connection API more easily.

3 years agolib-master: anvil-client - Convert to connection API
Timo Sirainen [Wed, 5 Jan 2022 22:00:21 +0000 (00:00 +0200)] 
lib-master: anvil-client - Convert to connection API

3 years agolib-master: anvil-client - Delay ostream error handling
Timo Sirainen [Wed, 5 Jan 2022 21:58:52 +0000 (23:58 +0200)] 
lib-master: anvil-client - Delay ostream error handling

There's no need to handle write errors immediately. It just makes the code
more complex.

3 years agolib-master: anvil-client - Use struct connection
Timo Sirainen [Wed, 5 Jan 2022 21:12:56 +0000 (23:12 +0200)] 
lib-master: anvil-client - Use struct connection

3 years agoanvil: Add handshake with service name and PID for non-FIFO connections
Timo Sirainen [Wed, 22 Dec 2021 21:20:57 +0000 (23:20 +0200)] 
anvil: Add handshake with service name and PID for non-FIFO connections

This is in preparation for assuming that incoming anvil connections can also
be used to send admin commands for processes. Instead of connecting to the
process's admin UNIX socket, anvil can instead use the existing connection.
The PID is used to identify which admin connections are available.
When the handshake is used, multiplex iostream is enabled.

3 years agoanvil: Convert to using connection API
Timo Sirainen [Wed, 22 Dec 2021 21:09:25 +0000 (23:09 +0200)] 
anvil: Convert to using connection API

Anvil connections can optionally be FIFOs. This causes some difficulties
with the connection API, so everything couldn't be fully converted.

3 years agoanvil: Use struct connection for the anvil client
Timo Sirainen [Wed, 22 Dec 2021 10:40:58 +0000 (12:40 +0200)] 
anvil: Use struct connection for the anvil client

3 years agoanvil, doveadm: Add alt usernames to CONNECT-DUMP output
Timo Sirainen [Thu, 16 Dec 2021 02:50:09 +0000 (04:50 +0200)] 
anvil, doveadm: Add alt usernames to CONNECT-DUMP output

3 years agodoveadm who: Improve error handling
Timo Sirainen [Tue, 1 Feb 2022 15:22:47 +0000 (16:22 +0100)] 
doveadm who: Improve error handling

Avoid i_fatal(), but still fail with non-zero exit code.

3 years agodoveadm: Replace who_lookup() with iterator API
Timo Sirainen [Thu, 16 Dec 2021 02:48:40 +0000 (04:48 +0200)] 
doveadm: Replace who_lookup() with iterator API

3 years agologin-common: Send proxy session destination IP to anvil
Timo Sirainen [Mon, 17 Jan 2022 11:08:29 +0000 (12:08 +0100)] 
login-common: Send proxy session destination IP to anvil

3 years agolib-master: master_service_anvil_connect() - Add support for proxy session destination IP
Timo Sirainen [Mon, 17 Jan 2022 11:06:50 +0000 (12:06 +0100)] 
lib-master: master_service_anvil_connect() - Add support for proxy session destination IP

3 years agoanvil: Don't track proxy connections in userip_hash
Timo Sirainen [Tue, 18 Jan 2022 14:10:00 +0000 (15:10 +0100)] 
anvil: Don't track proxy connections in userip_hash

Otherwise proxy connections would also be counted towards tracking
mail_max_userip_connections, which could cause the same session to be
counted multiple times.

3 years agoanvil, doveadm: Add support for tracking proxy session destination IP
Timo Sirainen [Mon, 17 Jan 2022 10:59:30 +0000 (11:59 +0100)] 
anvil, doveadm: Add support for tracking proxy session destination IP

3 years agologin-common: Send alt usernames to anvil
Timo Sirainen [Wed, 12 Jan 2022 15:34:51 +0000 (17:34 +0200)] 
login-common: Send alt usernames to anvil

3 years agolib-master: master_service_anvil_connect() - Add support for alt usernames
Timo Sirainen [Wed, 12 Jan 2022 15:25:23 +0000 (17:25 +0200)] 
lib-master: master_service_anvil_connect() - Add support for alt usernames

3 years agoanvil: Add support for tracking alternative usernames
Timo Sirainen [Wed, 15 Dec 2021 23:58:35 +0000 (01:58 +0200)] 
anvil: Add support for tracking alternative usernames

3 years agolib-master, global: Send kick-type for anvil CONNECT
Timo Sirainen [Wed, 15 Dec 2021 11:41:32 +0000 (13:41 +0200)] 
lib-master, global: Send kick-type for anvil CONNECT

3 years agoanvil: Add test-connect-limit
Timo Sirainen [Wed, 15 Dec 2021 23:51:24 +0000 (01:51 +0200)] 
anvil: Add test-connect-limit

3 years agoanvil: Add kick-type parameter for CONNECT
Timo Sirainen [Mon, 17 Jan 2022 22:25:09 +0000 (23:25 +0100)] 
anvil: Add kick-type parameter for CONNECT

This indicates how the process supports kicking users.

3 years agoanvil: Split off session_[un]link_process()
Timo Sirainen [Thu, 13 Jan 2022 14:42:31 +0000 (16:42 +0200)] 
anvil: Split off session_[un]link_process()

3 years agolib-master, anvil: [DIS]CONNECT - Move conn-guid to being the first parameter
Timo Sirainen [Mon, 17 Jan 2022 22:31:40 +0000 (23:31 +0100)] 
lib-master, anvil: [DIS]CONNECT - Move conn-guid to being the first parameter

It uniquely identifies the connection, so it's clearer that it's the first
parameter.

3 years agoanvil, doveadm: Require conn-guid to be set for CONNECT
Timo Sirainen [Wed, 15 Dec 2021 22:46:58 +0000 (00:46 +0200)] 
anvil, doveadm: Require conn-guid to be set for CONNECT

This removes the need for refcount tracking.

3 years agoanvil: connect-limit - Add API for iterating user's all connections
Timo Sirainen [Mon, 7 Feb 2022 10:41:02 +0000 (11:41 +0100)] 
anvil: connect-limit - Add API for iterating user's all connections

3 years agoanvil: connect-limit - Keep track of all sessions per user
Timo Sirainen [Wed, 15 Dec 2021 13:39:23 +0000 (15:39 +0200)] 
anvil: connect-limit - Keep track of all sessions per user

3 years agoanvil: connect-limit - Keep track of all sessions per process
Timo Sirainen [Wed, 8 Dec 2021 00:25:39 +0000 (02:25 +0200)] 
anvil: connect-limit - Keep track of all sessions per process

3 years agosubmission: Change kick log message to "Server shutting down"
Timo Sirainen [Wed, 19 Jan 2022 23:09:58 +0000 (00:09 +0100)] 
submission: Change kick log message to "Server shutting down"

This way it's the same as with imap and pop3.

3 years agosubmission: Add admin-client with KICK-USER command
Timo Sirainen [Thu, 13 Jan 2022 16:09:51 +0000 (18:09 +0200)] 
submission: Add admin-client with KICK-USER command

3 years agopop3: Add admin-client with KICK-USER command
Timo Sirainen [Thu, 13 Jan 2022 16:07:02 +0000 (18:07 +0200)] 
pop3: Add admin-client with KICK-USER command

3 years agoimap: Add admin-client with KICK-USER command
Timo Sirainen [Thu, 13 Jan 2022 16:03:00 +0000 (18:03 +0200)] 
imap: Add admin-client with KICK-USER command

3 years agologin-common: Add admin-client with KICK-USER command
Timo Sirainen [Sat, 9 Oct 2021 21:03:20 +0000 (00:03 +0300)] 
login-common: Add admin-client with KICK-USER command

3 years agologin-common: Add login_proxy_kick_user_connection()
Timo Sirainen [Thu, 6 Jan 2022 11:34:09 +0000 (13:34 +0200)] 
login-common: Add login_proxy_kick_user_connection()

3 years agologin-common: Split off more generic login_proxy_kick_user/alt/host()
Timo Sirainen [Sat, 9 Oct 2021 21:22:03 +0000 (00:22 +0300)] 
login-common: Split off more generic login_proxy_kick_user/alt/host()

Move the IPC-specific command input/output handling to the caller, so
these functions just do the main work of kicking.

3 years agologin-common: Track proxied connections in anvil
Timo Sirainen [Wed, 8 Dec 2021 00:03:45 +0000 (02:03 +0200)] 
login-common: Track proxied connections in anvil

3 years agoglobal: Send connection GUIDs to anvil
Timo Sirainen [Sun, 12 Dec 2021 23:26:21 +0000 (01:26 +0200)] 
global: Send connection GUIDs to anvil

3 years agoanvil, doveadm: Add support for connection GUIDs
Timo Sirainen [Sun, 12 Dec 2021 23:22:31 +0000 (01:22 +0200)] 
anvil, doveadm: Add support for connection GUIDs

These are anvil-specific GUIDs that can be used to refer to a specific
connection.

3 years agoanvil, doveadm: Simplify CONNECT-DUMP output format
Timo Sirainen [Sun, 12 Dec 2021 23:17:13 +0000 (01:17 +0200)] 
anvil, doveadm: Simplify CONNECT-DUMP output format

3 years agoanvil, global: Split CONNECT/DISCONNECT/LOOKUP ident to separate parameters
Timo Sirainen [Sun, 12 Dec 2021 22:58:24 +0000 (00:58 +0200)] 
anvil, global: Split CONNECT/DISCONNECT/LOOKUP ident to separate parameters

3 years agoglobal: Increase anvil protocol major version number
Timo Sirainen [Sun, 12 Dec 2021 23:11:56 +0000 (01:11 +0200)] 
global: Increase anvil protocol major version number

The following changes break the backwards compatibility.

3 years agolib-master, global: Replace master_service_anvil_send() with explicit connect/disconn...
Timo Sirainen [Sun, 12 Dec 2021 22:56:12 +0000 (00:56 +0200)] 
lib-master, global: Replace master_service_anvil_send() with explicit connect/disconnect()

3 years agoglobal: Assume anvil command was success only if master_service_anvil_send() returns...
Timo Sirainen [Sun, 12 Dec 2021 22:52:49 +0000 (00:52 +0200)] 
global: Assume anvil command was success only if master_service_anvil_send() returns TRUE

3 years agolib-master: master_service_anvil_send() - Return TRUE if command was actually sent
Timo Sirainen [Sun, 12 Dec 2021 22:52:34 +0000 (00:52 +0200)] 
lib-master: master_service_anvil_send() - Return TRUE if command was actually sent

3 years agoanvil: Store service strings in a reference counted table
Timo Sirainen [Wed, 15 Dec 2021 13:15:34 +0000 (15:15 +0200)] 
anvil: Store service strings in a reference counted table

There are only a few different services, so there's no need to duplicate the
memory usage for each of the string instances.

3 years agoanvil: Initialize session_lookup struct directly
Timo Sirainen [Wed, 15 Dec 2021 12:57:31 +0000 (14:57 +0200)] 
anvil: Initialize session_lookup struct directly

3 years agoanvil: Rename "i" variables to "session"
Timo Sirainen [Wed, 15 Dec 2021 12:55:40 +0000 (14:55 +0200)] 
anvil: Rename "i" variables to "session"

3 years agoanvil: Rename struct ident_pid to struct session
Timo Sirainen [Wed, 15 Dec 2021 12:54:18 +0000 (14:54 +0200)] 
anvil: Rename struct ident_pid to struct session

3 years agoanvil: Change connect-limit API to use struct rather than ident string
Timo Sirainen [Sun, 12 Dec 2021 17:36:37 +0000 (19:36 +0200)] 
anvil: Change connect-limit API to use struct rather than ident string

3 years agoanvil: Split off main_init() and main_deinit()
Timo Sirainen [Mon, 3 Jan 2022 17:27:51 +0000 (19:27 +0200)] 
anvil: Split off main_init() and main_deinit()

3 years agoimap: Avoid sending untagged BYE in the middle of command output
Timo Sirainen [Thu, 13 Jan 2022 16:03:32 +0000 (18:03 +0200)] 
imap: Avoid sending untagged BYE in the middle of command output

This could have caused the untagged BYE to be sent in the middle of e.g.
FETCH command output if the session was kicked out.