]> git.ipfire.org Git - thirdparty/dovecot/core.git/log
thirdparty/dovecot/core.git
13 years agolib-imap-urlauth: Minor fix to avoiding timing attacks against mailbox existence.
Timo Sirainen [Thu, 18 Oct 2012 03:58:01 +0000 (06:58 +0300)] 
lib-imap-urlauth: Minor fix to avoiding timing attacks against mailbox existence.
random_fill() is slightly slower than random_fill_weak(). Probably even
better way to handle timing attacks would be to always add a short random
pause before returning verification failure.

13 years agoMoved random_init() from lib-imap-urlauth to imap/imap-urlauth main().
Timo Sirainen [Thu, 18 Oct 2012 03:55:04 +0000 (06:55 +0300)] 
Moved random_init() from lib-imap-urlauth to imap/imap-urlauth main().
This way if the processes are chrooted they are still able to open
/dev/urandom.

13 years agolib-index: Crashfix for MAIL_INDEX_OPEN_FLAG_SAVEONLY change.
Timo Sirainen [Thu, 18 Oct 2012 03:45:39 +0000 (06:45 +0300)] 
lib-index: Crashfix for MAIL_INDEX_OPEN_FLAG_SAVEONLY change.

13 years agologin_log_format_elements: Added %{real_rip} variable.
Timo Sirainen [Thu, 18 Oct 2012 03:21:25 +0000 (06:21 +0300)] 
login_log_format_elements: Added %{real_rip} variable.
It differs from %r when Dovecot proxy sends an updated client IP address.
Patch by Jack Bates.

13 years agolib-index: Fixed handling of finding a duplicate dovecot.index.log file_seq
Timo Sirainen [Thu, 18 Oct 2012 03:00:18 +0000 (06:00 +0300)] 
lib-index: Fixed handling of finding a duplicate dovecot.index.log file_seq
Previously we assumed that the already opened file was always the wrong one,
but more common was that the newly opened file was .log.2 which should have
been deleted.

13 years agolib-index: Handle better race condition there dovecot.index.log and .log.2 are the...
Timo Sirainen [Thu, 18 Oct 2012 02:55:30 +0000 (05:55 +0300)] 
lib-index: Handle better race condition there dovecot.index.log and .log.2 are the same link.

13 years agolib-storage: Open index with MAIL_INDEX_OPEN_FLAG_SAVEONLY if mailbox has MAILBOX_FLA...
Timo Sirainen [Thu, 18 Oct 2012 02:23:27 +0000 (05:23 +0300)] 
lib-storage: Open index with MAIL_INDEX_OPEN_FLAG_SAVEONLY if mailbox has MAILBOX_FLAG_SAVEONLY

13 years agolib-index: Added MAIL_INDEX_OPEN_FLAG_SAVEONLY to do only minimal reads from cache...
Timo Sirainen [Thu, 18 Oct 2012 02:22:36 +0000 (05:22 +0300)] 
lib-index: Added MAIL_INDEX_OPEN_FLAG_SAVEONLY to do only minimal reads from cache file.

13 years agolib-index: Code cleanup: Removed mail_cache.data
Timo Sirainen [Thu, 18 Oct 2012 02:16:54 +0000 (05:16 +0300)] 
lib-index: Code cleanup: Removed mail_cache.data

13 years agolib-index: mail_cache_map() API cleanup
Timo Sirainen [Thu, 18 Oct 2012 02:10:29 +0000 (05:10 +0300)] 
lib-index: mail_cache_map() API cleanup

13 years agodict quota: Fixed a potential crash if quota recalculation was triggered at deinit.
Timo Sirainen [Tue, 16 Oct 2012 00:34:51 +0000 (03:34 +0300)] 
dict quota: Fixed a potential crash if quota recalculation was triggered at deinit.

13 years agolib-master: Fixed -i <instance name> parameter handling.
Timo Sirainen [Tue, 16 Oct 2012 00:08:21 +0000 (03:08 +0300)] 
lib-master: Fixed -i <instance name> parameter handling.
It previously worked only if the default config socket wasn't usable.

13 years agolib-storage: Added missing file from previous mailbox attribute commit.
Timo Sirainen [Sat, 13 Oct 2012 01:30:17 +0000 (04:30 +0300)] 
lib-storage: Added missing file from previous mailbox attribute commit.

13 years agoimap-urlauth: Store urlauth keys to the new mailbox attributes.
Timo Sirainen [Sat, 13 Oct 2012 01:28:09 +0000 (04:28 +0300)] 
imap-urlauth: Store urlauth keys to the new mailbox attributes.

13 years agolib-storage: Added support to get/set/iterate mailbox attributes.
Timo Sirainen [Sat, 13 Oct 2012 01:27:14 +0000 (04:27 +0300)] 
lib-storage: Added support to get/set/iterate mailbox attributes.
The attributes are stored in a dict specified by mail_attribute_dict
setting. The idea is to use this as storage for extensions that require
per-mailbox key=value pairs, such as METADATA.

13 years agodict: If DICT_ITERATE_FLAG_NO_VALUE is set, don't send values to dict client.
Timo Sirainen [Sat, 13 Oct 2012 01:18:26 +0000 (04:18 +0300)] 
dict: If DICT_ITERATE_FLAG_NO_VALUE is set, don't send values to dict client.

13 years agolib-dict: Added DICT_ITERATE_FLAG_NO_VALUE
Timo Sirainen [Sat, 13 Oct 2012 01:17:45 +0000 (04:17 +0300)] 
lib-dict: Added DICT_ITERATE_FLAG_NO_VALUE
This allows iterating dictionary without wasting extra time on returning
values that aren't needed.

13 years agoimap-urlauth: Use mailbox GUID instead of mailbox name for dict keys
Timo Sirainen [Fri, 12 Oct 2012 22:57:24 +0000 (01:57 +0300)] 
imap-urlauth: Use mailbox GUID instead of mailbox name for dict keys

13 years agoexample-config: Added imap_urlauth_* settings
Timo Sirainen [Fri, 12 Oct 2012 22:38:48 +0000 (01:38 +0300)] 
example-config: Added imap_urlauth_* settings

13 years agoimap urlauth: Don't autofill imap_urlauth_host. Use "*" value to mean "any host".
Timo Sirainen [Fri, 12 Oct 2012 22:36:13 +0000 (01:36 +0300)] 
imap urlauth: Don't autofill imap_urlauth_host. Use "*" value to mean "any host".

13 years agolib-dict: dict_init() now returns error string instead of logging it
Timo Sirainen [Fri, 12 Oct 2012 22:09:37 +0000 (01:09 +0300)] 
lib-dict: dict_init() now returns error string instead of logging it

13 years agolib-settings: settings_read*() now returns an error string instead of logging itself
Timo Sirainen [Fri, 12 Oct 2012 22:03:13 +0000 (01:03 +0300)] 
lib-settings: settings_read*() now returns an error string instead of logging itself

13 years agoMoved doveadm zlib commands from zlib plugin to doveadm directly.
Timo Sirainen [Fri, 12 Oct 2012 21:40:41 +0000 (00:40 +0300)] 
Moved doveadm zlib commands from zlib plugin to doveadm directly.
Previously it was a plugin, because the istream-zlib existed only in zlib
plugin. Now there's a lib-compression that implements it.

13 years agoistream: Added internal try_alloc_limit to limit size returned by i_stream_try_alloc()
Timo Sirainen [Fri, 12 Oct 2012 21:32:34 +0000 (00:32 +0300)] 
istream: Added internal try_alloc_limit to limit size returned by i_stream_try_alloc()
This was required by the previous SSL change.

13 years agolib-ssl-iostream: Make the input buffering behave the same as in file-istream
Timo Sirainen [Fri, 12 Oct 2012 21:24:47 +0000 (00:24 +0300)] 
lib-ssl-iostream: Make the input buffering behave the same as in file-istream
Previously i_stream_read(ssl_input) could have still left some data buffered
into the underlying file-istream, which meant that I/O loop didn't detect
any new input from the fd and the connection got stuck.

13 years agoconfig: Added lib-master's settings parsers back to config's knowledge
Timo Sirainen [Fri, 12 Oct 2012 20:18:58 +0000 (23:18 +0300)] 
config: Added lib-master's settings parsers back to config's knowledge

13 years agoconfigure: Make sure MYSQL_LIBS has -lmysqlclient even if it's not explicitly found.
Timo Sirainen [Fri, 12 Oct 2012 20:05:43 +0000 (23:05 +0300)] 
configure: Make sure MYSQL_LIBS has -lmysqlclient even if it's not explicitly found.

13 years agolib-storage: Fixed crash when attempting to remove subscriptions for nonexistent...
Timo Sirainen [Fri, 12 Oct 2012 05:48:25 +0000 (08:48 +0300)] 
lib-storage: Fixed crash when attempting to remove subscriptions for nonexistent shared users.

13 years agolib-index: dovecot.index file is no longer overwritten, so it doesn't need to be...
Timo Sirainen [Fri, 12 Oct 2012 05:39:31 +0000 (08:39 +0300)] 
lib-index: dovecot.index file is no longer overwritten, so it doesn't need to be locked.

13 years agolib-index: Log a warning if locking transaction log takes longer than 30 secs.
Timo Sirainen [Fri, 12 Oct 2012 05:31:15 +0000 (08:31 +0300)] 
lib-index: Log a warning if locking transaction log takes longer than 30 secs.

13 years agomaildir: If INDEXPVT is set, assume private \Seen flags even if dovecot-shared doesn...
Timo Sirainen [Fri, 12 Oct 2012 04:58:17 +0000 (07:58 +0300)] 
maildir: If INDEXPVT is set, assume private \Seen flags even if dovecot-shared doesn't exist.

13 years agolib-storage: Added support for "broken_char" setting for escaping invalid mailbox...
Timo Sirainen [Fri, 12 Oct 2012 02:45:42 +0000 (05:45 +0300)] 
lib-storage: Added support for "broken_char" setting for escaping invalid mailbox names.
This is currently enabled only for imapc backend, where '~' character is
used for it.

Most importantly this allows migrating mailboxes from other IMAP servers
that contain mailbox names that Dovecot's imapc backend couldn't otherwise
access.

13 years agolib-storage: Added optional mailbox_list.init(), which can check for failure.
Timo Sirainen [Fri, 12 Oct 2012 00:47:41 +0000 (03:47 +0300)] 
lib-storage: Added optional mailbox_list.init(), which can check for failure.
"index" backend now gives a nice error message instead of crashing when
mailbox_list_index=no

13 years agoBuild imapc and pop3c always as plugins.
Timo Sirainen [Fri, 12 Oct 2012 00:17:56 +0000 (03:17 +0300)] 
Build imapc and pop3c always as plugins.
This avoids having to link openssl library to all binaries that use
lib-storage. It appears that simply by linking with openssl causes each
such process to use 100-200 kB of more memory. With 10k imap processes this
is 1-2 GB of wasted memory.

The imapc and pop3c are still registered as stubs, and their plugins are
automatically loaded when needed.

13 years agolib-storage: Added mail_user_get_storage_class(), which auto-loads storage plugins.
Timo Sirainen [Fri, 12 Oct 2012 00:12:19 +0000 (03:12 +0300)] 
lib-storage: Added mail_user_get_storage_class(), which auto-loads storage plugins.
The auto-loading is done only if there's already a stub storage registered.

13 years agoMakefile: Added cc-wrapper.sh.in missing from last commit
Timo Sirainen [Fri, 12 Oct 2012 00:09:27 +0000 (03:09 +0300)] 
Makefile: Added cc-wrapper.sh.in missing from last commit

13 years ago--without-shared-libs: Link Dovecot libraries with --whole-archive flag for binaries.
Timo Sirainen [Fri, 12 Oct 2012 00:08:13 +0000 (03:08 +0300)] 
--without-shared-libs: Link Dovecot libraries with --whole-archive flag for binaries.
This removes the need for the ugly unused_objects lists for binaries, which
were needed to avoid plugins from failing because they were missing some
functions.

Apparently there's no easy way to use --whole-archive properly with libtool,
so there's now a rather ugly cc-wrapper.sh that does it. Also this is done
only when GNU ld is deted. Most people are going to use --with-shared-libs
though, so I don't think any of this is going to be a real problem.

13 years agoconfig: Don't include lib-master/*.c files in all-settings.c
Timo Sirainen [Thu, 11 Oct 2012 23:59:59 +0000 (02:59 +0300)] 
config: Don't include lib-master/*.c files in all-settings.c
lib-master is already being linked to the binaries anyway.

13 years agoimap: Don't waste data stack memory at startup.
Timo Sirainen [Thu, 11 Oct 2012 22:21:30 +0000 (01:21 +0300)] 
imap: Don't waste data stack memory at startup.

13 years agohostpid_init(): Don't waste memory from data stack.
Timo Sirainen [Thu, 11 Oct 2012 22:17:05 +0000 (01:17 +0300)] 
hostpid_init(): Don't waste memory from data stack.
Even though it's only a few bytes, it was being wasted permanently for all
processes.

13 years agoi_set_failure_prefix() now takes printf-like parameters.
Timo Sirainen [Thu, 11 Oct 2012 22:06:13 +0000 (01:06 +0300)] 
i_set_failure_prefix() now takes printf-like parameters.
This avoids using t_strdup_printf() with it, which was done very commonly.

13 years agolib-index: Error handling fix to cache transaction flushing.
Timo Sirainen [Thu, 11 Oct 2012 22:03:49 +0000 (01:03 +0300)] 
lib-index: Error handling fix to cache transaction flushing.

13 years agoPlugin ABI version checking improvements.
Timo Sirainen [Thu, 11 Oct 2012 21:51:41 +0000 (00:51 +0300)] 
Plugin ABI version checking improvements.
Previously the plugin version was checked against the version string
returned by the currently running Dovecot master process, not necessarily
the same as the binary. Also version_ignore=yes setting skipped the version
check entirely.

Now there's a new DOVECOT_ABI_VERSION macro that can (at least in theory) be
updated only when the ABI actually changes. The version is in format
"2.2.ABIv1(2.2.15)", where the (2.2.15) would be the actual Dovecot version
number that gets ignored when comparing the strings.

Also now the plugin version is compared to the actually running binary's
ABI, not the master's version, and it can't be ignored with a setting.

13 years agosdbox: Make sure mail_attachment_fs=sis-queue isn't attempted to be used.
Timo Sirainen [Thu, 11 Oct 2012 21:30:23 +0000 (00:30 +0300)] 
sdbox: Make sure mail_attachment_fs=sis-queue isn't attempted to be used.
It could be fixed, but nobody seems to have used it so far..

13 years agosdbox: Class didn't have MAIL_STORAGE_CLASS_FLAG_FILE_PER_MSG set
Timo Sirainen [Thu, 11 Oct 2012 21:29:41 +0000 (00:29 +0300)] 
sdbox: Class didn't have MAIL_STORAGE_CLASS_FLAG_FILE_PER_MSG set
This currently only meant that mail_prefetch_count setting wasn't working.

13 years agolib-fs API cleanups and improvements
Timo Sirainen [Thu, 11 Oct 2012 21:22:19 +0000 (00:22 +0300)] 
lib-fs API cleanups and improvements

13 years agoCompiler warning fix.
Timo Sirainen [Thu, 11 Oct 2012 20:01:13 +0000 (23:01 +0300)] 
Compiler warning fix.

13 years agoAdd HTTP date parsing support.
Stephan Bosch [Wed, 10 Oct 2012 20:59:12 +0000 (23:59 +0300)] 
Add HTTP date parsing support.

13 years agoAdds HTTP URL parse support.
Stephan Bosch [Wed, 10 Oct 2012 20:57:56 +0000 (23:57 +0300)] 
Adds HTTP URL parse support.

13 years agoAdjust IMAP URL parser to changes in uri-util.
Stephan Bosch [Wed, 10 Oct 2012 20:56:01 +0000 (23:56 +0300)] 
Adjust IMAP URL parser to changes in uri-util.

13 years agouri-util: Fix handling of '..' and '.' segments in URI paths.
Stephan Bosch [Wed, 10 Oct 2012 20:55:21 +0000 (23:55 +0300)] 
uri-util: Fix handling of '..' and '.' segments in URI paths.
As specified by RFC 3986

13 years agomaster: If service { protocol } is set and not included in "protocols", ignore its...
Timo Sirainen [Mon, 8 Oct 2012 05:53:54 +0000 (08:53 +0300)] 
master: If service { protocol } is set and not included in "protocols", ignore its settings

13 years agofts-lucene: doveadm fts rescan crashed with mailbox_list_index=yes
Timo Sirainen [Mon, 8 Oct 2012 00:14:12 +0000 (03:14 +0300)] 
fts-lucene: doveadm fts rescan crashed with mailbox_list_index=yes

13 years agofts-lucene: Compile fix for previous unlink_directory() change
Timo Sirainen [Sun, 7 Oct 2012 21:48:55 +0000 (00:48 +0300)] 
fts-lucene: Compile fix for previous unlink_directory() change

13 years agounlink_directory(): Added UNLINK_DIRECTORY_FLAG_SKIP_DOTFILES flag.
Timo Sirainen [Sun, 7 Oct 2012 21:00:55 +0000 (00:00 +0300)] 
unlink_directory(): Added UNLINK_DIRECTORY_FLAG_SKIP_DOTFILES flag.

13 years agolib-storage: Don't crash when searching multiple keywords.
Timo Sirainen [Thu, 4 Oct 2012 21:15:01 +0000 (00:15 +0300)] 
lib-storage: Don't crash when searching multiple keywords.
Fixed by simply removing the keyword merging code.
mail_search_args_simplify() is called before mail_search_args_init(), so the
keywords are still NULL and merging can't be done. Alternative fix would
have been to add string array to mail_search_arg.value containing the
keywords, but all of this is a pretty unnecessary optimization.

13 years agolib-index: Simplified writing to dovecot.index.cache file.
Timo Sirainen [Wed, 3 Oct 2012 23:34:53 +0000 (02:34 +0300)] 
lib-index: Simplified writing to dovecot.index.cache file.
The old method was basically:
 - write max. 32 kB to internal buffer
 - flush it by writing to reserved areas (with no locks)

The reserved areas were acquired by doing (whenever needed):
 - lock dovecot.index.cache
 - reserve data from dovecot.index.cache for writing, potentially increasing
   the file size by writing 0 bytes. the reserved area size varies.
 - unlock dovecot.index.cache

This worked, but if multiple processes were writing to the cache file it
could have left incomplete reserved areas as holes. The holes were attempted
to be filled if they were large enough.

The new method is:
 - write max. 256 kB to internal buffer
 - lock dovecot.index.cache
 - append the buffer to dovecot.index.cache
 - unlock dovecot.index.cache

No reserved areas, holes or anything else weird going on.

Ideally no data would be overwritten in the dovecot.index.cache file, only
appended. Unfortunately currently some data is still overwritten:
 - mail_cache_header.{deleted_space,continued_record_count}
 - mail_cache_header_fields.next_offset when writing a new one
 - mail_cache_header_fields.{last_used,decision}
 - mail_cache_record.prev_offset

The changing headers could eventually be moved to dovecot.index. This
however is a backwards-incompatible change. The record's prev_offset could
maybe simply just not be written in those (somewhat rare) problematic
situations.

13 years agodbox: Index rebuilding didn't open dovecot.index.backup file.
Timo Sirainen [Wed, 3 Oct 2012 23:08:23 +0000 (02:08 +0300)] 
dbox: Index rebuilding didn't open dovecot.index.backup file.
Recent changes broke it, and it was attemting to use dovecot.index/.backup
file instead.

13 years agoAdded/updated some copyright comments.
Timo Sirainen [Wed, 3 Oct 2012 21:56:14 +0000 (00:56 +0300)] 
Added/updated some copyright comments.

13 years agoRenamed network.[ch] to net.[ch].
Timo Sirainen [Wed, 3 Oct 2012 15:17:26 +0000 (18:17 +0300)] 
Renamed network.[ch] to net.[ch].
The function prefixes already started with net_ instead of network_.
And icecap wants to use network.h for other purpose. :)

13 years agoauth: More error checking and cleanups to SCRAM-SHA-1.
Timo Sirainen [Wed, 3 Oct 2012 13:57:28 +0000 (16:57 +0300)] 
auth: More error checking and cleanups to SCRAM-SHA-1.

13 years agolib-storage: Fixed potential memory leak when mailbox_transaction_commit_get_changes...
Timo Sirainen [Wed, 3 Oct 2012 02:43:27 +0000 (05:43 +0300)] 
lib-storage: Fixed potential memory leak when mailbox_transaction_commit_get_changes() failed

13 years agolib-storage: When configuring mailbox INBOX {}, make sure INBOX is uppercased.
Timo Sirainen [Wed, 3 Oct 2012 02:42:55 +0000 (05:42 +0300)] 
lib-storage: When configuring mailbox INBOX {}, make sure INBOX is uppercased.

13 years agolib-index: Fix for handling view syncing for already deleted transaction logs.
Timo Sirainen [Wed, 3 Oct 2012 02:41:46 +0000 (05:41 +0300)] 
lib-index: Fix for handling view syncing for already deleted transaction logs.
The sync changes' hidden-flag was set randomly, which could have caused
flag changes to get lost.

13 years agoimap: LIST (SPECIAL-USE) shouldn't send INBOX reply.
Timo Sirainen [Wed, 3 Oct 2012 02:20:29 +0000 (05:20 +0300)] 
imap: LIST (SPECIAL-USE) shouldn't send INBOX reply.

13 years agomaildir: Fixed crash with mailbox_list_index=yes
Timo Sirainen [Wed, 3 Oct 2012 02:15:11 +0000 (05:15 +0300)] 
maildir: Fixed crash with mailbox_list_index=yes

13 years agolib-dict: Fixed error handling on initialization.
Timo Sirainen [Wed, 3 Oct 2012 01:14:33 +0000 (04:14 +0300)] 
lib-dict: Fixed error handling on initialization.

13 years agolib-master: Fixed crashing with -i <instance> parameter handling.
Timo Sirainen [Wed, 3 Oct 2012 01:09:23 +0000 (04:09 +0300)] 
lib-master: Fixed crashing with -i <instance> parameter handling.

13 years agoTypofix: s/TRANSCATION/TRANSACTION/
Timo Sirainen [Wed, 3 Oct 2012 01:01:59 +0000 (04:01 +0300)] 
Typofix: s/TRANSCATION/TRANSACTION/

13 years agosdbox: Fix to handling transactions with partially failed saves.
Timo Sirainen [Tue, 2 Oct 2012 22:38:20 +0000 (01:38 +0300)] 
sdbox: Fix to handling transactions with partially failed saves.

13 years agomdbox: Fix to handling transactions with partially failed saves.
Timo Sirainen [Tue, 2 Oct 2012 22:26:42 +0000 (01:26 +0300)] 
mdbox: Fix to handling transactions with partially failed saves.

13 years agolib-storage: mailbox_save_cancel() now makes sure that dest_mail is reset.
Timo Sirainen [Tue, 2 Oct 2012 22:20:22 +0000 (01:20 +0300)] 
lib-storage: mailbox_save_cancel() now makes sure that dest_mail is reset.
This fixes e.g. doveadm import, which continues import even though some
messages couldn't be saved.

13 years agolib-storage: struct mail.close() now clears all of its data.
Timo Sirainen [Tue, 2 Oct 2012 22:19:19 +0000 (01:19 +0300)] 
lib-storage: struct mail.close() now clears all of its data.

13 years agodbox: Small code cleanup.
Timo Sirainen [Tue, 2 Oct 2012 22:12:13 +0000 (01:12 +0300)] 
dbox: Small code cleanup.

13 years agolib-storage: When index mkdir() fails with EPERM, create the dir anyway with 0700...
Timo Sirainen [Tue, 2 Oct 2012 20:24:10 +0000 (23:24 +0300)] 
lib-storage: When index mkdir() fails with EPERM, create the dir anyway with 0700 mode.
This avoids failing entirely when /var/mail/user has 0660 permissions and we
don't have access to the group. The error message is still logged.

13 years agolib-master: Fixed crashes with settings cache.
Timo Sirainen [Tue, 2 Oct 2012 20:12:07 +0000 (23:12 +0300)] 
lib-master: Fixed crashes with settings cache.

13 years agodoveadm: Fixed printing large input from doveadm-server.
Timo Sirainen [Tue, 2 Oct 2012 19:37:49 +0000 (22:37 +0300)] 
doveadm: Fixed printing large input from doveadm-server.

13 years agombox: Fixed getting filesystem permissions when parent dir has setgid-bit enabled.
Timo Sirainen [Tue, 2 Oct 2012 18:56:09 +0000 (21:56 +0300)] 
mbox: Fixed getting filesystem permissions when parent dir has setgid-bit enabled.

13 years agolmtp: Fixed hanging on proxying if remote server was down.
Timo Sirainen [Tue, 2 Oct 2012 18:36:43 +0000 (21:36 +0300)] 
lmtp: Fixed hanging on proxying if remote server was down.
Patch by Jack Bates.

13 years agoCompiling fix for HURD
Timo Sirainen [Fri, 28 Sep 2012 12:12:28 +0000 (15:12 +0300)] 
Compiling fix for HURD

13 years agoAvoid using PATH_MAX.
Timo Sirainen [Fri, 28 Sep 2012 12:11:30 +0000 (15:11 +0300)] 
Avoid using PATH_MAX.

13 years agoAvoid using PATH_MAX.
Timo Sirainen [Fri, 28 Sep 2012 12:07:11 +0000 (15:07 +0300)] 
Avoid using PATH_MAX.

13 years agomdbox: Don't crash in storage rebuild if mail's "original mailbox" metadata is missing.
Timo Sirainen [Wed, 26 Sep 2012 23:55:14 +0000 (02:55 +0300)] 
mdbox: Don't crash in storage rebuild if mail's "original mailbox" metadata is missing.

13 years agodoveadm altmove: Make sure all storages get purged (and not more than once)
Timo Sirainen [Wed, 26 Sep 2012 21:19:41 +0000 (00:19 +0300)] 
doveadm altmove: Make sure all storages get purged (and not more than once)

13 years agoi_getpwnam(): Ignore EINVAL errors silently.
Timo Sirainen [Wed, 26 Sep 2012 18:14:23 +0000 (21:14 +0300)] 
i_getpwnam(): Ignore EINVAL errors silently.
At least FreeBSD returns it when attempting to lookup user@domain.

13 years agolazy-expunge: Fixed handling non-default namespace separator.
Timo Sirainen [Wed, 26 Sep 2012 18:12:37 +0000 (21:12 +0300)] 
lazy-expunge: Fixed handling non-default namespace separator.

13 years agoauth ldap: Previous change broke %$ variable.
Timo Sirainen [Mon, 24 Sep 2012 14:03:42 +0000 (17:03 +0300)] 
auth ldap: Previous change broke %$ variable.

13 years agoldap auth: Update %variables after each field update.
Timo Sirainen [Mon, 24 Sep 2012 13:49:29 +0000 (16:49 +0300)] 
ldap auth: Update %variables after each field update.
The previous behavior was a bit confusing. "uid=user" at the beginning
updated the %u variable, but if it was after templates it didn't update it.
Also "=user=%{uid}" that was supposed to be equivalent wasn't. Now the
behavior is consistent across all ways to set the fields.

13 years agolib-storage: Added ALTNOCHECK option to mail_location.
Timo Sirainen [Mon, 24 Sep 2012 11:42:38 +0000 (14:42 +0300)] 
lib-storage: Added ALTNOCHECK option to mail_location.
By default Dovecot verifies that $rootdir/dbox-alt-root symlink matches the
ALT directory location, and logs an error if not. This is mainly to avoid
accidents during initial configuration when for example alt dir was set in
global mail_location but was forgotten to be set in userdb reply's
mail_location. The ALTNOCHECK setting simply doesn't check or create this
symlink, giving a (very) small performance improvement.

13 years agolmtp: Added lmtp_rcpt_check_quota setting to check quota already on RCPT TO.
Timo Sirainen [Mon, 24 Sep 2012 11:33:52 +0000 (14:33 +0300)] 
lmtp: Added lmtp_rcpt_check_quota setting to check quota already on RCPT TO.

13 years agolib-storage: Added STATUS_CHECK_OVER_QUOTA for checking if user is over quota.
Timo Sirainen [Mon, 24 Sep 2012 11:31:16 +0000 (14:31 +0300)] 
lib-storage: Added STATUS_CHECK_OVER_QUOTA for checking if user is over quota.

13 years agoimapc: And another compile fix..
Timo Sirainen [Mon, 24 Sep 2012 11:24:58 +0000 (14:24 +0300)] 
imapc: And another compile fix..
Using the macro would have required config/all-settings.c to include
imapc-client.h, which is a bit too much trouble just for this.

13 years agoimapc: Compile fix for previous change.
Timo Sirainen [Mon, 24 Sep 2012 11:22:40 +0000 (14:22 +0300)] 
imapc: Compile fix for previous change.

13 years agoauth: passdb imap assert-crashed always
Timo Sirainen [Mon, 24 Sep 2012 11:16:41 +0000 (14:16 +0300)] 
auth: passdb imap assert-crashed always

13 years agoimapc: Added IMAPC_DEFAULT_MAX_IDLE_TIME macro.
Timo Sirainen [Mon, 24 Sep 2012 11:16:32 +0000 (14:16 +0300)] 
imapc: Added IMAPC_DEFAULT_MAX_IDLE_TIME macro.

13 years agolib-lda: After auto-creating mailbox only open it, don't bother syncing it.
Timo Sirainen [Sat, 22 Sep 2012 16:23:15 +0000 (19:23 +0300)] 
lib-lda: After auto-creating mailbox only open it, don't bother syncing it.

13 years agomdbox: Delay getting permissions for map/message files.
Timo Sirainen [Fri, 21 Sep 2012 09:44:17 +0000 (11:44 +0200)] 
mdbox: Delay getting permissions for map/message files.
This avoids a stat() if no mailbox is opened.

13 years agolmtp: After successful proxying RCPT TO, the second one to nonexistent user gave...
Timo Sirainen [Fri, 21 Sep 2012 07:26:10 +0000 (09:26 +0200)] 
lmtp: After successful proxying RCPT TO, the second one to nonexistent user gave tempfail error.
Instead of "unknown user" it gave "Can't handle mixed proxy/non-proxy
destinations".

13 years agolmtp: RSET/LHLO should reset any pending proxy connections.
Timo Sirainen [Fri, 21 Sep 2012 07:23:58 +0000 (09:23 +0200)] 
lmtp: RSET/LHLO should reset any pending proxy connections.

13 years agoconfig: Don't ignore invalid network/mask in local/remote blocks
Timo Sirainen [Fri, 21 Sep 2012 07:22:54 +0000 (09:22 +0200)] 
config: Don't ignore invalid network/mask in local/remote blocks