Postfix -> bogogilter -> Dovecot -> Sieve

2021-11-16 Thread Mike



I've been trying to work out how to get postfix to accept mail, send  
it to bogofilter, then deliver using dovecot while allowing a global  
sieve filter and users able to filter mail based on the bogofilter  
header.


I've been successful at getting it to add the bogofilter header as  
needed, but don't understand what I need to do in order to have it get  
routed to sieve.


Anyone do anything like this already and have a working config?

I THINK I need to make dovecot deliver mail locally using lmtp or lda,  
but I'm not exactly sure.


Thanks for any thoughts or ideas that you might have to accomplish this.


Mike.


Order of loading and checking userdb on Ubuntu

2022-01-16 Thread Mike
When using the lmtp service for local delivery, I'd like to change the  
user lookup to only use the user portion of the email address.


I think I do that in the 20-lmtp.conf file, but not exactly sure how.

From what I've found on the web, I just need to change the  
auth_username_format=%n.


I feel confident that I'm not doing it right.

older posts implied that the order things are loaded is an issue, but  
not sure if that is the case anymore.


My goal is to set username_format for only lmtp.

Thanks for any help.


Re: Order of loading and checking userdb on Ubuntu

2022-01-16 Thread Mike

BTW, I THINK the right answer is just to set

auth_username_format = %Ln

in 20-lmtp.conf to make it look like this:

protocol lmtp {
  # this postmaster_address entry is required???  Saw that in a much  
older post

  postmaster_address = postmas...@mydomain.com
  # Space separated list of plugins to load (default is global mail_plugins).
  mail_plugins = $mail_plugins sieve
  auth_username_format = %Ln
  info_log_path = /var/log/dovecot-lmtp.log
}




Just want to make sure that it will only affect lmtp.

Mike

Quoting Mike :

When using the lmtp service for local delivery, I'd like to change  
the user lookup to only use the user portion of the email address.


I think I do that in the 20-lmtp.conf file, but not exactly sure how.

From what I've found on the web, I just need to change the  
auth_username_format=%n.


I feel confident that I'm not doing it right.

older posts implied that the order things are loaded is an issue,  
but not sure if that is the case anymore.


My goal is to set username_format for only lmtp.

Thanks for any help.





sockets created for lmtp

2022-01-17 Thread Mike

Was recently configuring lmtp to listen in the postfix spool for mail.

I set the socket as suggested in the documentation, however, when I  
look at what sockets were created there was an additional one for  
dovecot.


Since I made the change, my expectation would have been just the one  
that I set up.


I doubt it impacts it negatively, but I wanted to understand if I  
configured things correctly or not.


Thanks.

Mike



Re: sockets created for lmtp

2022-01-18 Thread Mike



Quoting Aki Tuomi :


On 17/01/2022 20:56 Mike  wrote:


Was recently configuring lmtp to listen in the postfix spool for mail.

I set the socket as suggested in the documentation, however, when I
look at what sockets were created there was an additional one for
dovecot.

Since I made the change, my expectation would have been just the one
that I set up.

I doubt it impacts it negatively, but I wanted to understand if I
configured things correctly or not.

Thanks.

Mike


Can you provide any details on what you did, what you expected, and  
what you actually observed?


Aki


Sure.  I used the documentation to setup lmtp from here:

https://doc.dovecot.org/configuration_manual/howto/postfix_dovecot_lmtp/

When issuing this command:

ss -lxn | grep lmtp

And I get:

u_str LISTEN  0   100
private/lmtp 64917 * 0
u_str LISTEN  0   100 
/var/spool/postfix/private/dovecot-lmtp 63578 * 0
u_str LISTEN  0   100   
/var/run/dovecot/lmtp 63575 * 0


When I expect:

u_str LISTEN  0   100
private/lmtp 64917 * 0
u_str LISTEN  0   100 
/var/spool/postfix/private/dovecot-lmtp 63578 * 0


The first entry I believe belongs to postfix.
The second one is the one I set as above.
The third seems to be an extra.

I have an Ubuntu setup if that matters.

Again, I don't think it is an issue.  Everything seems to work, just  
thought it makes sense to understand what is going on.


Mike




Re: sockets created for lmtp

2022-01-19 Thread Mike



Quoting Aki Tuomi :


On 19/01/2022 01:07 Mike  wrote:


Quoting Aki Tuomi :

>> On 17/01/2022 20:56 Mike  wrote:
>>
>>
>> Was recently configuring lmtp to listen in the postfix spool for mail.
>>
>> I set the socket as suggested in the documentation, however, when I
>> look at what sockets were created there was an additional one for
>> dovecot.
>>
>> Since I made the change, my expectation would have been just the one
>> that I set up.
>>
>> I doubt it impacts it negatively, but I wanted to understand if I
>> configured things correctly or not.
>>
>> Thanks.
>>
>> Mike
>
> Can you provide any details on what you did, what you expected, and
> what you actually observed?
>
> Aki

Sure.  I used the documentation to setup lmtp from here:

https://doc.dovecot.org/configuration_manual/howto/postfix_dovecot_lmtp/

When issuing this command:

ss -lxn | grep lmtp

And I get:

u_str LISTEN  0   100
private/lmtp 64917 * 0
u_str LISTEN  0   100
/var/spool/postfix/private/dovecot-lmtp 63578 * 0
u_str LISTEN  0   100
/var/run/dovecot/lmtp 63575 * 0

When I expect:

u_str LISTEN  0   100
private/lmtp 64917 * 0
u_str LISTEN  0   100
/var/spool/postfix/private/dovecot-lmtp 63578 * 0

The first entry I believe belongs to postfix.
The second one is the one I set as above.
The third seems to be an extra.

I have an Ubuntu setup if that matters.

Again, I don't think it is an issue.  Everything seems to work, just
thought it makes sense to understand what is going on.

Mike


Check `doveconf service/lmtp`

Aki


service {
  chroot =
  client_limit = 1
  drop_priv_before_exec = no
  executable = lmtp -L
  extra_groups = $default_internal_group
  group =
  idle_kill = 0
  privileged_group =
  process_limit = 0
  process_min_avail = 0
  protocol = lmtp
  service_count = 0
  type =
  unix_listener {
group = postfix
mode = 0600
user = postfix
path = /var/spool/postfix/private/dovecot-lmtp
  }
  unix_listener {
group =
mode = 0666
user =
path = lmtp
  }
  user =
  vsz_limit = 18446744073709551615 B
  name = lmtp
}

I assume the second unix_listener stanza is where the other entry  
comes from, but I haven't a clue where it is getting defined.


I'll keep looking.

Thanks.

Mike



[Dovecot] auth_debug_passwords only on mismatches?

2008-03-04 Thread Mike
>From the configuration notes (1.0.10), it sounds like setting
'auth_debug_passwords' will only log the user supplied password if there was
a mismatch.. When I set it (with auth_debug=no), I get a good amount of auth
debug info, regardless of password matching..

--
dovecot.conf:
# In case of password mismatches, log the passwords and used scheme so the
# problem can be debugged. Requires auth_debug=yes to be set.
auth_debug_passwords = yes
--

I'm basically looking to just add a "login failed" line, with the username,
and supplied passsword when a mismatch occurs..
Is there currently a way to do this without modifying the code?

Thanks!

-Mike


[Dovecot] Dovecot-1.1.1 with quota and antispam plugin - segmentation fault

2008-07-11 Thread mike

Hello! 

I have port-built dovecot-1.1.1 on freebsd 6.3 i386 box.

There is signal 11 on imap child occurs every time when i'm trying to send
email.
In fact, email is sending to MTA correctly, but when message moving to Sent
folder segmentation error appears.

I built dovecot and antispam plugin with -g3 -O0 -pipe

With GDB I recieve next:

GNU gdb 6.1.1 [FreeBSD]
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you
are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i386-marcel-freebsd"...(no debugging symbols
found)...
Attaching to program: /usr/local/libexec/dovecot/imap, process 10427
Reading symbols from /usr/local/lib/libiconv.so.3...(no debugging symbols
found)...done.
Loaded symbols for /usr/local/lib/libiconv.so.3
Reading symbols from /lib/libc.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib/libc.so.6
Reading symbols from
/usr/local/lib/dovecot/imap/lib10_quota_plugin.so...done.
Loaded symbols for /usr/local/lib/dovecot/imap/lib10_quota_plugin.so
Reading symbols from /usr/lib/librpcsvc.so.3...done.
Loaded symbols for /usr/lib/librpcsvc.so.3
Reading symbols from
/usr/local/lib/dovecot/imap/lib11_imap_quota_plugin.so...done.
Loaded symbols for /usr/local/lib/dovecot/imap/lib11_imap_quota_plugin.so
Reading symbols from
/usr/local/lib/dovecot/imap/lib90_antispam_plugin.so...done.
Loaded symbols for /usr/local/lib/dovecot/imap/lib90_antispam_plugin.so
Reading symbols from /libexec/ld-elf.so.1...done.
Loaded symbols for /libexec/ld-elf.so.1
0x182b7eeb in kevent () from /lib/libc.so.6
(gdb) SignalStopPrint   Pass to program Description
SIGPIPE   NoYes Yes Broken pipe
(gdb) SignalStopPrint   Pass to program Description
SIGALRM   NoNo  Yes Alarm clock
(gdb) SignalStopPrint   Pass to program Description
SIG32 NoYes Yes Real-time event 32
(gdb) Continuing.

Program received signal SIGSEGV, Segmentation fault.
0x080a968c in mail_get_physical_size ()
(gdb) #0  0x080a968c in mail_get_physical_size ()
No symbol table info available.
#1  0x1831d07a in quota_try_alloc (ctx=0x8128700, mail=0x0,
too_large_r=0xbfbfe74b) at quota.c:797
size = 4
ret = 0
#2  0x183213ce in quota_check (t=0x812e580, mail=0x0) at
quota-storage.c:148
qt = (struct quota_transaction_context *) 0x8128700
ret = 134728787
too_large = 191
#3  0x18321740 in quota_save_finish (ctx=0x8152028) at quota-storage.c:251
qt = (struct quota_transaction_context *) 0x8128700
qbox = (struct quota_mailbox *) 0x81381e8
#4  0x1833212f in antispam_save_finish (ctx=0x8152028)
at antispam-storage-1.1.c:178
asbox = (struct antispam_mailbox *) 0x8138280
ast = (struct antispam_internal_context *) 0x812b270
dest_mail = (struct mail *) 0x4
ret = 0
#5  0x080ac4ed in mailbox_save_finish ()
No symbol table info available.
#6  0x08059caa in _start ()
No symbol table info available.
#7  0x080590f3 in _start ()
No symbol table info available.
#8  0x080ee05d in io_loop_handler_run ()
No symbol table info available.
#9  0x080ed385 in io_loop_run ()
No symbol table info available.
#10 0x0806a6ff in main ()
No symbol table info available.
(gdb) Detaching from program: /usr/local/libexec/dovecot/imap, process
10427




Re: [Dovecot] Dovecot-1.1.1 with quota and antispam plugin - segmentation fault

2008-07-11 Thread mike

Hi again!


I've make some investigation and found next in 

dovecot-1.1.1/src/plugins/quota/quota-storage.c
  242 static int quota_save_finish(struct mail_save_context *ctx)
  243 {
  244   struct quota_transaction_context *qt =
QUOTA_CONTEXT(ctx->transaction);
  245   struct quota_mailbox *qbox = QUOTA_CONTEXT(ctx->transaction->box);
  246 
  247   if (qbox->module_ctx.super.save_finish(ctx) < 0)
  248   return -1;
  249 
  250   qbox->save_hack = TRUE;
  251   return quota_check(ctx->transaction, ctx->dest_mail != NULL ?
  252  ctx->dest_mail : qt->tmp_mail);
  253 }


and in src/dovecot-antispam/antispam-storage-1.1.c

169 static int antispam_save_finish(struct mail_save_context *ctx)
170 {
171 struct antispam_mailbox *asbox =
172 ANTISPAM_CONTEXT(ctx->transaction->box);
173 struct antispam_internal_context *ast =
174 ANTISPAM_CONTEXT(ctx->transaction);
175 struct mail *dest_mail;
176 int ret;
177
178 if (asbox->module_ctx.super.save_finish(ctx) < 0)
179 return -1;
180
181 dest_mail = ctx->dest_mail ? : ast->mail;
182
183 asbox->save_hack = TRUE;
184
185 ret = 0;
186
187 switch (asbox->movetype) {
188 case MMT_UNINTERESTING:
189 break;
190 case MMT_APPEND:



PS: I've tried to recompile dovecot and plugin with gcc43 instead of
gcc2.95 and with -O0 optimizations - same error in a same place.
As I understood segfault appears when sent message moving in sent folder or
when draft message appears in draft. I think it occurs when both plugins
trying to save same message

WBR, Mike


On Fri, 11 Jul 2008 10:48:13 +0300, <[EMAIL PROTECTED]> wrote:
> 
> Hello! 
> 
> I have port-built dovecot-1.1.1 on freebsd 6.3 i386 box.
> 
> There is signal 11 on imap child occurs every time when i'm trying to
send
> email.
> In fact, email is sending to MTA correctly, but when message moving to
> Sent
> folder segmentation error appears.
> 
> I built dovecot and antispam plugin with -g3 -O0 -pipe
> 
> With GDB I recieve next:
> 
> GNU gdb 6.1.1 [FreeBSD]
> Copyright 2004 Free Software Foundation, Inc.
> GDB is free software, covered by the GNU General Public License, and you
> are
> welcome to change it and/or distribute copies of it under certain
> conditions.
> Type "show copying" to see the conditions.
> There is absolutely no warranty for GDB.  Type "show warranty" for
> details.
> This GDB was configured as "i386-marcel-freebsd"...(no debugging symbols
> found)...
> Attaching to program: /usr/local/libexec/dovecot/imap, process 10427
> Reading symbols from /usr/local/lib/libiconv.so.3...(no debugging symbols
> found)...done.
> Loaded symbols for /usr/local/lib/libiconv.so.3
> Reading symbols from /lib/libc.so.6...(no debugging symbols
found)...done.
> Loaded symbols for /lib/libc.so.6
> Reading symbols from
> /usr/local/lib/dovecot/imap/lib10_quota_plugin.so...done.
> Loaded symbols for /usr/local/lib/dovecot/imap/lib10_quota_plugin.so
> Reading symbols from /usr/lib/librpcsvc.so.3...done.
> Loaded symbols for /usr/lib/librpcsvc.so.3
> Reading symbols from
> /usr/local/lib/dovecot/imap/lib11_imap_quota_plugin.so...done.
> Loaded symbols for /usr/local/lib/dovecot/imap/lib11_imap_quota_plugin.so
> Reading symbols from
> /usr/local/lib/dovecot/imap/lib90_antispam_plugin.so...done.
> Loaded symbols for /usr/local/lib/dovecot/imap/lib90_antispam_plugin.so
> Reading symbols from /libexec/ld-elf.so.1...done.
> Loaded symbols for /libexec/ld-elf.so.1
> 0x182b7eeb in kevent () from /lib/libc.so.6
> (gdb) SignalStopPrint   Pass to program Description
> SIGPIPE   NoYes Yes Broken pipe
> (gdb) SignalStopPrint   Pass to program Description
> SIGALRM   NoNo  Yes Alarm clock
> (gdb) SignalStopPrint   Pass to program Description
> SIG32 NoYes Yes Real-time event 32
> (gdb) Continuing.
> 
> Program received signal SIGSEGV, Segmentation fault.
> 0x080a968c in mail_get_physical_size ()
> (gdb) #0  0x080a968c in mail_get_physical_size ()
> No symbol table info available.
> #1  0x1831d07a in quota_try_alloc (ctx=0x8128700, mail=0x0,
> too_large_r=0xbfbfe74b) at quota.c:797
> size = 4
> ret = 0
> #2  0x183213ce in quota_check (t=0x812e580, mail=0x0) at
> quota-storage.c:148
> qt = (struct quota_transaction_context *) 0x8128700
> ret = 134728787
> too_large = 191
> #3  0x18321740 in quota_s

[Dovecot] Dovecot from inetd, when it playing like LDA also

2008-08-22 Thread mike

Hello Dovecot guys!

I want to play with dovecot login processes invoked from inetd superserver,
but cannot run auth worker for postfix sasl and deliver process in this
case.
Any ideas?

WBR, mike



Re: [Dovecot] Dovecot from inetd, when it playing like LDA also

2008-08-22 Thread mike

Sorry guys, config issue. All is working like a charm.

On Fri, 22 Aug 2008 13:48:55 +0300, <[EMAIL PROTECTED]> wrote:
> 
> Hello Dovecot guys!
> 
> I want to play with dovecot login processes invoked from inetd
> superserver,
> but cannot run auth worker for postfix sasl and deliver process in this
> case.
> Any ideas?
> 
> WBR, mike



Re: [Dovecot] antispam plugin signature-log backend with v1.1.2

2008-09-22 Thread mike

1.1.3 on FreeBSD. Dovecot from ports, antispam plugin from git.

On Mon, 22 Sep 2008 13:52:50 +0200, Alexander Prinsier
<[EMAIL PROTECTED]> wrote:
> Johannes Berg wrote:
>> On Mon, 2008-09-22 at 00:59 +0200, Alexander Prinsier wrote:
>>> Hello,
>>>
>>> Is the signature-log backend of the antispam plugin broken when
>>> compiling with dovecot version 1.1.2? I'm using version 1.0 of the
>>> antispam plugin. It looks like there isn't anything more recent.
>>
>> It has never even worked correctly so I haven't bothered to update it
>> for a long time, sorry. You can probably find some old notes from me
>> about that on the list archive.
> 
> Oh it worked very fine for me with dovecot 1.0 :) I'll see what I can do
> to fix it, or I'll use another version of dovecot if I can't get it fixed
> :)
> 
> Alexander



[Dovecot] proxy and gpg processing

2010-12-07 Thread Mike
Hi

I have dovecot running as pure proxy for accessing imap and pop mailboxes
on other servers.

How can I do the following scenario:

When a client user reads a gpg signed or gpg encrypted email through the
proxy, can I verify/decrypt the email before it gets delivered to the
client user?

Ideally I would like to write a perl program which processes the email
within the proxy before it gets delivered to the user. With Sieve I can
not do this, is there another way to achieve this?

Thanks for any hint.
Mike




dying on osx

2018-08-10 Thread Mike Makuch

OSX 10.13.6 High Sierra, dovecot 2.3.2.1

dovecot starts up and runs but dies as soon as my mail client makes a 
request with log and config below.


And advice appreciated.

Thanks

Mike



20180810-083730 auth: Debug: auth client connected (pid=77432)

20180810-083730 auth: Debug: client in: AUTH    1    PLAIN 
service=imap    secured    session=xo1p2BRzZNd/AAAB lip=127.0.0.1    
rip=127.0.0.1    lport=143    rport=55140

20180810-083730 auth: Debug: client passdb out: CONT    1
20180810-083730 auth: Debug: client in: CONT    1 AG1rbQBta20xMjM= 
(previous base64 data may contain sensitive data)
20180810-083730 auth: Debug: static(mkm,127.0.0.1,): 
lookup
20180810-083730 auth: Debug: client passdb out: OK    1 user=mkm    
host=localhost    nopasswd=y
20180810-083730 auth: Debug: master in: REQUEST    4201906177 77432    
1    b8126b4b71be2959fc7716888eccc566 session_pid=77433    
request_auth_token
20180810-083730 auth-worker(77426): Debug: 
passwd(mkm,127.0.0.1,): lookup
20180810-083730 auth: Debug: master userdb out: USER 4201906177    
mkm    system_groups_user=mkm    uid=503 gid=20    home=/Users/mkm 
auth_token=4d2bb44168df3d63e4e1bb352e59de632bc7da49
20180810-083730 imap-login: Info: Login: user=, method=PLAIN, 
rip=127.0.0.1, lip=127.0.0.1, mpid=77433, secured, 
session=
20180810-083730 imap(mkm)<77433>: Fatal: 
setgroups(505) failed: Too many extra groups


# doveconf -n
# 2.3.2.1 (0719df592): /usr/local/etc/dovecot/dovecot.conf
# OS: Darwin 17.7.0 x86_64
# Hostname: pine
auth_debug = yes
auth_debug_passwords = yes
default_internal_user = _dovecot
default_login_user = _dovenull
disable_plaintext_auth = no
listen = 127.0.0.1
log_path = /var/log/dovecot
log_timestamp = "%Y%m%d-%H%M%S "
mail_debug = yes
mail_gid = staff
mail_location = mbox:~/Mail:INBOX=/var/mail/%u
mail_privileged_group = mail
mail_uid = _dovecot
passdb {
  args = password=*** host=localhost nopasswd=y
  driver = static
}
passdb {
  args = login
  driver = pam
}
protocols = imap
service auth {
  user = root
}
service imap-login {
  inet_listener imap {
    address = *
    port = 143
  }
}
ssl = no
userdb {
  driver = passwd
}




Re: dying on osx

2018-08-10 Thread Mike Makuch

Maybe an old problem that has resurfaced???

https://bugzilla.samba.org/show_bug.cgi?id=8773

Mike



On 8/10/18 10:54, Aki Tuomi wrote:

I have to see if this is reproducible outside mac.



---
Aki Tuomi
Dovecot oy

 Original message 
From: Mike Makuch <1mikemak...@gmail.com>
Date: 10/08/2018 18:46 (GMT+02:00)
To: Aki Tuomi 
Subject: Re: dying on osx

I did find that page and tried a few things there. My config has all of
the settings there except 3:

mail_access_groups = mail
mbox_read_locks = fcntl
mbox_write_locks = fcntl

I add them to my config, restart and get the same abort

20180810-103849 imap(mkm)<79213>: Fatal:
setgroups(mail,505) failed: Too many extra groups

I've tried numerous other settings as well.

Thanks for any further advice

Mike


On 8/10/18 08:45, Aki Tuomi wrote:
> Can you try this config and report back?
>
> 
https://superuser.com/questions/957272/dotlock-permissions-problems-with-dovecot-and-os-x-10-10-3

>
> Aki
>
>> On 10 August 2018 at 16:39 Mike Makuch <1mikemak...@gmail.com> wrote:
>>
>>
>> OSX 10.13.6 High Sierra, dovecot 2.3.2.1
>>
>> dovecot starts up and runs but dies as soon as my mail client makes a
>> request with log and config below.
>>
>> And advice appreciated.
>>
>> Thanks
>>
>> Mike
>>
>>
>>
>> 20180810-083730 auth: Debug: auth client connected (pid=77432)
>>
>> 20180810-083730 auth: Debug: client in: AUTH    1 PLAIN
>> service=imap    secured    session=xo1p2BRzZNd/AAAB lip=127.0.0.1
>> rip=127.0.0.1    lport=143    rport=55140
>> 20180810-083730 auth: Debug: client passdb out: CONT    1
>> 20180810-083730 auth: Debug: client in: CONT    1 AG1rbQBta20xMjM=
>> (previous base64 data may contain sensitive data)
>> 20180810-083730 auth: Debug: static(mkm,127.0.0.1,):
>> lookup
>> 20180810-083730 auth: Debug: client passdb out: OK    1 user=mkm
>> host=localhost    nopasswd=y
>> 20180810-083730 auth: Debug: master in: REQUEST 4201906177 77432
>> 1    b8126b4b71be2959fc7716888eccc566 session_pid=77433
>> request_auth_token
>> 20180810-083730 auth-worker(77426): Debug:
>> passwd(mkm,127.0.0.1,): lookup
>> 20180810-083730 auth: Debug: master userdb out: USER 4201906177
>> mkm    system_groups_user=mkm    uid=503 gid=20 home=/Users/mkm
>> auth_token=4d2bb44168df3d63e4e1bb352e59de632bc7da49
>> 20180810-083730 imap-login: Info: Login: user=, method=PLAIN,
>> rip=127.0.0.1, lip=127.0.0.1, mpid=77433, secured,
>> session=
>> 20180810-083730 imap(mkm)<77433>: Fatal:
>> setgroups(505) failed: Too many extra groups
>>
>> # doveconf -n
>> # 2.3.2.1 (0719df592): /usr/local/etc/dovecot/dovecot.conf
>> # OS: Darwin 17.7.0 x86_64
>> # Hostname: pine
>> auth_debug = yes
>> auth_debug_passwords = yes
>> default_internal_user = _dovecot
>> default_login_user = _dovenull
>> disable_plaintext_auth = no
>> listen = 127.0.0.1
>> log_path = /var/log/dovecot
>> log_timestamp = "%Y%m%d-%H%M%S "
>> mail_debug = yes
>> mail_gid = staff
>> mail_location = mbox:~/Mail:INBOX=/var/mail/%u
>> mail_privileged_group = mail
>> mail_uid = _dovecot
>> passdb {
>>     args = password=*** host=localhost nopasswd=y
>>     driver = static
>> }
>> passdb {
>>     args = login
>>     driver = pam
>> }
>> protocols = imap
>> service auth {
>>     user = root
>> }
>> service imap-login {
>>     inet_listener imap {
>>       address = *
>>       port = 143
>>     }
>> }
>> ssl = no
>> userdb {
>>     driver = passwd
>> }
>>
>>





Re: dying on osx

2018-08-10 Thread Mike Makuch


$ grep dove /etc/passwd /etc/group
/etc/passwd:_dovecot:*:214:6:Dovecot Administrator:/var/empty:/usr/bin/false
/etc/passwd:_dovenull:*:227:227:Dovecot 
Authentication:/var/empty:/usr/bin/false

/etc/group:certusers:*:29:root,_jabber,_postfix,_cyrus,_calendar,_dovecot
/etc/group:_dovenull:*:227:


I'm trying to build on osx so I can try to do some debugging. The 
INSTALL.md says to do:



$ more INSTALL.md
Build Instructions
==

For most people, the usual:

```
./configure
make
sudo make install
```

But there is no configure file. How would I generate the configure file? 
Is it generated? Been a long time since I've done open source C code..


Thanks

Mike


On 8/10/18 11:04, Aki Tuomi wrote:

Is the user member of mail group?



---
Aki Tuomi
Dovecot oy

 Original message ----
From: Mike Makuch <1mikemak...@gmail.com>
Date: 10/08/2018 19:02 (GMT+02:00)
To: Aki Tuomi 
Cc: dovecot@dovecot.org
Subject: Re: dying on osx

Maybe an old problem that has resurfaced???

https://bugzilla.samba.org/show_bug.cgi?id=8773

Mike



On 8/10/18 10:54, Aki Tuomi wrote:

I have to see if this is reproducible outside mac.



---
Aki Tuomi
Dovecot oy

 Original message ----
From: Mike Makuch <1mikemak...@gmail.com>
Date: 10/08/2018 18:46 (GMT+02:00)
To: Aki Tuomi 
Subject: Re: dying on osx

I did find that page and tried a few things there. My config has all of
the settings there except 3:

mail_access_groups = mail
mbox_read_locks = fcntl
mbox_write_locks = fcntl

I add them to my config, restart and get the same abort

20180810-103849 imap(mkm)<79213>: Fatal:
setgroups(mail,505) failed: Too many extra groups

I've tried numerous other settings as well.

Thanks for any further advice

Mike


On 8/10/18 08:45, Aki Tuomi wrote:
> Can you try this config and report back?
>
> 
https://superuser.com/questions/957272/dotlock-permissions-problems-with-dovecot-and-os-x-10-10-3

>
> Aki
>
>> On 10 August 2018 at 16:39 Mike Makuch <1mikemak...@gmail.com> wrote:
>>
>>
>> OSX 10.13.6 High Sierra, dovecot 2.3.2.1
>>
>> dovecot starts up and runs but dies as soon as my mail client makes a
>> request with log and config below.
>>
>> And advice appreciated.
>>
>> Thanks
>>
>> Mike
>>
>>
>>
>> 20180810-083730 auth: Debug: auth client connected (pid=77432)
>>
>> 20180810-083730 auth: Debug: client in: AUTH    1 PLAIN
>> service=imap    secured    session=xo1p2BRzZNd/AAAB lip=127.0.0.1
>> rip=127.0.0.1    lport=143    rport=55140
>> 20180810-083730 auth: Debug: client passdb out: CONT 1
>> 20180810-083730 auth: Debug: client in: CONT    1 AG1rbQBta20xMjM=
>> (previous base64 data may contain sensitive data)
>> 20180810-083730 auth: Debug: static(mkm,127.0.0.1,):
>> lookup
>> 20180810-083730 auth: Debug: client passdb out: OK    1 user=mkm
>> host=localhost    nopasswd=y
>> 20180810-083730 auth: Debug: master in: REQUEST 4201906177 77432
>> 1    b8126b4b71be2959fc7716888eccc566 session_pid=77433
>> request_auth_token
>> 20180810-083730 auth-worker(77426): Debug:
>> passwd(mkm,127.0.0.1,): lookup
>> 20180810-083730 auth: Debug: master userdb out: USER 4201906177
>> mkm    system_groups_user=mkm    uid=503 gid=20 home=/Users/mkm
>> auth_token=4d2bb44168df3d63e4e1bb352e59de632bc7da49
>> 20180810-083730 imap-login: Info: Login: user=, method=PLAIN,
>> rip=127.0.0.1, lip=127.0.0.1, mpid=77433, secured,
>> session=
>> 20180810-083730 imap(mkm)<77433>: Fatal:
>> setgroups(505) failed: Too many extra groups
>>
>> # doveconf -n
>> # 2.3.2.1 (0719df592): /usr/local/etc/dovecot/dovecot.conf
>> # OS: Darwin 17.7.0 x86_64
>> # Hostname: pine
>> auth_debug = yes
>> auth_debug_passwords = yes
>> default_internal_user = _dovecot
>> default_login_user = _dovenull
>> disable_plaintext_auth = no
>> listen = 127.0.0.1
>> log_path = /var/log/dovecot
>> log_timestamp = "%Y%m%d-%H%M%S "
>> mail_debug = yes
>> mail_gid = staff
>> mail_location = mbox:~/Mail:INBOX=/var/mail/%u
>> mail_privileged_group = mail
>> mail_uid = _dovecot
>> passdb {
>>     args = password=*** host=localhost nopasswd=y
>>     driver = static
>> }
>> passdb {
>>     args = login
>>     driver = pam
>> }
>> protocols = imap
>> service auth {
>>     user = root
>> }
>> service imap-login {
>>     inet_listener imap {
>>       address = *
>>       port = 143
>>     }
>> }
>> ssl = no
>> userdb {
>>     driver = passwd
>> }
>>
>>







Re: dying on osx

2018-08-10 Thread Mike Makuch
I've cloned https://github.com/dovecot/core and tried running autogen.sh 
but it fails:



$ bash autogen.sh
/Users/mkm/src/dovecot/doc
--2018-08-10 11:10:26-- https://www.dovecot.org/tmp/wiki2-export.tar.gz
Resolving www.dovecot.org... 94.237.25.159
Connecting to www.dovecot.org|94.237.25.159|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 427414 (417K) [application/x-gzip]
Saving to: ‘wiki2-export.tar.gz’

wiki2-export.tar.gz 
100%[===>] 
417.40K   432KB/s    in 1.0s


2018-08-10 11:10:28 (432 KB/s) - ‘wiki2-export.tar.gz’ saved [427414/427414]

/Users/mkm/src/dovecot/doc/wiki
glibtoolize: putting auxiliary files in '.'.
glibtoolize: copying file './ltmain.sh'
glibtoolize: putting macros in AC_CONFIG_MACRO_DIRS, 'm4'.
glibtoolize: copying file 'm4/libtool.m4'
glibtoolize: copying file 'm4/ltoptions.m4'
glibtoolize: copying file 'm4/ltsugar.m4'
glibtoolize: copying file 'm4/ltversion.m4'
glibtoolize: copying file 'm4/lt~obsolete.m4'
configure.ac:293: installing './compile'
configure.ac:299: installing './config.guess'
configure.ac:300: error: required file './config.rpath' not found
configure.ac:299: installing './config.sub'
configure.ac:11: installing './install-sh'
configure.ac:11: installing './missing'
src/anvil/Makefile.am: installing './depcomp'
autoreconf: automake failed with exit status: 1


Any suggestions on how to build on osx?

Thanks

Mike





On 8/10/18 11:08, Mike Makuch wrote:



$ grep dove /etc/passwd /etc/group
/etc/passwd:_dovecot:*:214:6:Dovecot 
Administrator:/var/empty:/usr/bin/false
/etc/passwd:_dovenull:*:227:227:Dovecot 
Authentication:/var/empty:/usr/bin/false

/etc/group:certusers:*:29:root,_jabber,_postfix,_cyrus,_calendar,_dovecot
/etc/group:_dovenull:*:227:


I'm trying to build on osx so I can try to do some debugging. The 
INSTALL.md says to do:



$ more INSTALL.md
Build Instructions
==

For most people, the usual:

```
./configure
make
sudo make install
```

But there is no configure file. How would I generate the configure 
file? Is it generated? Been a long time since I've done open source C 
code..


Thanks

Mike


On 8/10/18 11:04, Aki Tuomi wrote:

Is the user member of mail group?



---
Aki Tuomi
Dovecot oy

 Original message 
From: Mike Makuch <1mikemak...@gmail.com>
Date: 10/08/2018 19:02 (GMT+02:00)
To: Aki Tuomi 
Cc: dovecot@dovecot.org
Subject: Re: dying on osx

Maybe an old problem that has resurfaced???

https://bugzilla.samba.org/show_bug.cgi?id=8773

Mike



On 8/10/18 10:54, Aki Tuomi wrote:

I have to see if this is reproducible outside mac.



---
Aki Tuomi
Dovecot oy

 Original message 
From: Mike Makuch <1mikemak...@gmail.com>
Date: 10/08/2018 18:46 (GMT+02:00)
To: Aki Tuomi 
Subject: Re: dying on osx

I did find that page and tried a few things there. My config has all of
the settings there except 3:

mail_access_groups = mail
mbox_read_locks = fcntl
mbox_write_locks = fcntl

I add them to my config, restart and get the same abort

20180810-103849 imap(mkm)<79213>: Fatal:
setgroups(mail,505) failed: Too many extra groups

I've tried numerous other settings as well.

Thanks for any further advice

Mike


On 8/10/18 08:45, Aki Tuomi wrote:
> Can you try this config and report back?
>
> 
https://superuser.com/questions/957272/dotlock-permissions-problems-with-dovecot-and-os-x-10-10-3

>
> Aki
>
>> On 10 August 2018 at 16:39 Mike Makuch <1mikemak...@gmail.com> wrote:
>>
>>
>> OSX 10.13.6 High Sierra, dovecot 2.3.2.1
>>
>> dovecot starts up and runs but dies as soon as my mail client makes a
>> request with log and config below.
>>
>> And advice appreciated.
>>
>> Thanks
>>
>> Mike
>>
>>
>>
>> 20180810-083730 auth: Debug: auth client connected (pid=77432)
>>
>> 20180810-083730 auth: Debug: client in: AUTH    1 PLAIN
>> service=imap    secured    session=xo1p2BRzZNd/AAAB lip=127.0.0.1
>> rip=127.0.0.1    lport=143    rport=55140
>> 20180810-083730 auth: Debug: client passdb out: CONT    1
>> 20180810-083730 auth: Debug: client in: CONT    1 AG1rbQBta20xMjM=
>> (previous base64 data may contain sensitive data)
>> 20180810-083730 auth: Debug: 
static(mkm,127.0.0.1,):

>> lookup
>> 20180810-083730 auth: Debug: client passdb out: OK 1 user=mkm
>> host=localhost    nopasswd=y
>> 20180810-083730 auth: Debug: master in: REQUEST 4201906177 77432
>> 1    b8126b4b71be2959fc7716888eccc566 session_pid=77433
>> request_auth_token
>> 20180810-083730 auth-worker(77426): Debug:
>>

Re: dying on osx

2018-08-10 Thread Mike Makuch
Ok I added the two users _dovecot & _dovenull to mail group, still get 
same error "Too many extra groups"



# grep mail /etc/group /usr/local/etc/dovecot/dovecot.conf
/etc/group:mail:*:6:_teamsserver,_dovecot,_dovenull
/etc/group:_mailman:*:78:
/usr/local/etc/dovecot/dovecot.conf:mail_debug = yes
/usr/local/etc/dovecot/dovecot.conf:mail_gid = mail
/usr/local/etc/dovecot/dovecot.conf:mail_location = 
mbox:~/Mail:INBOX=/var/mail/%u

/usr/local/etc/dovecot/dovecot.conf:mail_privileged_group = mail
/usr/local/etc/dovecot/dovecot.conf:mail_access_groups = mail
/usr/local/etc/dovecot/dovecot.conf:mail_uid = _dovecot

20180810-113132 imap(mkm)<68466>: Fatal: 
setgroups(mail,505) failed: Too many extra groups


Thanks
Mike



On 8/10/18 11:08, Mike Makuch wrote:



$ grep dove /etc/passwd /etc/group
/etc/passwd:_dovecot:*:214:6:Dovecot 
Administrator:/var/empty:/usr/bin/false
/etc/passwd:_dovenull:*:227:227:Dovecot 
Authentication:/var/empty:/usr/bin/false

/etc/group:certusers:*:29:root,_jabber,_postfix,_cyrus,_calendar,_dovecot
/etc/group:_dovenull:*:227:


I'm trying to build on osx so I can try to do some debugging. The 
INSTALL.md says to do:



$ more INSTALL.md
Build Instructions
==

For most people, the usual:

```
./configure
make
sudo make install
```

But there is no configure file. How would I generate the configure 
file? Is it generated? Been a long time since I've done open source C 
code..


Thanks

Mike


On 8/10/18 11:04, Aki Tuomi wrote:

Is the user member of mail group?



---
Aki Tuomi
Dovecot oy

 Original message 
From: Mike Makuch <1mikemak...@gmail.com>
Date: 10/08/2018 19:02 (GMT+02:00)
To: Aki Tuomi 
Cc: dovecot@dovecot.org
Subject: Re: dying on osx

Maybe an old problem that has resurfaced???

https://bugzilla.samba.org/show_bug.cgi?id=8773

Mike



On 8/10/18 10:54, Aki Tuomi wrote:

I have to see if this is reproducible outside mac.



---
Aki Tuomi
Dovecot oy

---- Original message 
From: Mike Makuch <1mikemak...@gmail.com>
Date: 10/08/2018 18:46 (GMT+02:00)
To: Aki Tuomi 
Subject: Re: dying on osx

I did find that page and tried a few things there. My config has all of
the settings there except 3:

mail_access_groups = mail
mbox_read_locks = fcntl
mbox_write_locks = fcntl

I add them to my config, restart and get the same abort

20180810-103849 imap(mkm)<79213>: Fatal:
setgroups(mail,505) failed: Too many extra groups

I've tried numerous other settings as well.

Thanks for any further advice

Mike


On 8/10/18 08:45, Aki Tuomi wrote:
> Can you try this config and report back?
>
> 
https://superuser.com/questions/957272/dotlock-permissions-problems-with-dovecot-and-os-x-10-10-3

>
> Aki
>
>> On 10 August 2018 at 16:39 Mike Makuch <1mikemak...@gmail.com> wrote:
>>
>>
>> OSX 10.13.6 High Sierra, dovecot 2.3.2.1
>>
>> dovecot starts up and runs but dies as soon as my mail client makes a
>> request with log and config below.
>>
>> And advice appreciated.
>>
>> Thanks
>>
>> Mike
>>
>>
>>
>> 20180810-083730 auth: Debug: auth client connected (pid=77432)
>>
>> 20180810-083730 auth: Debug: client in: AUTH    1 PLAIN
>> service=imap    secured    session=xo1p2BRzZNd/AAAB lip=127.0.0.1
>> rip=127.0.0.1    lport=143    rport=55140
>> 20180810-083730 auth: Debug: client passdb out: CONT    1
>> 20180810-083730 auth: Debug: client in: CONT    1 AG1rbQBta20xMjM=
>> (previous base64 data may contain sensitive data)
>> 20180810-083730 auth: Debug: 
static(mkm,127.0.0.1,):

>> lookup
>> 20180810-083730 auth: Debug: client passdb out: OK 1 user=mkm
>> host=localhost    nopasswd=y
>> 20180810-083730 auth: Debug: master in: REQUEST 4201906177 77432
>> 1    b8126b4b71be2959fc7716888eccc566 session_pid=77433
>> request_auth_token
>> 20180810-083730 auth-worker(77426): Debug:
>> passwd(mkm,127.0.0.1,): lookup
>> 20180810-083730 auth: Debug: master userdb out: USER 4201906177
>> mkm    system_groups_user=mkm    uid=503 gid=20 home=/Users/mkm
>> auth_token=4d2bb44168df3d63e4e1bb352e59de632bc7da49
>> 20180810-083730 imap-login: Info: Login: user=, method=PLAIN,
>> rip=127.0.0.1, lip=127.0.0.1, mpid=77433, secured,
>> session=
>> 20180810-083730 imap(mkm)<77433>: Fatal:
>> setgroups(505) failed: Too many extra groups
>>
>> # doveconf -n
>> # 2.3.2.1 (0719df592): /usr/local/etc/dovecot/dovecot.conf
>> # OS: Darwin 17.7.0 x86_64
>> # Hostname: pine
>> auth_debug = yes
>> auth_debug_passwords = yes
>> default_internal_user = _dovecot
>> default_login_user = _dovenull
>> disable_plaintext_auth = no
>> listen = 127.0.0.1
>> log_path = /var/log/dovecot
>> log_

Re: dying on osx

2018-08-10 Thread Mike Makuch
I found and tried this work around on the man page: 
https://www.unix.com/man-page/all/5/ngroups_max/ but I still get the 
same "Too many extra groups" error even when I start dovecot with the 
above program to limit the # of groups. I suspect that dovecot is adding 
a number of groups when it starts up.


I've hacked a work around to get it working for me on my laptop:

diff --git a/src/lib/restrict-access.c b/src/lib/restrict-access.c

@@ -224,7 +224,12 @@ static void fix_groups_list(const struct 
restrict_access_settings *set,


-    if (setgroups(gid_count, gid_list) < 0) {

+    if (setgroups(gid_count > NGROUPS_MAX ? 16 : gid_count, gid_list) < 
0) {

     if (errno == EINVAL) {
         i_fatal("setgroups(%s) failed: Too many extra groups",
             set->extra_groups == NULL ? "" :

and this works.

I'm not sure what the right solution is for a PR. Any suggestions?

Thanks

Mike



On 8/10/18 11:04, Aki Tuomi wrote:

Is the user member of mail group?



---
Aki Tuomi
Dovecot oy

 Original message 
From: Mike Makuch <1mikemak...@gmail.com>
Date: 10/08/2018 19:02 (GMT+02:00)
To: Aki Tuomi 
Cc: dovecot@dovecot.org
Subject: Re: dying on osx

Maybe an old problem that has resurfaced???

https://bugzilla.samba.org/show_bug.cgi?id=8773

Mike



On 8/10/18 10:54, Aki Tuomi wrote:

I have to see if this is reproducible outside mac.



---
Aki Tuomi
Dovecot oy

 Original message 
From: Mike Makuch <1mikemak...@gmail.com>
Date: 10/08/2018 18:46 (GMT+02:00)
To: Aki Tuomi 
Subject: Re: dying on osx

I did find that page and tried a few things there. My config has all of
the settings there except 3:

mail_access_groups = mail
mbox_read_locks = fcntl
mbox_write_locks = fcntl

I add them to my config, restart and get the same abort

20180810-103849 imap(mkm)<79213>: Fatal:
setgroups(mail,505) failed: Too many extra groups

I've tried numerous other settings as well.

Thanks for any further advice

Mike


On 8/10/18 08:45, Aki Tuomi wrote:
> Can you try this config and report back?
>
> 
https://superuser.com/questions/957272/dotlock-permissions-problems-with-dovecot-and-os-x-10-10-3

>
> Aki
>
>> On 10 August 2018 at 16:39 Mike Makuch <1mikemak...@gmail.com> wrote:
>>
>>
>> OSX 10.13.6 High Sierra, dovecot 2.3.2.1
>>
>> dovecot starts up and runs but dies as soon as my mail client makes a
>> request with log and config below.
>>
>> And advice appreciated.
>>
>> Thanks
>>
>> Mike
>>
>>
>>
>> 20180810-083730 auth: Debug: auth client connected (pid=77432)
>>
>> 20180810-083730 auth: Debug: client in: AUTH    1 PLAIN
>> service=imap    secured    session=xo1p2BRzZNd/AAAB lip=127.0.0.1
>> rip=127.0.0.1    lport=143    rport=55140
>> 20180810-083730 auth: Debug: client passdb out: CONT 1
>> 20180810-083730 auth: Debug: client in: CONT    1 AG1rbQBta20xMjM=
>> (previous base64 data may contain sensitive data)
>> 20180810-083730 auth: Debug: static(mkm,127.0.0.1,):
>> lookup
>> 20180810-083730 auth: Debug: client passdb out: OK    1 user=mkm
>> host=localhost    nopasswd=y
>> 20180810-083730 auth: Debug: master in: REQUEST 4201906177 77432
>> 1    b8126b4b71be2959fc7716888eccc566 session_pid=77433
>> request_auth_token
>> 20180810-083730 auth-worker(77426): Debug:
>> passwd(mkm,127.0.0.1,): lookup
>> 20180810-083730 auth: Debug: master userdb out: USER 4201906177
>> mkm    system_groups_user=mkm    uid=503 gid=20 home=/Users/mkm
>> auth_token=4d2bb44168df3d63e4e1bb352e59de632bc7da49
>> 20180810-083730 imap-login: Info: Login: user=, method=PLAIN,
>> rip=127.0.0.1, lip=127.0.0.1, mpid=77433, secured,
>> session=
>> 20180810-083730 imap(mkm)<77433>: Fatal:
>> setgroups(505) failed: Too many extra groups
>>
>> # doveconf -n
>> # 2.3.2.1 (0719df592): /usr/local/etc/dovecot/dovecot.conf
>> # OS: Darwin 17.7.0 x86_64
>> # Hostname: pine
>> auth_debug = yes
>> auth_debug_passwords = yes
>> default_internal_user = _dovecot
>> default_login_user = _dovenull
>> disable_plaintext_auth = no
>> listen = 127.0.0.1
>> log_path = /var/log/dovecot
>> log_timestamp = "%Y%m%d-%H%M%S "
>> mail_debug = yes
>> mail_gid = staff
>> mail_location = mbox:~/Mail:INBOX=/var/mail/%u
>> mail_privileged_group = mail
>> mail_uid = _dovecot
>> passdb {
>>     args = password=*** host=localhost nopasswd=y
>>     driver = static
>> }
>> passdb {
>>     args = login
>>     driver = pam
>> }
>> protocols = imap
>> service auth {
>>     user = root
>> }
>> service imap-login {
>>     inet_listener imap {
>>       address = *
>>       port = 143
>>     }
>> }
>> ssl = no
>> userdb {
>>     driver = passwd
>> }
>>
>>







Re: dovecot and postfix, help?

2018-08-19 Thread Mike Makuch
One tip: for checking whether or not you have access to your vps @ 
host:port you ought to use netcat or telnet from your localhost:


https://www.digitalocean.com/community/tutorials/how-to-use-netcat-to-establish-and-test-tcp-and-udp-connections-on-a-vps

I frequently use telnet since you can also type in the protocol to a 
server (assuming the server expects ascii) and get a response out of it. 
E.g.


Type:
    $ telnet xyzzy.com 80
Server response:
Trying 104.31.88.30...
    Connected to xyzzy.com.
    Escape character is '^]'.
Type:
    GET / HTTP/1.0
Server response:
    
    
        XYZZY
        
        content="width=device-width,initial-scale=1,maximum-scale=1" />

    
    
      You are in a twisty maze of passages, all alike.
      [snip]
    

And yes in this case "curl" would be more a appropriate utility (for 
http) but not for other protocols that curl doesn't support.


If you telnet to a port that isn't opened and being listened on:

$ telnet localhost 4321
Trying ::1...
telnet: connect to address ::1: Connection refused
Trying 127.0.0.1...
telnet: connect to address 127.0.0.1: Connection refused
Trying fe80::1...
telnet: connect to address fe80::1: Connection refused
telnet: Unable to connect to remote host

Good day
Mike





On 8/17/18 18:05, Christy S wrote:

Hi all,


First a disclaimer. I have played with linux off and on for years, but 
this is my first time trying to run a server completely on my own from 
start to finish, well it's on a vps, but still. I'm pretty techie, but 
a lot of this stuff is new to me, so I apologize for any *duh!* 
questions. That said, I've so far installed dovecot, postfix, 
wordpress, and related programs mostly successfully by following 
tutorials. I say mostly successfully, because I'm having a really hard 
time trying to get dovecot and postfix to behave together, and I'm 
about at the end of what I know how to find on google.



If you're still with me and not groaning at yet another newbie asking 
wtf did I do wrong questions, thank you! My basic setup is running 
ubuntu 18 with up to date dovecot and postfix. Sasl is installed, and 
I'm using a custom domain with all records successfully pointing to 
the VPS.



As I mentioned, I've been following tutorials. My goal is to have a 
mail server which can send and receive emails using this custom domain 
both from the shell and, much more often, from my primary computer 
using thunderbird. As there will likely only be two of us using this, 
I'm completely fine with the setup using mailboxes that actually have 
linux accounts. I'm also using maildir as the mailbox type. 
Furthermore, I want to make sure to use ssl on any mail connections.. 
Normal passwords but ssl being used.



So, following one tutorial I set up postfix and dovecot, then went to 
test it. The result was that while on the shell, I could send email to 
my gmail account from the domain and receive it just fine. I could 
also send mail from my gmail account to the domain and receive it on 
the shel. I even managed to get imap to work, so I could receive 
domain emails in thunderbird, after playing around with tb's settings. 
However, if using tb I attempted to send an email using the custom 
domain, smtp failed to connect.



I verified with my VPS provider that no, they do not block port 25, 
465 or 587. I also verified that at&t, my home ISP, does not block 
outgoing smtp traffic, considering I am using google's for my gmail 
account. After hitting google again, I realized two things. One, for 
some reason port 25 never got opened on UFW, so I fixed that. Second, 
for some reason in all the stuff I did, postfix never got configured 
to use SSL.



I found yet another tutorial, and ran through it to set up SSL with 
postfix. However, in doing this I had to change a path for sasl, only 
to find out later that doing that broke dovecot! Imap completely and 
utterly stopped behaving.



Back to google again, and this time I found something a bit more up to 
date which explained how to interconnect postfix and dovecot. It goes 
through using mysql too, but I don't need that, so I skipped that 
part. Changed the sasl path back to what it should be, told dovecot 
and postfix to talk to each other and... Nope, still nothing.



I saw a warning that I should not use different certificates for 
postfix and dovecot, so I told dovecot to look at the smtpd 
certificate that I made. Not sure if that's what's breaking this or 
something completely different, as I'm also brand new to the ssl 
certificate creation process. So, here's the current status of using 
thunderbird with my domain.



mail sent from gmail to new domain, never comes back in thunderbird 
but doesn't bounce, either.


Mail sent via thunderbird to gmail from domain, works, but shows up as 
from my gmail domain as well, which makes me 

no shared cipher openssl

2020-11-15 Thread Mike Schroeder
CentOS 7
Dovecot 2.2.36

Nov 14 07:13:08 mail dovecot: pop3-login: Disconnected (no auth attempts in
0 secs):
user=<>, rip=73.0.0.0, lip=192.64.118.242, TLS handshaking: SSL_accept()
failed:
error:1408A0C1:SSL routines:ssl3_get_client_hello:no shared cipher,
session=<>

Was working fine for over a year, until the cert expired and I replaced it.
I've tried the good cert I have for https and I used the Dovecot.org script
to generate a self-signed certificate.

10-ssl.conf
## SSL settings
#ssl = required
ssl = yes
#ssl = no
ssl_cert = 

Problem enabling the mail_log plugin

2021-02-07 Thread Mike Quigley
I need to track some issues with deleted messages so I have been trying 
to set up the mail_log plugin.  I have Dovecot v2..27 running on Debian 
9.  I have configured /etc/dovecot/conf.d/10-logging.conf, 20-imap.conf, 
and 20-lmtp.conf and restarted dovecot, but I see so difference in 
/var/log/mail.info & /var/log/syslog when I delete a message from my 
Inbox in Roundcube.  Here is the abbreviated output from doveconf -n:


# 2.2.27 (): /etc/dovecot/dovecot.conf
# Pigeonhole version 0.4.16 ()
# OS: Linux 4.9.0-14-amd64 x86_64 Debian 9.13 ext4

plugin {
mail_log_events = delete undelete mailbox_delete mailbox_rename
mail_log_fields = uid box msgid size
sieve = ~/.dovecot.sieve
sieve_after = /etc/dovecot/sieve-after
sieve_dir = ~/sieve
}

protocols = " imap lmtp sieve pop3"

protocol lmtp {
mail_plugins = " sieve notify mail_log"
}

protocol imap {
mail_max_userip_connections = 50
mail_plugins = " notify mail_log"
}

What am I missing?

Re: Problem enabling the mail_log plugin

2021-02-09 Thread Mike Quigley
I looked at the Trash messages on the Server (which is using Maildir) 
and they are flagged as :2,S (Seen) but not T (Trash). So it looks like 
when Roundcube copies them to Trash and expunges the original, it 
doesn't set the Trash flag on the message.  If I manually delete the 
message from the Trash folder, then RC does set the Trash flag and that 
action will be logged to my Dovecot logs. I did not set the expunge & 
copy options in mail_log_events because I didn't want to fill up the 
logs with all that additional logging, thinking that delete would get me 
what I was looking for.  Thanks for pointing me in the right direction.

--

On 2021-02-09 3:44 am, Yassine Chaouche wrote:


Le 2/9/21 à 11:41 AM, Yassine Chaouche a écrit :


I have expunge in mail_log_events

mail_log_events = delete undelete expunge copy mailbox_delete 
mailbox_rename


Yassine

Oh yes and copy, because when you delete mail in roundcube it actually
copies it to the trash then expunge it from where it was, so you
should look after these two

Yassine.


Re: Problem enabling the mail_log plugin

2021-02-09 Thread Mike Quigley
The default Debian 8 or 9 install of Dovecot duplicates Dovecot logging 
in both /var/log/mail.info & /var/log/syslog.  This server was 
originally setup with v8 and later upgraded to v9.

--

On 2021-02-09 3:46 am, Yassine Chaouche wrote:


Le 2/8/21 à 5:03 AM, Mike Quigley a écrit :
I see so difference in /var/log/mail.info & /var/log/syslog


Did you configure it to use syslog ? my config puts dovecot logs in 
/var/log/dovecot


Yassine.


Undefined symbol using fts-flatcurve with repo.dovecot.org packages

2021-12-18 Thread Mike Acar


Hi,

I'm trying to use dovecot-fts-flatcurve with dovecot 2:2.3.15-1+debian10
from repo.dovecot.org, but it looks like the package doesn't include
ICU, which fts-flatcurve requires.

After compilation and installation, I get an error from doveadm:

doveadm fts-flatcurve stats -u user INBOX
Fatal: Couldn't load required plugin
/usr/lib/dovecot/modules/lib21_fts_flatcurve_plugin.so: dlopen() failed:
/usr/lib/dovecot/modules/lib21_fts_flatcurve_plugin.so: undefined
symbol: _ZTIN6icu_638ByteSinkE

Unmangled, I think that's this symbol:

U typeinfo for icu_63::ByteSink

I checked the rules file from dovecot_2.3.15-1%2Bdebian10.debian.tar.xz
and it appears that configure doesn't include --with-icu.

Is there a plan to include this in a future release?

-- 
  | Mike Acar |    | mike at waspfactory dot org |


Re: JMAP support in Dovecot

2020-01-22 Thread Mike Gao
Hi,

Any news for jmap Support in Dovecot?

Thanks,
Mike


public folder subscriptions sync issue with ldap user/group in dovecot-acl

2016-12-13 Thread Mike Fröhner

Hello people,

I am having an issue with 'doveadm sync'. I am currently trying to have 
two dovecots behind an haproxy (works fine). Therefore I configured 
these two dovecot server (imap-1/imap-2) to sync throught dsync. This 
works just partly. The sync of the maiboxes is fine, but the sync of the 
subscriptions file just works partly. It works for private folder 
subscription, but not completly for public folder subscription. I found 
two issues, if I am using LDAP (user/groups) in dovecot ACLs.


1. I would like to subscribe 2 public folder (public/test/test1 and 
public/test/test2).


My user (ldaptestuser) is an ldap user and this user is member of the 
ldap group (ldaptestgroup) which does have all dovecot-acl rights on 
these folders.


imap-1 # cat /opt/mail/_public/publictest/.test*/dovecot-acl
group=ldaptestgroup akxeilprwts
group=ldaptestgroup akxeilprwts

I am now connecting with my mail client to imap-1 (throught haproxy) and 
the subscription to this folder works. The file which is written looks like:


imap-1 # cat /opt/mail/ldaptestuser/Mails/subscriptions
Sent
publictest/test/test1
publictest/test/test2

Now I am awaiting the synch to imap-2, but the file which it written 
looks like:


imap-2 # cat /opt/mail/ldaptestuser/Mails/subscriptions
Sent

If I modify the dovecot-acl for .test1 to

imap-1 # cat /opt/mail/_public/publictest/.test1/dovecot-acl
group=ldaptestgroup akxeilprwts
user=ldaptestuser akxeilprwts

and execute the subscription again - the synced file looks like:

imap-2 # cat /opt/mail/ldaptestuser/Mails/subscriptions
Sent
publictest/test/test1

The subscription of public folder test2 will also been synced, if I add 
my ldaptestuser to the acl file for this folder.


2. Another issue is to unsubscribe a public folder. If I unsubscribe 
folder test1, it is written to subscriptions file on the imap where I am 
connected, but it is NOT synced even if my user and group are configured 
at the dovecot-acl file. If I then unsubscribe a not public folder (like 
Sent), the former unsubscribed folder test1 is (faulty) subscribed 
again. But both imap do have the same subscriptions for my ldaptestuser 
user.


I do have the behavior with dovecot-2.2.26 and dovecot-2.2.27 on 
CentOS-7 (selinux disabled).


If you need more information like the dovecot -n or some other stuff 
give me a short notice.


Mike;


Re: public folder subscriptions sync issue with ldap user/group in dovecot-acl

2016-12-14 Thread Mike Fröhner
I made some additional tests and found that also local unix groups are 
not working in replacement for my ldap groups as discribed below.


Do groups in dovecot-acl intendedly not work?

On 12/13/2016 03:47 PM, Mike Fröhner wrote:

Hello people,

I am having an issue with 'doveadm sync'. I am currently trying to have
two dovecots behind an haproxy (works fine). Therefore I configured
these two dovecot server (imap-1/imap-2) to sync throught dsync. This
works just partly. The sync of the maiboxes is fine, but the sync of the
subscriptions file just works partly. It works for private folder
subscription, but not completly for public folder subscription. I found
two issues, if I am using LDAP (user/groups) in dovecot ACLs.

1. I would like to subscribe 2 public folder (public/test/test1 and
public/test/test2).

My user (ldaptestuser) is an ldap user and this user is member of the
ldap group (ldaptestgroup) which does have all dovecot-acl rights on
these folders.

imap-1 # cat /opt/mail/_public/publictest/.test*/dovecot-acl
group=ldaptestgroup akxeilprwts
group=ldaptestgroup akxeilprwts

I am now connecting with my mail client to imap-1 (throught haproxy) and
the subscription to this folder works. The file which is written looks
like:

imap-1 # cat /opt/mail/ldaptestuser/Mails/subscriptions
Sent
publictest/test/test1
publictest/test/test2

Now I am awaiting the synch to imap-2, but the file which it written
looks like:

imap-2 # cat /opt/mail/ldaptestuser/Mails/subscriptions
Sent

If I modify the dovecot-acl for .test1 to

imap-1 # cat /opt/mail/_public/publictest/.test1/dovecot-acl
group=ldaptestgroup akxeilprwts
user=ldaptestuser akxeilprwts

and execute the subscription again - the synced file looks like:

imap-2 # cat /opt/mail/ldaptestuser/Mails/subscriptions
Sent
publictest/test/test1

The subscription of public folder test2 will also been synced, if I add
my ldaptestuser to the acl file for this folder.

2. Another issue is to unsubscribe a public folder. If I unsubscribe
folder test1, it is written to subscriptions file on the imap where I am
connected, but it is NOT synced even if my user and group are configured
at the dovecot-acl file. If I then unsubscribe a not public folder (like
Sent), the former unsubscribed folder test1 is (faulty) subscribed
again. But both imap do have the same subscriptions for my ldaptestuser
user.

I do have the behavior with dovecot-2.2.26 and dovecot-2.2.27 on
CentOS-7 (selinux disabled).

If you need more information like the dovecot -n or some other stuff
give me a short notice.

Mike;



Re: public folder subscriptions sync issue with ldap user/group in dovecot-acl

2016-12-16 Thread Mike Fröhner

Thanks for your reply Timo.

On 12/14/2016 06:40 PM, Timo Sirainen wrote:

On 14 Dec 2016, at 11.16, Mike Fröhner mailto:mikefroeh...@gmx.de>> wrote:


I made some additional tests and found that also local unix groups are
not working in replacement for my ldap groups as discribed below.

Do groups in dovecot-acl intendedly not work?


http://wiki2.dovecot.org/ACL -> ACL groups support works by returning a
comma-separated acl_groups extra field from userdb, which contains all
the groups the user belongs to. User's UNIX groups have no effect on
ACLs (you can "enable" them by using a special post-login script).


I think I have configured the userdb right, because the debug log tells 
me this:


imap-1 dovecot: imap(ldaptestuser): Debug: acl: acl username = ldaptestuser
imap-1 dovecot: imap(ldaptestuser): Debug: acl: owner = 1
imap-1 dovecot: imap(ldaptestuser): Debug: acl: group added: mailusers
imap-1 dovecot: imap(ldaptestuser): Debug: acl: group added: ldaptestgroup





On 12/13/2016 03:47 PM, Mike Fröhner wrote:

Hello people,

I am having an issue with 'doveadm sync'. I am currently trying to have
two dovecots behind an haproxy (works fine). Therefore I configured
these two dovecot server (imap-1/imap-2) to sync throught dsync. This
works just partly. The sync of the maiboxes is fine, but the sync of the
subscriptions file just works partly. It works for private folder
subscription, but not completly for public folder subscription. I found
two issues, if I am using LDAP (user/groups) in dovecot ACLs.

1. I would like to subscribe 2 public folder (public/test/test1 and
public/test/test2).

My user (ldaptestuser) is an ldap user and this user is member of the
ldap group (ldaptestgroup) which does have all dovecot-acl rights on
these folders.

imap-1 # cat /opt/mail/_public/publictest/.test*/dovecot-acl
group=ldaptestgroup akxeilprwts
group=ldaptestgroup akxeilprwts

I am now connecting with my mail client to imap-1 (throught haproxy) and
the subscription to this folder works. The file which is written looks
like:

imap-1 # cat /opt/mail/ldaptestuser/Mails/subscriptions
Sent
publictest/test/test1
publictest/test/test2

Now I am awaiting the synch to imap-2, but the file which it written
looks like:

imap-2 # cat /opt/mail/ldaptestuser/Mails/subscriptions
Sent

If I modify the dovecot-acl for .test1 to

imap-1 # cat /opt/mail/_public/publictest/.test1/dovecot-acl
group=ldaptestgroup akxeilprwts
user=ldaptestuser akxeilprwts

and execute the subscription again - the synced file looks like:

imap-2 # cat /opt/mail/ldaptestuser/Mails/subscriptions
Sent
publictest/test/test1

The subscription of public folder test2 will also been synced, if I add
my ldaptestuser to the acl file for this folder.

2. Another issue is to unsubscribe a public folder. If I unsubscribe
folder test1, it is written to subscriptions file on the imap where I am
connected, but it is NOT synced even if my user and group are configured
at the dovecot-acl file. If I then unsubscribe a not public folder (like
Sent), the former unsubscribed folder test1 is (faulty) subscribed
again. But both imap do have the same subscriptions for my ldaptestuser
user.

I do have the behavior with dovecot-2.2.26 and dovecot-2.2.27 on
CentOS-7 (selinux disabled).

If you need more information like the dovecot -n or some other stuff
give me a short notice.

Mike;





Re: public folder subscriptions sync issue with ldap user/group in dovecot-acl

2016-12-16 Thread Mike Fröhner

Hi again,

here some more debugs:

On 12/16/2016 03:25 PM, Mike Fröhner wrote:

Thanks for your reply Timo.

On 12/14/2016 06:40 PM, Timo Sirainen wrote:

On 14 Dec 2016, at 11.16, Mike Fröhner mailto:mikefroeh...@gmx.de>> wrote:


I made some additional tests and found that also local unix groups are
not working in replacement for my ldap groups as discribed below.

Do groups in dovecot-acl intendedly not work?


http://wiki2.dovecot.org/ACL -> ACL groups support works by returning a
comma-separated acl_groups extra field from userdb, which contains all
the groups the user belongs to. User's UNIX groups have no effect on
ACLs (you can "enable" them by using a special post-login script).


I think I have configured the userdb right, because the debug log tells
me this:

imap-1 dovecot: imap(ldaptestuser): Debug: acl: acl username = ldaptestuser
imap-1 dovecot: imap(ldaptestuser): Debug: acl: owner = 1
imap-1 dovecot: imap(ldaptestuser): Debug: acl: group added: mailusers
imap-1 dovecot: imap(ldaptestuser): Debug: acl: group added: ldaptestgroup


Well, the IMAP debug lists/adds the groups, but not the doveadm:

Dec 16 16:36:12 imap-1 dovecot: doveadm(ldaptestuser): Debug: auth PASS 
input: user=ldaptestuser
Dec 16 16:36:12 imap-1 dovecot: doveadm(ldaptestuser): Debug: auth USER 
input: ldaptestuser home=/opt/mail/ldaptestuser 
mail=maildir:/opt/mail/ldaptestuser/Mails gid=991 uid=834603987
Dec 16 16:36:12 imap-1 dovecot: doveadm(ldaptestuser): Debug: Added 
userdb setting: mail=maildir:/opt/mail/ldaptestuser/Mails
Dec 16 16:36:12 imap-1 dovecot: doveadm(ldaptestuser): Debug: Effective 
uid=834603987, gid=991, home=/opt/mail/ldaptestuser




Dec 16 16:36:12 imap-1 dovecot: doveadm(ldaptestuser): Debug: Namespace 
public-test: type=public, prefix=public/test/, sep=/, inbox=no, 
hidden=no, list=yes, subscriptions=no 
location=maildir:/opt/mail/_public/test
Dec 16 16:36:12 imap-1 dovecot: doveadm(ldaptestuser): Debug: maildir++: 
root=/opt/mail/_public/test, index=, indexpvt=, control=, inbox=, alt=
Dec 16 16:36:12 imap-1 dovecot: doveadm(ldaptestuser): Debug: acl: 
initializing backend with data: vfile
Dec 16 16:36:12 imap-1 dovecot: doveadm(ldaptestuser): Debug: acl: acl 
username = ldaptestuser

Dec 16 16:36:12 imap-1 dovecot: doveadm(ldaptestuser): Debug: acl: owner = 0
Dec 16 16:36:12 imap-1 dovecot: doveadm(ldaptestuser): Debug: acl vfile: 
Global ACLs disabled


The debug output equals on server imap-1 and imap-2.







On 12/13/2016 03:47 PM, Mike Fröhner wrote:

Hello people,

I am having an issue with 'doveadm sync'. I am currently trying to have
two dovecots behind an haproxy (works fine). Therefore I configured
these two dovecot server (imap-1/imap-2) to sync throught dsync. This
works just partly. The sync of the maiboxes is fine, but the sync of
the
subscriptions file just works partly. It works for private folder
subscription, but not completly for public folder subscription. I found
two issues, if I am using LDAP (user/groups) in dovecot ACLs.

1. I would like to subscribe 2 public folder (public/test/test1 and
public/test/test2).

My user (ldaptestuser) is an ldap user and this user is member of the
ldap group (ldaptestgroup) which does have all dovecot-acl rights on
these folders.

imap-1 # cat /opt/mail/_public/publictest/.test*/dovecot-acl
group=ldaptestgroup akxeilprwts
group=ldaptestgroup akxeilprwts

I am now connecting with my mail client to imap-1 (throught haproxy)
and
the subscription to this folder works. The file which is written looks
like:

imap-1 # cat /opt/mail/ldaptestuser/Mails/subscriptions
Sent
publictest/test/test1
publictest/test/test2

Now I am awaiting the synch to imap-2, but the file which it written
looks like:

imap-2 # cat /opt/mail/ldaptestuser/Mails/subscriptions
Sent

If I modify the dovecot-acl for .test1 to

imap-1 # cat /opt/mail/_public/publictest/.test1/dovecot-acl
group=ldaptestgroup akxeilprwts
user=ldaptestuser akxeilprwts

and execute the subscription again - the synced file looks like:

imap-2 # cat /opt/mail/ldaptestuser/Mails/subscriptions
Sent
publictest/test/test1

The subscription of public folder test2 will also been synced, if I add
my ldaptestuser to the acl file for this folder.

2. Another issue is to unsubscribe a public folder. If I unsubscribe
folder test1, it is written to subscriptions file on the imap where
I am
connected, but it is NOT synced even if my user and group are
configured
at the dovecot-acl file. If I then unsubscribe a not public folder
(like
Sent), the former unsubscribed folder test1 is (faulty) subscribed
again. But both imap do have the same subscriptions for my ldaptestuser
user.

I do have the behavior with dovecot-2.2.26 and dovecot-2.2.27 on
CentOS-7 (selinux disabled).

If you need more information like the dovecot -n or some other stuff
give me a short notice.

Mike;







dsync for subscription on public/shared folder

2016-12-22 Thread Mike Fröhner

Hello,

I already wrote regarding that, but maybe it sounded too complex. I will 
write it a bit softer now.


The replication through dsnyc works perfectly with one exception. I am 
having an issue with the replication of the subscriptions file on shared 
folder.


We have a public mailbox defined:

namespace public-test {
  location = maildir:/opt/mail/_public/test
  prefix = public/test/
  separator = /
  subscriptions = no
  type = public
}

There 2 subfolder .Test1 and .Test2 which I would like to subscribe on 
my user "ldaptestuser" which is part of the group "ldaptestgroup"


The dovecot-acl file on /opt/mail/_public/test and 
/opt/mail/_public/test/.Test{1,2} are the same and are containing:


group=ldaptestgroup lrwstipekxa

Now if I login through my client (Thunderbird or Roundcubemail) I can 
see the following debug log:


dovecot: imap(ldaptestuser): Debug: acl: acl username = ldaptestuser
dovecot: imap(ldaptestuser): Debug: acl: owner = 0
dovecot: imap(ldaptestuser): Debug: acl: group added: domain users
dovecot: imap(ldaptestuser): Debug: acl: group added: ldaptestgroup
dovecot: imap(ldaptestuser): Debug: acl: group added: all_mailuser

I created one new private folder on the mailbox of my test user and also 
subscribed it. This subscription is successfully replicated.


After that I am trying to subscribe the public folder. I can see the 
folder in my client after I subscribed them. But on the 2nd dovecot 
server the subscription file is not updated.


imap-1 # cat subscription
Private1
public/test/Test1

imap-2 # cat subscription
Private1

The debug log on both dovecot server tells me:
dovecot: doveadm(,ldaptestuser): Debug: Effective uid=834603987, 
gid=991, home=/opt/mail/ldaptestuser
dovecot: doveadm(,ldaptestuser): Debug: acl: No acl_shared_dict 
setting - shared mailbox listing is disabled
dovecot: doveadm(,ldaptestuser): Debug: maildir++: 
root=/opt/mail/_public/test, index=, indexpvt=, control=, inbox=, alt=
dovecot: doveadm(,ldaptestuser): Debug: acl: initializing backend 
with data: vfile

dovecot: doveadm(,ldaptestuser): Debug: acl: acl username = ldaptestuser
dovecot: doveadm(,ldaptestuser): Debug: acl: owner = 0
dovecot: doveadm(,ldaptestuser): Debug: acl vfile: Global ACLs disabled

It looks like the doveadm() cannot find the group or is not 
checking/initalizing the groups.


Anybody any idea if I missconfigured something or is this just a bug? I 
really would appreciate some help.


kind regards,
Mike;


Re: dsync for subscription on public/shared folder

2017-01-08 Thread Mike Fröhner
I can
see the following debug log:

dovecot: imap(ldaptestuser): Debug: acl: acl username = ldaptestuser
dovecot: imap(ldaptestuser): Debug: acl: owner = 0
dovecot: imap(ldaptestuser): Debug: acl: group added: domain users
dovecot: imap(ldaptestuser): Debug: acl: group added: ldaptestgroup
dovecot: imap(ldaptestuser): Debug: acl: group added: all_mailuser

I created one new private folder on the mailbox of my test user and also
subscribed it. This subscription is successfully replicated.

After that I am trying to subscribe the public folder. I can see the
folder in my client after I subscribed them. But on the 2nd dovecot
server the subscription file is not updated.

imap-1 # cat subscription
Private1
public/test/Test1

imap-2 # cat subscription
Private1

The debug log on both dovecot server tells me:
dovecot: doveadm(,ldaptestuser): Debug: Effective uid=834603987,
gid=991, home=/opt/mail/ldaptestuser
dovecot: doveadm(,ldaptestuser): Debug: acl: No acl_shared_dict
setting - shared mailbox listing is disabled
dovecot: doveadm(,ldaptestuser): Debug: maildir++:
root=/opt/mail/_public/test, index=, indexpvt=, control=, inbox=, alt=
dovecot: doveadm(,ldaptestuser): Debug: acl: initializing backend
with data: vfile
dovecot: doveadm(,ldaptestuser): Debug: acl: acl username =
ldaptestuser
dovecot: doveadm(,ldaptestuser): Debug: acl: owner = 0
dovecot: doveadm(,ldaptestuser): Debug: acl vfile: Global ACLs disabled

It looks like the doveadm() cannot find the group or is not
checking/initalizing the groups.

Anybody any idea if I missconfigured something or is this just a bug? I
really would appreciate some help.

kind regards,
Mike;



Re: Replication: Can't unsubscribe from shared mailbox

2017-01-16 Thread Mike Fröhner

Hi Karsten,

I have a similar issue with current 2.2.27 version on CentOS with public 
folder/namespaces on a active/active replication.


I am able to subscribe the public folder on one dovecot, but it is not 
replicated to the 2nd dovecot throught dsync. Everything else is fine 
with dsync, also the replication of the subscription of private/personal 
folder.


Currently I am trying to debug this at the source code, but my C is 
quite dusty.


Mike;

On 01/16/2017 03:19 PM, Karsten Heiken wrote:

Hi all,

I hope it's okay to bump this once after four months.

In the meantime we updated to 2.2.26.0 and our problem still persists:
After unsubscribing from a shared mailbox, the subscription instantly
re-appears.
A pcap was attached to my original mail, in case it has something to do
with dsync:
http://dovecot.org/pipermail/dovecot/2016-September/105419.html

Is anyone on this mailing list using replication in combination with
shared folders?
Does this problem exist for anyone else? I would love to hear from
people who got this working or if anyone else is affected by this.

My original post is at the end of this email; the current doveconf is
also attached.


Thank you very much,

Karsten

# doveconf -n
# 2.2.26.0 (23d1de6): /etc/dovecot/dovecot.conf
# Pigeonhole version 0.4.16 (fed8554)
# OS: Linux 3.16.0-4-amd64 x86_64 Debian 8.6
auth_cache_size = 10 M
auth_cache_ttl = 2 hours
default_vsz_limit = 1 G
dict {
  acl = mysql:/etc/dovecot/dovecot-dict-sql.conf.ext
}
lmtp_rcpt_check_quota = yes
login_trusted_networks = xxx
mail_attribute_dict = file:%h/dovecot-attributes
mail_gid = 
mail_location = mdbox:%h/mdbox
mail_plugins = " zlib quota acl notify replication"
mail_server_admin = mailto:postmaster@xxx
mail_server_comment = xxx
mail_shared_explicit_inbox = yes
mail_uid = 
mailbox_list_index = yes
managesieve_notify_capability = mailto
managesieve_sieve_capability = fileinto reject envelope
encoded-character vacation subaddress comparator-i;ascii-numeric
relational regex imap4flags copy include variables body enotify
environment mailbox date index ihave duplicate mime foreverypart
extracttext imapflags notify
mdbox_rotate_size = 10 M
namespace {
  hidden = no
  ignore_on_failure = no
  inbox = no
  list = children
  location = mdbox:%%h/mdbox:INDEXPVT=%h/shared/%%u
  prefix = shared/%%u/
  separator = /
  subscriptions = no
  type = shared
}
namespace inbox {
  hidden = no
  inbox = yes
  list = yes
  location =
  mailbox 30dTrash {
auto = subscribe
autoexpunge = 30 days
special_use = \Junk
  }
  mailbox Drafts {
auto = subscribe
special_use = \Drafts
  }
  mailbox Sent {
auto = subscribe
special_use = \Sent
  }
  mailbox Trash {
auto = subscribe
special_use = \Trash
  }
  prefix =
  separator = /
  subscriptions = yes
  type = private
}
passdb {
  args = /etc/dovecot/dovecot-ldap.conf.ext
  driver = ldap
}
plugin {
  acl = vfile
  acl_shared_dict = proxy::acl
  mail_replica = tcp:xxx:24245
  quota = dict:User quota::noenforcing:file:%h/dovecot-quota
  quota_grace = 2%%
  quota_rule = *:storage=8G
  quota_status_nouser = DUNNO
  quota_status_overquota = DUNNO
  quota_status_success = DUNNO
  sieve = ~/.dovecot.sieve
  sieve_dir = ~/sieve
  sieve_extensions = +notify +imapflags
  sieve_max_actions = 250
  sieve_max_redirects = 200
  zlib_save = gz
  zlib_save_level = 6
}
postmaster_address = postmaster@xxx
protocols = " imap lmtp sieve pop3 sieve"
replication_dsync_parameters = -d -l 30 -U -N
replication_max_conns = 5
service aggregator {
  fifo_listener replication-notify-fifo {
user = vmail
  }
  unix_listener replication-notify {
user = vmail
  }
}
service auth {
  unix_listener auth-userdb {
group = vmail
user = vmail
  }
}
service dict {
  unix_listener dict {
group = vmail
mode = 0660
user = vmail
  }
}
service doveadm {
  inet_listener {
port = 24245
  }
}
service imap-login {
  process_min_avail = 16
  service_count = 0
}
service imap {
  executable = imap postlogin
  process_limit = 3
}
service lmtp {
  inet_listener lmtp {
port = 24
  }
  vsz_limit = 1 G
}
service managesieve-login {
  inet_listener sieve {
port = 4190
  }
}
service managesieve {
  process_limit = 1024
}
service pop3-login {
  process_min_avail = 4
  service_count = 0
}
service pop3 {
  process_limit = 2500
}
service postlogin {
  executable = script-login -d rawlog /usr/local/bin/dovecot-postlogin.sh
}
service quota-status {
  client_limit = 1
  executable = quota-status -p postfix
  inet_listener {
port = 12340
  }
}
service replicator {
  process_min_avail = 1
  unix_listener replicator-doveadm {
mode = 0600
user = vmail
  }
}
shutdown_clients = no
ssl_cert = 
Hi,

I am running two dovecot servers active/active.
Everything runs pretty great, except for the replication of
subscriptions in a shared namespace.

When I unsubscribe from a folder the subscription instantly
re-appears. The timestamp on the subs

Re: dsync dovecot / Failed connection refused

2017-01-24 Thread Mike Fröhner

Hello,

I might be wrong, but the port which will be used for the replicator 
port is the value of 'doveadm_port' which in your case is 4711.


Mike;

On 01/23/2017 05:58 PM, Thierry wrote:

Dear all,

I am using VMWare and I  have cloned my emails server.
Now I do have two identicals servers, both running the same version of dovecot 
(2.2.13) and imap.
Let's call them: server1.domain.ltd  and server2.domain.ltd.
I would  like to sync both server using dsync.

Dovecot is working well except concerning  the sync.

dsync config server1.domain.ltd

# Enable the replication plugin globally
mail_plugins = $mail_plugins notify replication

# The mail processes need to have access to the replication-notify fifo and 
socket.
service aggregator {
  fifo_listener replication-notify-fifo {
user = vmail
mode = 0666
  }
  unix_listener replication-notify {
user = vmail
mode = 0666
  }
}

# Enable doveadm replicator commands
service replicator {
  unix_listener replicator-doveadm {
mode = 0666
  }
}

# Create a listener for doveadm-server
service doveadm {
  user = vmail
  inet_listener {
port = 12345
  }
}

# configure how many dsyncs can be run in parallel (10 by default)
replication_max_conns = 10

# tell doveadm client to use this port by default
doveadm_port = 4711

#Both the client and the server also need to have a shared secret
doveadm_password = {SHA512-CRYPT}$6$rou
# use tcp:hostname as the dsync target
plugin {
  #mail_replica = tcp:server2.domain.ltd # use doveadm_port
  mail_replica = tcp:server2.domain.ltd:12345 # use port 12345 explicitly
}

service config {
  unix_listener config {
user = vmail
  }
}

***

dsync config server2.domain.ltd

# Enable the replication plugin globally
mail_plugins = $mail_plugins notify replication

# The mail processes need to have access to the replication-notify fifo and 
socket.
service aggregator {
  fifo_listener replication-notify-fifo {
user = vmail
mode = 0666
  }
  unix_listener replication-notify {
user = vmail
mode = 0666
  }
}

# Enable doveadm replicator commands
service replicator {
  unix_listener replicator-doveadm {
mode = 0666
  }
}

# Create a listener for doveadm-server
service doveadm {
  user = vmail
  inet_listener {
port = 12345
  }
}

# configure how many dsyncs can be run in parallel (10 by default)
replication_max_conns = 10

# tell doveadm client to use this port by default
doveadm_port = 4711

#Both the client and the server also need to have a shared secret
doveadm_password = {SHA512-CRYPT}$6$ro.
# use tcp:hostname as the dsync target
plugin {
  #mail_replica = tcp:server1.domain.ltd # use doveadm_port
  mail_replica = tcp:server1.domain.ltd:12345 # use port 12345 explicitly
}

service config {
  unix_listener config {
user = vmail
  }
}

To test both port   I have open on  my both servers port 12345 and 4711 :

Iptables server1: ACCEPT tcp  --  anywhere anywhere 
tcp dpt:4711
  ACCEPT tcp  --  anywhere anywhere 
tcp dpt:12345

Iptables server2: ACCEPT tcp  --  anywhere anywhere 
tcp dpt:4711
  ACCEPT tcp  --  anywhere anywhere 
tcp dpt:12345


doveadm replicator  status '*'
username
priority fast sync full sync failed
us...@domain.ltd
none 00:01:21  11:25:40  y
us...@domain.ltd
none 07:31:16  11:25:41  -
us...@domain.ltd
none 00:01:21  11:25:40  y
us...@domain.ltd
none 11:25:41  11:25:41  -
us...@domain.ltd
none 02:17:03  11:25:41  -
us...@domain.ltd
none 11:25:40  11:25:40  -
us...@domain.ltd
none 00:00:51  11:25:40  y

When  doing, from server1:   "doveadm sync -u us...@domain.ltd 
remote:server2.domain.ltd"

doveadm(us...@domain.ltd): Error: userdb lookup: 
connect(/var/run/dovecot/auth-userdb) failed: Connection refused
doveadm(us...@domain.ltd): Fatal: /var/run/dovecot/auth-userdb: passdb lookup 
failed (to see if user is proxied, because doveadm_port is set)
dsync-local(us...@domain.ltd): Error: read(server2.domain.ltd) failed: EOF 
(version not received)

Thx for your help.




Re: dsync dovecot / Failed connection refused

2017-01-24 Thread Mike Fröhner
Sorry, you are right, I was wrong. I missed you explicit configure the 
port at $mail_replica.


On 01/24/2017 10:45 AM, Thierry wrote:

Hi Mike,

Is  the value of  the 'doveadm_port' if I am choosing: mail_replica =
tcp:server1.domain.ltd   no ?
I might be wrong too ;)

Thx

Le mardi 24 janvier 2017 à 11:41:28, vous écriviez :


Hello,



I might be wrong, but the port which will be used for the replicator
port is the value of 'doveadm_port' which in your case is 4711.



Mike;



On 01/23/2017 05:58 PM, Thierry wrote:

Dear all,

I am using VMWare and I  have cloned my emails server.
Now I do have two identicals servers, both running the same version of dovecot 
(2.2.13) and imap.
Let's call them: server1.domain.ltd  and server2.domain.ltd.
I would  like to sync both server using dsync.

Dovecot is working well except concerning  the sync.

dsync config server1.domain.ltd

# Enable the replication plugin globally
mail_plugins = $mail_plugins notify replication

# The mail processes need to have access to the replication-notify fifo and 
socket.
service aggregator {
  fifo_listener replication-notify-fifo {
user = vmail
mode = 0666
  }
  unix_listener replication-notify {
user = vmail
mode = 0666
  }
}

# Enable doveadm replicator commands
service replicator {
  unix_listener replicator-doveadm {
mode = 0666
  }
}

# Create a listener for doveadm-server
service doveadm {
  user = vmail
  inet_listener {
port = 12345
  }
}

# configure how many dsyncs can be run in parallel (10 by default)
replication_max_conns = 10

# tell doveadm client to use this port by default
doveadm_port = 4711

#Both the client and the server also need to have a shared secret
doveadm_password = {SHA512-CRYPT}$6$rou
# use tcp:hostname as the dsync target
plugin {
  #mail_replica = tcp:server2.domain.ltd # use doveadm_port
  mail_replica = tcp:server2.domain.ltd:12345 # use port 12345 explicitly
}

service config {
  unix_listener config {
user = vmail
  }
}

***

dsync config server2.domain.ltd

# Enable the replication plugin globally
mail_plugins = $mail_plugins notify replication

# The mail processes need to have access to the replication-notify fifo and 
socket.
service aggregator {
  fifo_listener replication-notify-fifo {
user = vmail
mode = 0666
  }
  unix_listener replication-notify {
user = vmail
mode = 0666
  }
}

# Enable doveadm replicator commands
service replicator {
  unix_listener replicator-doveadm {
mode = 0666
  }
}

# Create a listener for doveadm-server
service doveadm {
  user = vmail
  inet_listener {
port = 12345
  }
}

# configure how many dsyncs can be run in parallel (10 by default)
replication_max_conns = 10

# tell doveadm client to use this port by default
doveadm_port = 4711

#Both the client and the server also need to have a shared secret
doveadm_password = {SHA512-CRYPT}$6$ro.
# use tcp:hostname as the dsync target
plugin {
  #mail_replica = tcp:server1.domain.ltd # use doveadm_port
  mail_replica = tcp:server1.domain.ltd:12345 # use port 12345 explicitly
}

service config {
  unix_listener config {
user = vmail
  }
}

To test both port   I have open on  my both servers port 12345 and 4711 :

Iptables server1: ACCEPT tcp  --  anywhere anywhere 
tcp dpt:4711
  ACCEPT tcp  --  anywhere anywhere 
tcp dpt:12345

Iptables server2: ACCEPT tcp  --  anywhere anywhere 
tcp dpt:4711
  ACCEPT tcp  --  anywhere anywhere 
tcp dpt:12345


doveadm replicator  status '*'
username
priority fast sync full sync failed
us...@domain.ltd
none 00:01:21  11:25:40  y
us...@domain.ltd
none 07:31:16  11:25:41  -
us...@domain.ltd
none 00:01:21  11:25:40  y
us...@domain.ltd
none 11:25:41  11:25:41  -
us...@domain.ltd
none 02:17:03  11:25:41  -
us...@domain.ltd
none 11:25:40  11:25:40  -
us...@domain.ltd
none 00:00:51  11:25:40  y

When  doing, from server1:   "doveadm sync -u us...@domain.ltd 
remote:server2.domain.ltd"

doveadm(us...@domain.ltd): Error: userdb lookup: 
connect(/var/run/dovecot/auth-userdb) failed: Connection refused
doveadm(us...@domain.ltd): Fatal: /var/run/dovecot/auth-userdb: passdb lookup 
failed (to see if

Re: dsync dovecot / Failed connection refused

2017-01-26 Thread Mike Fröhner
Your output looks like iptables -L -n. Can you add the -v option to 
check if the rule did handle packages?


On 01/26/2017 05:39 PM, Thierry wrote:

ACCEPT tcp  --  anywhere anywhere tcp dpt:4711


Re: Dovecot dsync 'ssl_client_ca'

2017-02-03 Thread Mike Fröhner

Hello,


On 02/03/2017 08:51 AM, Thierry wrote:

Hello,

Still working with my dsync pb.
I have done a clone (vmware) of my email server.
Today   I   have   two  strictly  identical  emails  servers (server1
(main) and server2 (bck) (except IP, hostname and  mail_replica).

The ssl config on my both server:

ssl_protocols = !SSLv2 !SSLv3
ssl = required
verbose_ssl = no
ssl_key = 

I think it should be ssl_client_ca_file = 





This  config  is  working   for  my   email  client  and my email web
interface ...

Are they on the right order ?

mail_replica = tcps:serv...@domain.ltd and tcps:serv...@domain.ltd

There is trafic on my iptables rules on my both  servers:

60  3600 ACCEPT tcp  --  *  *   0.0.0.0/00.0.0.0/0  
  tcp dpt:4711



My  error message from server1 (main server):

Feb 03 08:38:08 doveadm(us...@domain.ltd): Error: sync: Couldn't initialize SSL 
context: Can't verify remote server certs without trusted CAs (ssl_client_ca_* 
settings)
Feb 03 08:42:35 doveadm(us...@domain.ltd): Error: sync: Couldn't initialize SSL 
context: Can't verify remote server certs without trusted CAs (ssl_client_ca_* 
settings)
Feb 03 08:42:35 doveadm(us...@domain.ltd): Error: sync: Couldn't initialize SSL 
context: Can't verify remote server certs without trusted CAs (ssl_client_ca_* 
settings)
Feb 03 08:42:35 doveadm(us...@domain.ltd): Error: sync: Couldn't initialize SSL 
context: Can't verify remote server certs without trusted CAs (ssl_client_ca_* 
settings)

No logs from server2

Any ideas ?

Thx for your support




Pop3 service stops responding

2015-06-02 Thread Mike Eriksson
Hi!

I have problem with the pop3 service stops responding at random intervals
on my server. We started to notice this problem as we're running icinga to
check the imap & pop3 service.

When icinga reports that the service is down. We try to telnet to the
server on port 110 but it refuses the connection.

I've checked the netstat during this time and it's listens on port 110. My
first thought we were hitting the max connections and similar.

Changed login_max_connections from 128 to 256. Didnt solve the problem.

Started the debug on the dovecot server but could not see anything in the
logs. Also the error log or the syslog dosnt report anything that I can see.

Best thing would of course be to start and upgrade the software and
os(Debian 5) but I'm not comfortable upgrading it at the moment as my
knowledge about dovecot / postfix isn't great.

Do you have any idéas how to move forward?

dovecot -n
# 1.0.15: /etc/dovecot/dovecot.conf
base_dir: /var/run/dovecot/
log_path: /var/log/dovecot-error.log
info_log_path: /var/log/dovecot-info.log
log_timestamp: %Y-%m-%d %H:%M:%S
protocols: pop3 imap imaps pop3s
ssl_cipher_list: ALL:!LOW
disable_plaintext_auth: no
login_dir: /var/run/dovecot//login
login_executable(default): /usr/lib/dovecot/imap-login
login_executable(imap): /usr/lib/dovecot/imap-login
login_executable(pop3): /usr/lib/dovecot/pop3-login
login_max_processes_count: 256
first_valid_uid: 1090
last_valid_uid: 1090
first_valid_gid: 1090
last_valid_gid: 1090
mail_privileged_group: mail
mail_location: maildir:~/Maildir
mail_executable(default): /usr/lib/dovecot/imap
mail_executable(imap): /usr/lib/dovecot/imap
mail_executable(pop3): /usr/lib/dovecot/pop3
mail_plugins(default): quota imap_quota
mail_plugins(imap): quota imap_quota
mail_plugins(pop3): quota
mail_plugin_dir(default): /usr/lib/dovecot/modules/imap
mail_plugin_dir(imap): /usr/lib/dovecot/modules/imap
mail_plugin_dir(pop3): /usr/lib/dovecot/modules/pop3
pop3_uidl_format(default):
pop3_uidl_format(imap):
pop3_uidl_format(pop3): %08Xu%08Xv
auth default:
  username_chars:
abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ01234567890.-_@%
  username_translation: %@
  username_format: %Lu
  passdb:
driver: sql
args: /etc/dovecot/dovecot-sql.conf
  userdb:
driver: passwd
  userdb:
driver: sql
args: /etc/dovecot/dovecot-sql.conf
  socket:
type: listen
client:
  path: /var/spool/postfix/private/auth
  mode: 432
  user: postfix
  group: postfix
master:
  path: /var/run/dovecot/auth-master
  mode: 384
  user: vmail
  group: vmail
plugin:
  quota: maildir
  sieve_global_path: /etc/dovecot/sieve_scripts/spam-sort.sieve

login_max_processes_count: 256
login_max_connections: 256
max_mail_processes: 1024

Best Regards
Mike


passwd mismatch

2016-05-18 Thread Mike Ponto
I have been trying to follow the "instructions" at 
"http://blog.iandreev.com/?p=1975#dovecot"; and they seem to be pretty 
good.  everything works until I get to the part were I test the dovecot 
installation and it keeps failing.

I get an AUTH fail error at the "telnet localhost 110" login commands

I am trying to setup 3 domains:
domain1.us
domain2.com
domain3.com
I have 4 users entered in the /etc/dovecot/users file
I followed the instructions for creating an encrypted password but don't 
think it is correct and I don't have the knowledge to say why.  Just 
doesn't feel right.


I admit I am over my head and the learning curve just got exponential - 
any help at all would be really appreciated.



System:
QEMU/KVM vitrual install
Centos 7.01
basic install
4096 G Ram
4 proc
120 G HD

unit is behind an IPCop firewall with port forwarding.
internal IP 192.168.1.155
external IP on request

have username in /etc/dovecot/users as such:
mynameh...@mydomainhere.us:

Turned on debuggin and log file shows:
May 18 16:45:02 auth: Debug: auth client connected (pid=5639)
May 18 16:45:16 auth: Debug: client in: AUTH1PLAIN 
service=pop3secured session=2pP4xSQzzgAB
lip=::1 rip=::1 lport=110rport=33742 $
May 18 16:45:16 auth: Debug: 
passwd-file(mynameh...@mydomainhere.us,::1,<2pP4xSQzzgAB>): 
lookup: user=mynameh...@mydomainhere.us file=/etc/dovecot/users
May 18 16:45:16 auth: Info: 
passwd-file(mynameh...@mydomainhere.us,::1,<2pP4xSQzzgAB>): 
Password mismatch
May 18 16:45:18 auth: Debug: client passdb out: FAIL1 
user=mynamehe...@mydomainhere.us
May 18 16:45:20 pop3-login: Info: Aborted login (auth failed, 1 attempts 
in 4 secs): user=, method=PLAIN, rip=::1, 
lip=::1, secured, session=<2pP4xSQzzgAA$


[Dovecot] mbox originally needed 0 bytes, now needs maxint bytes

2011-08-16 Thread Mike Brown
I'm running dovecot 1.2.16 from the ports collection on FreeBSD 8.1-STABLE, 
amd64.

I've long been getting the following kind of messages in my logs, on 
random occasions when I access or move mail into mboxes:

Aug 16 00:43:58 myhost dovecot: IMAP(mike): mbox /home/mike/mail/feedback: 
seq=88 uid=91 uid_broken=0 originally needed 0 bytes, now needs 
18446744073709551615 bytes

Whatever I'm trying to do always succeeds, but apparently dovecot is confused 
about something. That number (2^64-1) suggests it has to do with the amd64 
architecture. Did a compile option get overlooked?

Thanks for whatever you can suggest. Let me know if you need more info.


[Dovecot] mbox originally needed 0 bytes, now needs maxint bytes

2011-08-16 Thread Mike Brown
I'm running dovecot 1.2.16 from the ports collection on FreeBSD 8.1-STABLE, 
amd64.

I've long been getting the following in my logs, seemingly at random (so, only 
sometimes), when I access or move mail into mboxes:

Aug 16 00:43:58 myhost dovecot: IMAP(mike): mbox /home/mike/mail/feedback: 
seq=88 uid=91 uid_broken=0 originally needed 0 bytes, now needs 
18446744073709551615 bytes

Whatever I'm trying to do always succeeds, but apparently dovecot is confused 
about something. That number (2^64-1) suggests it has to do with the amd64 
architecture. Did a compile option get overlooked?

Let me know if there's anything I need to do to get rid of these warnings.

Thanks,
Mike


[Dovecot] signal 11 crash, sometimes, during mbox bz2 decompression

2011-08-16 Thread Mike Brown
Hello again,

I'm running dovecot 1.2.16 from the ports collection on FreeBSD 8.1-STABLE, 
amd64.

To enable IMAP read-only access to gzip or bzip2 compressed mbox files, I 
added the following to my dovecot.conf, in the protocol imap { ... } section: 
mail_plugins = zlib

My compressed mbox files are all .bz2 files in an 'old' subdirectory of my 
main mail directory. I am trying to access them with Thunderbird. I 
'subscribed' to them just fine, and at first I thought it was working, but I 
just got lucky on the first couple I accessed. Dovecot actually fails to 
decompress them about 90% of the time, seemingly at random; the same box will 
not work a bunch of times, then work once, then not work again and again. When 
it works, sometimes only some of the messages get transmitted.

Most of the failures are accompanied by this pair of messages in my log:

Aug 16 00:25:33 myhost dovecot: dovecot: child 943 (imap) killed with signal 11 
(core not dumped - set mail_drop_priv_before_exec=yes)
Aug 16 00:25:33 myhost kernel: pid 943 (imap), uid 1001: exited on signal 11

Some of the failures have only the "exited on signal 11" message.

The very first failure had this:

Aug 16 00:22:47 myhost dovecot: IMAP(mike): Next message unexpectedly lost from 
mbox file (read-only mbox stream) at 2761 (cached)
Aug 16 00:22:47 myhost dovecot: IMAP(mike): read(mail, uid=2) failed: Invalid 
argument


Is this a problem with dovecot? Let me know if/how I can help, or what other 
info you need.


Thanks,
Mike



Re: [Dovecot] mbox originally needed 0 bytes, now needs maxint bytes

2011-08-16 Thread Mike Brown
Sorry for the duplicate post. I lost my network connection right as I was 
sending the first one.


Re: [Dovecot] signal 11 crash, sometimes, during mbox bz2 decompression

2011-09-12 Thread Mike Brown

On 8/23/2011 11:47 AM, Timo Sirainen wrote:

On Tue, 2011-08-16 at 05:00 -0600, Mike Brown wrote:


I'm running dovecot 1.2.16 from the ports collection on FreeBSD 8.1-STABLE,
amd64.

..


Thanks for the reply. Since you recommended updating to dovecot2, I'm 
now testing dovecot 2.0.14 from the ports collection on a different 
machine. Hopefully I got the configuration right.


# dovecot -n
# 2.0.14: /usr/local/etc/dovecot/dovecot.conf
# OS: FreeBSD 8.2-RELEASE-p2 i386
mail_location = mbox:~/mail:INBOX=/var/mail/%u
mail_plugins = " zlib"
passdb {
  args = %s
  driver = pam
}
plugin {
  zlib_save = bz2
  zlib_save_level = 9
}
protocols = imap
ssl_cert = On this system, I have the same setup with bz2-compressed mbox files. 
They're still inaccessible from Thunderbird, but dovecot isn't crashing 
with signal 11 anymore. Instead, the maillog says this for every 
compressed box it tries to check:


Sep 12 02:37:14 chilled dovecot: imap(mike): Error: 
read(/home/mike/mail/old/sent-1999-07.bz2) failed: Invalid argument (uid=2)
Sep 12 02:37:14 chilled dovecot: imap(mike): Disconnected: Internal 
error occurred. Refer to server log for more information. [2011-09-12 
02:37:14] bytes=5492/2664368
Sep 12 02:37:14 chilled dovecot: imap(mike): Error: Next message 
unexpectedly lost from mbox file /home/mike/mail/old/sent-1999-07.bz2 at 
536 (cached)


Did I misconfigure something?


[Dovecot] two little fixes for 2.0.14

2011-09-12 Thread Mike Abbott
--- a/dovecot/src/lib-index/mail-index-view.c
+++ b/dovecot/src/lib-index/mail-index-view.c
@@ -9,7 +9,7 @@
 void mail_index_view_clone(struct mail_index_view *dest,
   const struct mail_index_view *src)
 {
-   memset(dest, 0, sizeof(dest));
+   memset(dest, 0, sizeof(*dest));
dest->refcount = 1;
dest->v = src->v;
dest->index = src->index;


--- a/dovecot/src/lib-storage/mail-storage-service.c
+++ b/dovecot/src/lib-storage/mail-storage-service.c
@@ -870,7 +870,7 @@
}
 
user = p_new(user_pool, struct mail_storage_service_user, 1);
-   memset(user_r, 0, sizeof(user_r));
+   memset(user_r, 0, sizeof(*user_r));
user->pool = user_pool;
user->input = *input;
user->input.userdb_fields = NULL;



Re: [Dovecot] signal 11 crash, sometimes, during mbox bz2 decompression

2011-09-12 Thread Mike Brown

On 9/12/2011 5:28 AM, Timo Sirainen wrote:
Oh, wonder why no one else has complained about that. Fixed: 
http://hg.dovecot.org/dovecot-2.0/rev/a930318a74a1 

I tested this patch, and it's working like a charm. Thanks!


[Dovecot] Shredding instead of deleting

2011-09-14 Thread Mike Cardwell
Hi,

I have a wishlist item. Is there an appropriate place for me to post it?
Basically, I would like to know that my email isn't recoverable from the
local disk on the mail server after I delete it. So instead of just
deleting the file from my Maildir, I'd like the option to exist for
Dovecot to shred it.. Ie, overwrite the file with random data and/or
null bytes before deletion. In the same way that GNU shred behaves:

https://www.gnu.org/software/coreutils/manual/html_node/shred-invocation.html

-- 
Mike Cardwell https://grepular.com/  https://twitter.com/mickeyc
Professional  http://cardwellit.com/ http://linkedin.com/in/mikecardwell
PGP.mit.edu   0018461F/35BC AF1D 3AA2 1F84 3DC3 B0CF 70A5 F512 0018 461F



signature.asc
Description: OpenPGP digital signature


Re: [Dovecot] outlook 2007 very slow.

2011-09-20 Thread Mike Cardwell
On 20/09/11 11:46, Charles Marcus wrote:

>>> and is even better in 2010
> 
>> Do they support ACL in 2010? They don't in 2007, which is really
>> frustrating. What is better about 2010 IMAP support compared to 2007?
>> I'm genuinely interested to know...
> 
> What do you mean by 'ACL support'? Do you mean the ability to 
> create/edit them on shared folders?

Yes. Support for the IMAP ACL extension.

> If so, then no, not natively, I 
> don't think, but I didn't do any intensive testing, all I can tell you 
> is it is much more responsive, especially on larger folders.

This is a real shame. IMAP can do so much more than Exchange's IMAP
implementation allows.

-- 
Mike Cardwell https://grepular.com/  https://twitter.com/mickeyc
Professional  http://cardwellit.com/ http://linkedin.com/in/mikecardwell
PGP.mit.edu   0018461F/35BC AF1D 3AA2 1F84 3DC3 B0CF 70A5 F512 0018 461F



signature.asc
Description: OpenPGP digital signature


Re: [Dovecot] 64.31.19.48 attempt to break into my computer

2011-09-22 Thread Mike Cardwell
On 22/09/11 15:08, Charles Marcus wrote:

> The only attack I haven't figured out how to eliminate is the
> social/phishing attack, where $DumbUser gives out their username
> password voluntarily... although I have been considering faking a
> phishing attack on my own users, and flagging the ones who fall for it
> for training.

The University I work at was suffering from this a *lot*. Phishers kept
contacting our users pretending to be from our IT helpdesk asking users
to reply with their login details so that their mailbox could be
refreshed or so their quota could be fixed and other such things.

So I developed an application that sits on our outgoing mail routers
looking for login credentials inside emails. If it finds any, it
blackholes the email and sends an autoresponse to the sender telling
them to never ever send login details via email under any circumstances.
It Cc's me in too, and it catches people emailing their logins around on
a *daily* basis.

Our usernames follow a very strict format, and we have a pretty strict
password policy so what my program does is pull out a list of all the
*possible* usernames and passwords and then attempts to authenticate
against our AD using them.

I built it into a framework so other people can use it:

http://kochi.lboro.ac.uk/kochi1.html

You need to know how to write Perl though in order to use it. It's not
plug and play.

We also added ratelimiting to our outgoing mail, and a system which
alerts us whenever anyone hits the limit. If it takes a phisher 2000
spams to get access to one account, but that one account only allows the
phisher to send 1000 spams, then it completely destroys the point of
what they're doing.

-- 
Mike Cardwell https://grepular.com/  https://twitter.com/mickeyc
Professional  http://cardwellit.com/ http://linkedin.com/in/mikecardwell
PGP.mit.edu   0018461F/35BC AF1D 3AA2 1F84 3DC3 B0CF 70A5 F512 0018 461F



signature.asc
Description: OpenPGP digital signature


Re: [Dovecot] 64.31.19.48 attempt to break into my computer

2011-09-22 Thread Mike Cardwell
On 22/09/11 15:21, Ralf Hildebrandt wrote:

>> The University I work at was suffering from this a *lot*. Phishers kept
>> contacting our users pretending to be from our IT helpdesk asking users
>> to reply with their login details so that their mailbox could be
>> refreshed or so their quota could be fixed and other such things.
> 
> Same here.
> 
>> So I developed an application that sits on our outgoing mail routers
>> looking for login credentials inside emails. If it finds any, it
>> blackholes the email and sends an autoresponse to the sender telling
>> them to never ever send login details via email under any circumstances.
>> It Cc's me in too, and it catches people emailing their logins around on
>> a *daily* basis.
> 
> clamav is supposed to be capable of that functionality
>
>> Our usernames follow a very strict format, and we have a pretty strict
>> password policy so what my program does is pull out a list of all the
>> *possible* usernames and passwords and then attempts to authenticate
>> against our AD using them.
> 
> Ah!
> That's a nice idea.

Perhaps, if you have a list of the plain text passwords in advance you
could use ClamAV. In our case, we don't as we're using an AD. I actually
copied the ClamAV tcp and local interface API so that any MTA which can
plug in to ClamAV is also able to plug into Kochi. That's one of the
things the framework provides.

-- 
Mike Cardwell https://grepular.com/  https://twitter.com/mickeyc
Professional  http://cardwellit.com/ http://linkedin.com/in/mikecardwell
PGP.mit.edu   0018461F/35BC AF1D 3AA2 1F84 3DC3 B0CF 70A5 F512 0018 461F



signature.asc
Description: OpenPGP digital signature


[Dovecot] another sizeof tweak

2011-11-08 Thread Mike Abbott
Line 776 of dovecot-2.0.15/src/lib-storage/index/maildir/maildir-sync-index.c 
reads:
memcmp(old_rec, &new_rec, sizeof(old_rec)) != 0) {
Should that be sizeof(*old_rec)?


[Dovecot] dovecot 2.1.rc1 and folders with umlauts

2011-12-07 Thread Mike Constabel
Hi,

if I try to crate a folder in Thunderbird 8 which contains 
umlauts this happens:

- Create folder "Tür"
- Thunderbird show T&APw-r in folder list

In log:

Dec 07 17:45:39 imap(te...@in-preetz.de): Debug: Namespace : 
/mailspool1/in-preetz.de/test1/mdbox/mailboxes/T&APw-r doesn't exist yet, using 
default permissions
Dec 07 17:45:39 imap(te...@in-preetz.de): Debug: Namespace : Using permissions 
from /mailspool1/in-preetz.de/test1/mdbox: mode=0700 gid=-1

# ll /mailspool1/in-preetz.de/test1/mdbox/mailboxes/
insgesamt 32K
drwx-- 8 vmail vmail 4,0K  7. Dez 17:45 .
drwx-- 4 vmail vmail 4,0K  7. Dez 17:45 ..
drwx-- 3 vmail vmail 4,0K 29. Nov 11:11 Drafts
drwx-- 3 vmail vmail 4,0K 29. Nov 11:04 INBOX
drwx-- 3 vmail vmail 4,0K 29. Nov 11:11 Junk
drwx-- 3 vmail vmail 4,0K 29. Nov 11:11 Sent
drwx-- 3 vmail vmail 4,0K  7. Dez 17:45 T&APw-r
drwx-- 4 vmail vmail 4,0K  7. Dez 17:44 Trash

If I click in TB on the folder, TB gives an empty message, the 
log shows:

Dec 07 17:42:53 imap(te...@in-preetz.de): Debug: Effective uid=1000, gid=1000, 
home=/mailspool1/in-preetz.de/test1
Dec 07 17:42:53 imap(te...@in-preetz.de): Debug: quota: No quota setting - 
plugin disabled
Dec 07 17:42:53 imap(te...@in-preetz.de): Debug: Namespace inbox: type=private, 
prefix=, sep=/, inbox=yes, hidden=no, list=yes, subscriptions=yes 
location=mdbox:~/mdbox
Dec 07 17:42:53 imap(te...@in-preetz.de): Debug: fs: 
root=/mailspool1/in-preetz.de/test1/mdbox, index=, control=, inbox=, alt=
Dec 07 17:42:53 imap(te...@in-preetz.de): Debug: Namespace : Using permissions 
from /mailspool1/in-preetz.de/test1/mdbox: mode=0700 gid=-1
Dec 07 17:43:02 imap(te...@in-preetz.de): Debug: Namespace : 
/mailspool1/in-preetz.de/test1/mdbox/mailboxes/&ANY-de doesn't exist yet, using 
default permissions
Dec 07 17:43:02 imap(te...@in-preetz.de): Debug: Namespace : Using permissions 
from /mailspool1/in-preetz.de/test1/mdbox: mode=0700 gid=-1
Dec 07 17:44:19 imap(te...@in-preetz.de): Debug: Namespace : 
/mailspool1/in-preetz.de/test1/mdbox/mailboxes/&-ANY-de doesn't exist yet, 
using default permissions
Dec 07 17:44:19 imap(te...@in-preetz.de): Debug: Namespace : Using permissions 
from /mailspool1/in-preetz.de/test1/mdbox: mode=0700 gid=-1
Dec 07 17:44:19 imap(te...@in-preetz.de): Debug: Namespace : 
/mailspool1/in-preetz.de/test1/mdbox/mailboxes/Trash/&-ANY-de doesn't exist 
yet, using default permissions
Dec 07 17:44:24 imap(te...@in-preetz.de): Debug: Namespace : 
/mailspool1/in-preetz.de/test1/mdbox/mailboxes/Trash/T&APw-r doesn't exist yet, 
using default permissions
Dec 07 17:45:39 imap(te...@in-preetz.de): Debug: Namespace : 
/mailspool1/in-preetz.de/test1/mdbox/mailboxes/T&APw-r doesn't exist yet, using 
default permissions
Dec 07 17:45:39 imap(te...@in-preetz.de): Debug: Namespace : Using permissions 
from /mailspool1/in-preetz.de/test1/mdbox: mode=0700 gid=-1


On another server with

# 2.0.13 (537d4b6d9a7a): /etc/dovecot/dovecot.conf
# OS: Linux 2.6.32-5-686 i686 Debian 6.0.2 

an an server with

# 1.2.16: /etc/dovecot/dovecot.conf
# OS: Linux 2.6.32-5-xen-amd64 x86_64 Debian 5.0.9 

umlauts are working.

Is there an problem with my config or with the rc1?


thanks,
Mike


dovecot -n for not working 2.1.rc1:

# 2.1.rc1: /etc/dovecot/dovecot.conf
# OS: Linux 2.6.32-5-xen-amd64 x86_64 Debian 6.0.3 
auth_cache_size = 1 M
auth_debug = yes
auth_debug_passwords = yes
auth_mechanisms = plain login cram-md5
auth_verbose = yes
auth_verbose_passwords = plain
debug_log_path = /var/log/dovecot/dovecot-debug.log
default_client_limit = 2600
disable_plaintext_auth = no
hostname = mx4.constabel-it.de
info_log_path = /var/log/dovecot/dovecot-info.log
log_path = /var/log/dovecot/dovecot.log
mail_debug = yes
mail_location = mdbox:~/mdbox
mail_plugins = quota notify mail_log
mail_privileged_group = mail
managesieve_notify_capability = mailto
managesieve_sieve_capability = fileinto reject envelope encoded-character 
vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy 
include variables body enotify environment mailbox date ihave
namespace inbox {
  inbox = yes
  location = 
  prefix = 
  separator = /
  type = private
}
passdb {
  args = scheme=PLAIN username_format=%u /etc/imap.userdb
  driver = passwd-file
}
plugin {
  autocreate = Trash
  autocreate2 = Junk
  autocreate3 = Sent
  autocreate4 = Drafts
  autosubscribe = Trash
  autosubscribe2 = Junk
  autosubscribe3 = Sent
  autosubscribe4 = Drafts
  sieve = ~/.dovecot.sieve
  sieve_dir = ~/sieve
}
postmaster_address = postmaster@localhost
protocols = " imap lmtp sieve pop3"
service auth {
  inet_listener {
address = 192.168.10.117
port = 12345
  }
}
service imap-login {
  inet_listener imap {
address = 192.168.10.117
port = 143
  }
  inet_listener imaps {
address = 192.168.10.117
port = 993
ssl = yes
  }
}
service lmtp {
  inet_listener

Re: [Dovecot] dovecot 2.1.rc1 and folders with umlauts

2011-12-08 Thread Mike Constabel
Hi,

Timo Sirainen schrieb am Thursday, den 08. December 2011:

> On Wed, 2011-12-07 at 18:05 +0100, Mike Constabel wrote:
> 
> > if I try to crate a folder in Thunderbird 8 which contains 
> > umlauts this happens:
> > 
> > - Create folder "Tür"
> > - Thunderbird show T&APw-r in folder list
> 
> I can't reproduce. Is it possible this is a TB bug? Try talking IMAP
> protocol directly:
> 
> /usr/local/libexec/dovecot/imap -u user@domain
> a list "" T*
> 
> If it lists:
> 
> * LIST (\HasNoChildren) "." "T&APw-r"
> 
> Then Dovecot is working correctly.

I get:

# /usr/lib/dovecot/imap -u te...@in-preetz.de
Debug: Loading modules from directory: /usr/lib/dovecot/modules
Debug: Module loaded: /usr/lib/dovecot/modules/lib10_quota_plugin.so
Debug: Module loaded: /usr/lib/dovecot/modules/lib11_imap_quota_plugin.so
Debug: Module loaded: /usr/lib/dovecot/modules/lib15_notify_plugin.so
Debug: Module loaded: /usr/lib/dovecot/modules/lib20_mail_log_plugin.so
Debug: auth input: te...@in-preetz.de uid=1000 gid=1000 
home=/mailspool1/in-preetz.de/test1 quota_rule=*:storage=500M
Debug: Added userdb setting: plugin/quota_rule=*:storage=500M
Debug: Effective uid=1000, gid=1000, home=/mailspool1/in-preetz.de/test1
Debug: quota: No quota setting - plugin disabled
Debug: Namespace inbox: type=private, prefix=, sep=/, inbox=yes, hidden=no, 
list=yes, subscriptions=yes location=mdbox:~/mdbox
Debug: fs: root=/mailspool1/in-preetz.de/test1/mdbox, index=, control=, inbox=, 
alt=
Debug: Namespace : Using permissions from /mailspool1/in-preetz.de/test1/mdbox: 
mode=0700 gid=-1
* PREAUTH [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE IDLE 
SORT SORT=DISPLAY THREAD=REFERENCES THREAD=REFS MULTIAPPEND UNSELECT CHILDREN 
NAMESPACE UIDPLUS LIST-EXTENDED I18NLEVEL=1 CONDSTORE QRESYNC ESEARCH ESORT 
SEARCHRES WITHIN CONTEXT=SEARCH LIST-STATUS FUZZY SPECIAL-USE QUOTA] Logged in 
as te...@in-preetz.de
a list "" T*
* LIST (\HasNoChildren) "/" "T&-APw-r"
* LIST (\HasChildren) "/" "Trash"
* LIST (\HasNoChildren) "/" "Trash/T&-APw-r"
a OK List completed.


As you see there is a second "-" in the name:

"T&APw-r" != "T&-APw-r"


With my old server:


# telnet 192.168.10.102 143
Trying 192.168.10.102...
Connected to 192.168.10.102.
Escape character is '^]'.
* OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE STARTTLS 
AUTH=PLAIN AUTH=LOGIN AUTH=CRAM-MD5] Dovecot ready.
A login aaa bbb
A OK [CAPABILITY IMAP4rev1 LITERAL+ SASL-IR LOGIN-REFERRALS ID ENABLE SORT 
SORT=DISPLAY THREAD=REFERENCES THREAD=REFS MULTIAPPEND UNSELECT IDLE CHILDREN 
NAMESPACE UIDPLUS LIST-EXTENDED I18NLEVEL=1 CONDSTORE QRESYNC ESEARCH ESORT 
SEARCHRES WITHIN CONTEXT=SEARCH LIST-STATUS ACL RIGHTS=texk QUOTA] Logged in
a list "" T*
* LIST (\HasNoChildren) "/" "Trash"
* LIST (\HasNoChildren) "/" "Test-1"
* LIST (\HasNoChildren) "/" "T&APw-r"
a OK List completed.



Mike



Re: [Dovecot] dovecot 2.1.rc1 and folders with umlauts

2011-12-10 Thread Mike Constabel
Hi,

Timo Sirainen schrieb am Saturday, den 10. December 2011:

> On Thu, 2011-12-08 at 11:19 +0200, Timo Sirainen wrote:
> > On Thu, 2011-12-08 at 09:55 +0100, Mike Constabel wrote:
> > 
> > > As you see there is a second "-" in the name:
> > > 
> > > "T&APw-r" != "T&-APw-r"
> > 
> > Oh, right, it's broken in the "fs" layout. With "maildir++" layout it
> > works. And looks like this isn't going to be an easy fix. The fs layout
> > listing code is horrible.. Maybe I'll just try rewriting it.
> 
> OK, this should do it, hopefully without breaking anything:
> http://hg.dovecot.org/dovecot-2.1/rev/ab696ead12cc
> 

This works for me with a litte problem.


If I create in TB folder like "moe" (without special chars) the 
folder will be created, subscribed and TB shows the folder 
instantly.

But if I create a folder like "mö" (with special chars) the 
folder will be created, subscribed and *TB doesn't show the 
folder*. I must unsubscribe and subscribe it in TB to show it in 
folder pane.



Mike


Re: [Dovecot] dovecot 2.1.rc1 and folders with umlauts

2011-12-12 Thread Mike Constabel
On Mon, 12 Dec 2011, Timo Sirainen wrote:

> On Sat, 2011-12-10 at 15:10 +0100, Mike Constabel wrote:
> > > OK, this should do it, hopefully without breaking anything:
> > > http://hg.dovecot.org/dovecot-2.1/rev/ab696ead12cc
> > > 
> > 
> > This works for me with a litte problem.
> > 
> > 
> > If I create in TB folder like "moe" (without special chars) the 
> > folder will be created, subscribed and TB shows the folder 
> > instantly.
> > 
> > But if I create a folder like "mö" (with special chars) the 
> > folder will be created, subscribed and *TB doesn't show the 
> > folder*. I must unsubscribe and subscribe it in TB to show it in 
> > folder pane.
> 
> http://hg.dovecot.org/dovecot-2.1/rev/b9fcac239aed should fix it.
> 

Yes, it works. Thanks.


Mike


[Dovecot] dovecot 2.1.rc1: sieve and folders with umlauts

2011-12-12 Thread Mike Constabel
Hi,

now the umlauts problem with sieve:

# cat /mailspool1/in-preetz.de/test1/.dovecot.sieve
## Generated by Roundcube Webmail SieveRules Plugin ##
require ["fileinto"];

# rule:[Test]
if anyof (header :contains "Subject" "test")
{
fileinto "m&APY-";
}



Error: DBBjDsXL5U7mIAAA/TNBsA: sieve: execution of script 
/mailspool1/in-preetz.de/test1/.dovecot.sieve failed, but implicit keep was 
successful (user logfile /mailspool1/in-preetz.de/test1/.dovecot.sieve.log may 
reveal additional details)


# cat /mailspool1/in-preetz.de/test1/.dovecot.sieve.log
sieve: info: started log at Dec 12 10:40:04.
error: msgid=<20111212094004.db86918...@mx4.constabel-it.de>: failed to store 
into mailbox 'm&APY-': Mailbox doesn't exist: m&-APY-.


Here the same:

'm&APY-' != "m&-APY-"



Mike


Re: [Dovecot] dovecot 2.1.rc1: sieve and folders with umlauts

2011-12-12 Thread Mike Constabel
Hello,

On 2011-12-12 at 10:58 CET Timo Sirainen wrote:

> On 12.12.2011, at 11.46, Mike Constabel wrote:
> 
> > now the umlauts problem with sieve:
> ..
> > ## Generated by Roundcube Webmail SieveRules Plugin ##
> 
> Roundcube bug/"feature".
> 
> >fileinto "m&APY-";
> 
> Sieve uses UTF-8 mailbox names. The reason why Roundcube doesn't use them, is 
> because some old Cyrus Sieve versions didn't use UTF-8.

Ok, good to know. I found the setting in the roundcube sieverules 
plugin. After setting this to UTF-8 it works.

Thanks for the hint.


Mike



Re: [Dovecot] dovecot 2.1.rc1: sieve and folders with umlauts

2011-12-12 Thread Mike Constabel
Hello Stephan,

On 2011-12-12 at 11:00 CET Stephan Bosch wrote:

> Op 12/12/2011 10:46 AM, Mike Constabel schreef:
> >Hi,
> >
> >now the umlauts problem with sieve:
> >
> ># cat /mailspool1/in-preetz.de/test1/.dovecot.sieve
> >## Generated by Roundcube Webmail SieveRules Plugin ##
> >require ["fileinto"];
> >
> ># rule:[Test]
> >if anyof (header :contains "Subject" "test")
> >{
> > fileinto "m&APY-";
> >}
> 
> And here it is actually correct. Sieve fileinto expects the argument
> to be in utf8 and you are passing the IMAP mutf7.
> 
> Use
> 
> fileinto "mö";
> 
> instead.

Thanks for the hint, now it works. :)

Mike



[Dovecot] v2.1.rc1 managesieve TLS

2011-12-12 Thread Mike Constabel
Hi,


TLS on imap port 143 works.

But if I try TLS on managesieve port 4190, I get no connection.

Dec 12 21:16:10 managesieve-login: Info: Disconnected (no auth attempts in 5 
secs): rip=192.168.10.117, lip=192.168.10.117, secured
Dec 12 21:16:20 managesieve-login: Info: Disconnected (no auth attempts in 5 
secs): rip=192.168.10.117, lip=192.168.10.117, TLS handshaking: Disconnected


# gnutls-cli --starttls -p 4190 192.168.10.117
Resolving '192.168.10.117'...
Connecting to '192.168.10.117:4190'...

- Simple Client Mode:

"IMPLEMENTATION" "Dovecot Pigeonhole"
"SIEVE" "fileinto reject envelope encoded-character vacation subaddress 
comparator-i;ascii-numeric relational regex imap4flags copy include variables 
body enotify environment mailbox date ihave"
"NOTIFY" "mailto"
"SASL" "PLAIN LOGIN CRAM-MD5"
"STARTTLS"
"VERSION" "1.0"
OK "Dovecot ready."
STARTTLS
NO "Begin TLS negotiation now."


^ There is a NO and not an OK...


Possible something wrong with my config, but I cannot find 
something...



# doveconf -n
# 2.1.rc1: /etc/dovecot/dovecot.conf
# OS: Linux 2.6.32-5-xen-amd64 x86_64 Debian 6.0.3 
auth_cache_size = 1 M
auth_debug = yes
auth_debug_passwords = yes
auth_mechanisms = plain login cram-md5
auth_verbose = yes
auth_verbose_passwords = plain
debug_log_path = /var/log/dovecot/dovecot-debug.log
default_client_limit = 2600
dict {
  expire = sqlite:/etc/dovecot/dovecot-dict-expire.conf.ext
}
disable_plaintext_auth = no
hostname = mx4.constabel-it.de
info_log_path = /var/log/dovecot/dovecot-info.log
log_path = /var/log/dovecot/dovecot.log
mail_debug = yes
mail_location = mdbox:~/mdbox
mail_plugins = quota notify mail_log expire acl
mail_privileged_group = mail
managesieve_notify_capability = mailto
managesieve_sieve_capability = fileinto reject envelope 
encoded-character vacation subaddress comparator-i;ascii-numeric 
relational regex imap4flags copy include variables body enotify 
environment mailbox date ihave
namespace inbox {
  inbox = yes
  location = 
  mailbox Archive/2011 {
auto = subscribe
  }
  mailbox Drafts {
auto = subscribe
special_use = \Drafts
  }
  mailbox Junk {
auto = subscribe
special_use = \Junk
  }
  mailbox Sent {
auto = subscribe
special_use = \Sent
  }
  mailbox "Sent Messages" {
special_use = \Sent
  }
  mailbox Trash {
auto = subscribe
special_use = \Trash
  }
  prefix = 
  separator = /
  type = private
}
passdb {
  args = scheme=PLAIN username_format=%u /etc/imap.userdb
  driver = passwd-file
}
plugin {
  expire = Trash
  expire2 = Trash/*
  expire3 = Spam
  expire_dict = proxy::expire
  quota = dict:User quota::file:/mailspool1/%d/%n/dovecot-quota
  quota_rule = *:storage=9000M:messages=100
  sieve = ~/.dovecot.sieve
  sieve_dir = ~/sieve
}
postmaster_address = postmaster@localhost
protocols = " imap lmtp sieve pop3"
service auth {
  inet_listener {
address = 192.168.10.117
port = 12345
  }
}
service dict {
  unix_listener dict {
group = vmail
mode = 0666
  }
}
service imap-login {
  inet_listener imap {
address = 192.168.10.117
port = 143
  }
  inet_listener imaps {
address = 192.168.10.117
port = 993
ssl = yes
  }
}
service lmtp {
  inet_listener lmtp {
address = 192.168.10.117
port = 24
  }
}
service managesieve-login {
  inet_listener sieve {
address = 192.168.10.117
port = 4190
  }
  inet_listener sieve_deprecated {
port = 2000
  }
}
service pop3-login {
  inet_listener pop3 {
address = 192.168.10.117
port = 110
  }
  inet_listener pop3s {
address = 192.168.10.117
port = 995
ssl = yes
  }
}
ssl_ca = 

[Dovecot] proxying, SSL, and client certificate

2011-12-22 Thread Mike Abbott
How do I configure dovecot-2.0.x to present a client SSL certificate when 
proxying?

If dovecot on server1.example.com has:
passdb {
  driver = static
  args = proxy=y host=server2.example.com nopassword=y ssl=yes
}

and dovecot on server2.example.com has:
ssl_verify_client_cert = yes
auth_ssl_require_client_cert = yes

then when a client connects to server1 and authenticates, a connection is 
established to server2 but the SSL handshake fails because server1 doesn't 
present a client certificate.  I don't see where ssl_client_ctx is tied to a 
client certificate in ssl-proxy-openssl.c.

Thanks.


[Dovecot] MASTER_AUTH_MAX_DATA_SIZE

2012-01-11 Thread Mike Abbott
In 2.0.17 you increased LOGIN_MAX_INBUF_SIZE from 1024 to 4096.
Should you also have increased MASTER_AUTH_MAX_DATA_SIZE from (1024*2) to 
(4096*2)?
/* This should be kept in sync with LOGIN_MAX_INBUF_SIZE. Multiply it by two
   to make sure there's space to transfer the command tag  */



[Dovecot] 2.1.rc5 Cannot delete folders from trash

2012-02-12 Thread Mike Constabel
Hi,

If I delete a folder "foo" in Thunderbird, it is moved to trash.

[root@dovecot1][tmp:exec](~) # ll 
/mailspool1/.de/test1/mdbox/mailboxes/Trash/
insgesamt 16K
drwx-- 4 vmail vmail 4,0K 31. Jan 22:16 .
drwx-- 8 vmail vmail 4,0K 31. Jan 22:16 ..
drwx-- 2 vmail vmail 4,0K 12. Feb 11:51 dbox-Mails
drwx-- 3 vmail vmail 4,0K 31. Jan 22:16 foo
[root@dovecot1][tmp:exec](~) # 
[root@dovecot1][tmp:exec](~) # 
[root@dovecot1][tmp:exec](~) # ll 
/mailspool1/xxx.de/test1/mdbox/mailboxes/Trash/foo/
insgesamt 12K
drwx-- 3 vmail vmail 4,0K 31. Jan 22:16 .
drwx-- 4 vmail vmail 4,0K 31. Jan 22:16 ..
drwx-- 2 vmail vmail 4,0K 12. Feb 11:52 dbox-Mails
[root@dovecot1][tmp:exec](~) # ll 
/mailspool1/.de/test1/mdbox/mailboxes/Trash/foo/dbox-Mails/
insgesamt 12K
drwx-- 2 vmail vmail 4,0K 12. Feb 11:52 .
drwx-- 3 vmail vmail 4,0K 31. Jan 22:16 ..
-rw--- 1 vmail vmail  224 12. Feb 11:52 dovecot.index.log
[root@dovecot1][tmp:exec](~) # 


If I delete foo from trash, thunderbird removed it from view, 
but if I restart thunderbird, the folder is still in trash.

No error in dovecot log, no error in thunderbird.

tcpdump:

156 45.101512   192.168.10.1  192.168.10.117TCP  54094 
> imap [ACK] Seq=353 Ack=1617 Win=10144 Len=0 TSV=2414467591 TSER=251091441
157 45.349600   192.168.10.1  192.168.10.117IMAP 
Request: 16 list "" "Trash/*"
158 45.349717   192.168.10.117192.168.10.1  IMAP 
Response: * LIST (\HasNoChildren) "/" "Trash/foo"
159 45.349756   192.168.10.1  192.168.10.117TCP  54094 
> imap [ACK] Seq=375 Ack=1727 Win=10144 Len=0 TSV=2414467653 TSER=251091503
160 45.395546   192.168.10.1  192.168.10.117IMAP 
Request: 17 list "" "Trash/foo/*"
161 45.395624   192.168.10.117192.168.10.1  IMAP 
Response: * LIST (\Noselect \HasNoChildren) "/" "Trash/foo/"
162 45.395662   192.168.10.1  192.168.10.117TCP  54094 
> imap [ACK] Seq=401 Ack=1802 Win=10144 Len=0 TSV=2414467665 TSER=251091515
163 45.439998   192.168.10.1  192.168.10.117IMAP 
Request: 18 delete "Trash/foo/"
164 45.440067   192.168.10.117192.168.10.1  IMAP 
Response: 18 NO [CANNOT] Invalid mailbox name
165 45.440104   192.168.10.1  192.168.10.117TCP  54094 
> imap [ACK] Seq=425 Ack=1839 Win=10144 Len=0 TSV=2414467676 TSER=251091526
166 45.493978   192.168.10.1  192.168.10.117IMAP 
Request: 19 IDLE



with dovecot 1.2 and Maildir I can delete folders from trash.

Something wrong in my config? Thunderbird-Bug?


# 2.1.rc5 (b9e74767cd39): /etc/dovecot/dovecot.conf
# OS: Linux 2.6.32-5-xen-amd64 x86_64 Debian 6.0.4
auth_cache_size = 1 M
auth_debug = yes
auth_debug_passwords = yes
auth_mechanisms = plain login cram-md5
auth_verbose = yes
auth_verbose_passwords = plain
debug_log_path = /var/log/dovecot/dovecot-debug.log
dict {
  expire = sqlite:/etc/dovecot/dovecot-dict-expire.conf.ext
}
disable_plaintext_auth = no
hostname = mx4..de
info_log_path = /var/log/dovecot/dovecot-info.log
log_path = /var/log/dovecot/dovecot.log
mail_debug = yes
mail_location = mdbox:~/mdbox
mail_plugins = quota notify mail_log expire
mail_privileged_group = mail
managesieve_notify_capability = mailto
managesieve_sieve_capability = fileinto reject envelope 
encoded-character vacation subaddress comparator-i;ascii-numeric 
relational regex imap4flags copy include variables body enotify 
environment mailbox date ihave
namespace inbox {
  inbox = yes
  location =
  mailbox Archive/2011 {
auto = subscribe
  }
  mailbox Drafts {
auto = subscribe
special_use = \Drafts
  }
  mailbox Junk {
auto = subscribe
special_use = \Junk
  }
  mailbox Sent {
auto = subscribe
special_use = \Sent
  }
  mailbox "Sent Messages" {
special_use = \Sent
  }
  mailbox Trash {
auto = subscribe
special_use = \Trash
  }
  prefix =
  separator = /
  type = private
}
passdb {
  args = scheme=PLAIN username_format=%u /etc/imap.userdb
  driver = passwd-file
}
plugin {
  expire = Trash
  expire2 = Trash/*
  expire3 = Spam
  expire_dict = proxy::expire
  quota = dict:User quota::file:/mailspool1/%d/%n/dovecot-quota
  quota_rule = *:storage=9000M:messages=100
  sieve = ~/.dovecot.sieve
  sieve_dir = ~/sieve
}
postmaster_address = postmaster@localhost
protocols = " imap lmtp sieve pop3"
ssl_ca = 

Re: [Dovecot] 2.1.rc5 Cannot delete folders from trash

2012-02-12 Thread Mike Constabel
Hi,

On Sun, 12 Feb 2012, Morten Stevens wrote:

> On 12.02.2012 12:18, Mike Constabel wrote:
> 
> >If I delete foo from trash, thunderbird removed it from view,
> >but if I restart thunderbird, the folder is still in trash.
> >
> >No error in dovecot log, no error in thunderbird.
> 
> protocol imap {
>   ...
>   imap_client_workarounds = tb-extra-mailbox-sep
> }


Ok, this seems to work, (I thought I tried it before.. but now 
it works. :)


Another Question to this Option:

  #   tb-extra-mailbox-sep:
  # With mbox storage a mailbox can contain either mails or submailboxes,
  # but not both. Thunderbird separates these two by forcing server to
  # accept '/' suffix in mailbox names in subscriptions list.


I thought this is not needed because I use mdbox. But mbox here 
means also mdbox and sdbox?

Also "With mbox storage a mailbox can contain either mails or 
submailboxes, but not both" is only correct for mbox? In mdbox 
this is possible.

This description should contain a litte bit more info for 
mbox/sdbox/mdbox?



Should I use all 3 workarounds if I don't know which clients are 
in use?


LAYOUT=fs and mdbox


Regards, Mike



[Dovecot] Listener not binding to port

2012-04-04 Thread Mike Jones!
Hello.

Dovecot is not binding or listening on port 993 when I start it.

$ sudo netstat -tlnp | grep -c 993
0

Dovecot starts fine and runs without complaints.

$ sudo service dovecot restart
Restarting IMAP/POP3 mail server: dovecot.

$ sudo tail /var/log/mail.log
Apr  4 13:42:39 mwjones dovecot: master: Warning: Killed with signal
15 (by pid=16238 uid=0 code=kill)
Apr  4 13:42:39 mwjones dovecot: master: Dovecot v2.0.18 starting up
(core dumps disabled)

$ sudo ps -ef | grep -i [d]ovecot
root 16243 1  0 13:42 ?00:00:00 /usr/sbin/dovecot -c
/etc/dovecot/dovecot.conf
dovecot  16245 16243  0 13:42 ?00:00:00 dovecot/anvil
root 16246 16243  0 13:42 ?00:00:00 dovecot/log
root 16248 16243  0 13:42 ?00:00:00 dovecot/config

Still no listener :(

$ sudo netstat -tlnp | grep -c 993
0

Other infos for your scrutiny.

$ sudo dovecot --version
2.0.18

$ doveconf -n
# 2.0.18: /etc/dovecot/dovecot.conf
# OS: Linux 3.2.5-grsec x86_64 Debian wheezy/sid ext4
auth_debug = yes
auth_mechanisms = plain login
auth_verbose = yes
first_valid_uid = 1000
log_timestamp = "%Y-%m-%d %H:%M:%S "
mail_debug = yes
mail_location = maildir:/home/vmail/%d/%n/Maildir
passdb {
  args = /home/vmail/%d/etc/passwd
  driver = passwd-file
}
service auth {
  unix_listener /var/spool/postfix/private/auth {
group = postfix
mode = 0660
user = postfix
  }
  user = root
}
service imap-login {
  service_count = 1
}
service ssl-params {
  type = startup
}
ssl_cert = 

Re: [Dovecot] Listener not binding to port

2012-04-05 Thread Mike Jones!
Thanks so much all.  I was missing a few items:

protocols = imap # thanks to Timo Sirainen

# thanks to Noel Butler
service imap-login {
  inet_listener imap {
port = 0
  }
  inet_listener imaps {
address = *
port = 993
  }
  service_count = 1
}

Here is my final doveconf -n with listener successfully running on 993:

# 2.0.18: /etc/dovecot/dovecot.conf
# OS: Linux 3.2.5-grsec x86_64 Debian wheezy/sid ext4
auth_debug = yes
auth_mechanisms = plain login
auth_verbose = yes
first_valid_gid = 1030
first_valid_uid = 1030
info_log_path = /var/log/dovecot-info.log
last_valid_gid = 1030
last_valid_uid = 1030
log_path = /var/log/dovecot.log
log_timestamp = "%Y-%m-%d %H:%M:%S "
mail_debug = yes
mail_location = maildir:/home/vmail/%d/%n/Maildir
passdb {
  args = /home/vmail/%d/etc/passwd
  driver = passwd-file
}
protocols = imap
service auth {
  unix_listener /var/spool/postfix/private/auth {
group = postfix
mode = 0660
user = postfix
  }
  user = root
}
service imap-login {
  inet_listener imap {
port = 0
  }
  inet_listener imaps {
address = *
port = 993
  }
  service_count = 1
}
service ssl-params {
  type = startup
}
ssl_cert = 

Re: [Dovecot] Limiting the size of index files

2007-11-21 Thread Mike Brudenell

Greetings -

On 15 Nov 2007, at 07:36, Timo Sirainen wrote:

That was the plan, Maildir keywords are the only exception. I was  
also thinking about changing that some day so that it's not possible  
to set more than 26 keywords with maildir. I think this is currently  
pretty much a nonissue because keyword support is pretty bad with  
most IMAP clients and no-one has more than maybe 10 different  
keywords.


Anyway, by "just delete them" I meant dovecot.index.cache files, not  
the others. :)


Eeep!  Can I just check that I'm not doing something silly? ...

Our mail layout is as follows (using user "abc1" as an example):

  /mailstore/messages/a/abc1   ... Mail files in Maildir format
  /mailstore/control/a/abc1... Control files
  /mailstore/index/a/abc1  ... Index cache files

The first two are NFS-mounted; the last is on local disk.

Our load balancers direct people to their "preferred" host, failing  
over to another server if need be.  This means that when someone's  
preferred server is down for maintenance they can still access their  
mail, but end up getting index/cache files created on a "non- 
preferred" server.


Obviously these need cleaning up from time to time...

So we are currently using a housekeeping job (tmpreaper) to delete  
anything in or below a user's index directory that hasn't been  
accessed for 90 days.


I had thought I had read this was safe to do: that the index and  
caches files would be (re)built from the Maildir files if need be.   
But from what I read above, is it actually only safe to delete the  
dovecot.index.cache files?  That the index.cache files have to be left  
in place to avoid data loss?


Or am I worrying unnecessarily: that it would only affect people using  
more than 26 keywords?  (Rare)


Cheers,
Mike B-)

--
The Computing Service, University of York, Heslington, York Yo10 5DD, UK
Tel:+44-1904-433811  FAX:+44-1904-433740

* Unsolicited commercial e-mail is NOT welcome at this e-mail address. *



[Dovecot] Configuration Error

2007-11-25 Thread Mike McGonagle
Hello,
I am a newbie when it comes to Dovecot, and in following this (
http://workaround.org/articles/ispmail-etch/ ) document in setting these
things up, I have run into an error that I am not quite certain what to
do...

I am running Ubuntu Gutsy Gibbon, and using 1.0.5 for Dovecot. The message I
am getting when I try to 'restart' Dovecot (using '/etc/init.d/dovecot
restart') is:

Error: Error in configuration file /etc/dovecot/dovecot.conf line 505:
Protocol section not allowed here (section changed at line 505)
Fatal: Invalid configuration in /etc/dovecot/dovecot.conf
   ...fail!

Does this mean that I need to move this section of the configuration file to
a different spot in the file? All I did was uncomment these things, and make
the changes described in the link above, I would think that because this is
just an edited version of the configuration file, that something like this
shouldn't happen.

Any help would be appreciated.

Thank you,

Mike


-- 
Peace may sound simple—one beautiful word— but it requires everything we
have, every quality, every strength, every dream, every high ideal.
—Yehudi Menuhin (1916–1999), musician


Re: [Dovecot] Configuration Error

2007-11-25 Thread Mike McGonagle
Sorry for this, but I found a few braces that I forgot to uncomment. Guess I
should have checked my work a little more closely.
Thanks,

Mike


On Nov 25, 2007 4:09 PM, Mike McGonagle <[EMAIL PROTECTED]> wrote:

> Hello,
> I am a newbie when it comes to Dovecot, and in following this ( 
> http://workaround.org/articles/ispmail-etch/
> ) document in setting these things up, I have run into an error that I am
> not quite certain what to do...
>
> I am running Ubuntu Gutsy Gibbon, and using 1.0.5 for Dovecot. The message
> I am getting when I try to 'restart' Dovecot (using '/etc/init.d/dovecot
> restart') is:
>
> Error: Error in configuration file /etc/dovecot/dovecot.conf line 505:
> Protocol section not allowed here (section changed at line 505)
> Fatal: Invalid configuration in /etc/dovecot/dovecot.conf
>...fail!
>
> Does this mean that I need to move this section of the configuration file
> to a different spot in the file? All I did was uncomment these things, and
> make the changes described in the link above, I would think that because
> this is just an edited version of the configuration file, that something
> like this shouldn't happen.
>
> Any help would be appreciated.
>
> Thank you,
>
> Mike
>
>
> --
> Peace may sound simple—one beautiful word— but it requires everything we
> have, every quality, every strength, every dream, every high ideal.
> —Yehudi Menuhin (1916–1999), musician
>



-- 
Peace may sound simple—one beautiful word— but it requires everything we
have, every quality, every strength, every dream, every high ideal.
—Yehudi Menuhin (1916–1999), musician


[Dovecot] Can't login from Mac OS X Mail.app

2007-11-27 Thread Mike McGonagle
Hello all,
I have been working on getting this machine

-- 
Peace may sound simple—one beautiful word— but it requires everything we
have, every quality, every strength, every dream, every high ideal.
—Yehudi Menuhin (1916–1999), musician


Re: [Dovecot] dovecot-auth consumes 100% CPU time on Solaris 10

2007-11-29 Thread Mike Brudenell

Greetings -

On 29 Nov 2007, at 09:24, Mark Heitmann wrote:

In my $LD_LIBRARY_PATH /usr/lib is behind /usr/local/lib (for  
openldap), although
dovecot-auth was linked with the Solaris lib. The way that works for  
me is the
following LDFLAGS directive to the configure command, because the -- 
with-ldap

flag has no directory option:

LDFLAGS=-L"/usr/local/BerkeleyDB/lib -L/usr/local/lib /usr/local/lib/ 
libldap-2.4.so.2"


Is there a smarter way to link with the right lib and ignore the  
solaris one?


We used to have terrible problems similar to yours when trying to use  
LD_LIBRARY_PATH.  We now tend to use the "-R" option as well when  
compiling to specify unusual/specific library directories...


I think I have the following right:

 * "-l libraryname" searches in an ordered list of locations for a  
library

   named "libraryname".

 * "-L dirname" augments the above ordered list of locations with the
   directory "dirname".

If the library is a non-shared one then the above should suffice: the  
library routines needed by your program are hauled into the resulting  
executable and stored there.


However if, as is often the case, the libraries are instead shared  
(ie, have a ".so" suffix) then their code is NOT hauled into the  
executable, but is instead pulled in when the executable is actually  
run.  The run-time link-loader does this job.


The run-time link-loader also searches an ordered list of directories,  
this time looking for the shared libraries.  However this list is NOT  
affected by the "-L" option you used when compiling.


Instead the LD_LIBRARY_PATH (and, I think, the LD_RUN_PATH)  
environment variable influences this list.  However it is easy to end  
up with an inappropriate ordering, and so use the wrong shared library  
when running your program.


Using the "-R dirname" option at compile time "hardcodes" the named  
directory into your executable.  When it is run this directory is also  
searched for searched libraries, without the need to fiddle on setting  
environment variables up.


Typically you would list the same directories for both -L and -R  
options when you are using "unusual" places.  Eg,


  cc -o executable prog.c -lsomelib -L /usr/local/BerkeleyDB/lib -R / 
usr/local/BerkeleyDB/lib


(All on one line, of course; the mailer will probably wrap the above.)

It works for us...  :-)

Cheers,
Mike B-)

--
The Computing Service, University of York, Heslington, York Yo10 5DD, UK
Tel:+44-1904-433811  FAX:+44-1904-433740

* Unsolicited commercial e-mail is NOT welcome at this e-mail address. *



Re: [Dovecot] [OT] Webmail Recommendation

2008-01-11 Thread Mike Brudenell

Greetings -

On 10 Jan 2008, at 21:49, Chris Wakelin wrote:

With Dovecot's caching and indexing, things are much better, but  
there is still a significant overhead on opening lots of  
connections, I fear, especially for mboxes (moving to maildir would  
help of course). I would consider using imapproxy (designed to  
assist with this problem by caching the IMAP connections) but I'm  
not sure whether it would help significantly.


Whatever you do, DON'T move to Maildir if you are using the Prayer  
webmail software!


We have used Prayer here for many years with the UW IMAP server  
backend and first Berkeley, then later MBX, format mail folders.


When we migrated new users to Dovecoe with Maildir folders we  
discovered that Prayer does NOT like Maildir folders.  The reason is  
that Maildir folders are "dual-purpose": each can contain any mix of  
messages and sub-folders.  However Prayer is intrinsically designed to  
ONLY work with folders that can contain messages or subfolders, but  
NOT both.  The result is that Prayer can show you the list of folders  
to navigate around, but will not list any messages within any folder.


I checked with Cambridge and this is a known and documented  
restriction with Prayer.  Their solution has been to hack Cyrus to  
prevent dual-use folders.  (Timo kindly supplied us with a patch for  
Dovecot 1.0.x to do likewise.)


We are thinking about moving to a different webmail platform soon, so  
I am following this discussion with interest.


I can confirm that webmail software that uses persistent IMAP  
connections is a big win: it not only lightens load on the webmail  
server machine but also, more importantly, on the IMAP servers.


Cheers,
Mike B-)

--
The Computing Service, University of York, Heslington, York Yo10 5DD, UK
Tel:+44-1904-433811  FAX:+44-1904-433740

* Unsolicited commercial e-mail is NOT welcome at this e-mail address. *



[Dovecot] Please remove me

2008-01-16 Thread Mike McGonagle
Hello Mr List Administrator,
I have tried to remove myself from this list, but for some reason, these
requests are being ignored, and I am still receiving these mailings.

Could someone in charge PLEASE remove me email address from this list?

Thank you,

Michael McGonagle


[Dovecot] OT: Skins for Squirrelmail - looking for a reminder

2008-02-08 Thread Mike Brudenell

Greetings -

On one of the mailing lists I'm on there was a recent-ish discussion  
about webmail clients, and someone mentioned a site selling sets of  
skins for SquirrelMail... the entire set was about $300.


I'm trying to track down the site but seem to have deleted the message  
I'd carefully been keeping.


I recall an off-topic discussion along these lines here recently, but  
can't locate anything about skins in the archives.  Can anyone recall  
this?  Or am I mis-remembering it as being here on this list?


Confused, but then it is Friday... :-)

Cheers,
Mike B-)

--
The Computing Service, University of York, Heslington, York Yo10 5DD, UK
Tel:+44-1904-433811  FAX:+44-1904-433740

* Unsolicited commercial e-mail is NOT welcome at this e-mail address. *



[Dovecot] "too little data" error still occurring in 1.0.10

2008-02-09 Thread Mike Brown
Greetings-

I'm running dovecot 1.0.10, but am seeing the "too little data" error
that was supposedly fixed in 1.0.9. Not sure how long it's been going on.

I have a straightforward mbox setup, and am using Thunderbird to check my
inbox. It can't read the box. The log fills up with these messages:

Feb  8 23:24:43 chilled dovecot: imap-login: Login: user=, method=PLAIN, 
rip=##.##.##.##, lip=##.##.##.##, TLS
Feb  8 23:24:43 chilled dovecot: IMAP(mike): FETCH for mailbox INBOX UID 1644 
got too little data: 4254 vs 4262
Feb  8 23:24:43 chilled dovecot: IMAP(mike): Disconnected: Disconnected

Let me know if there's more info needed.

-Mike


Re: [Dovecot] "too little data" error still occurring in 1.0.10

2008-02-11 Thread Mike Brown
Timo Sirainen wrote:
> On Sat, 2008-02-09 at 02:53 -0700, Mike Brown wrote:
> > I'm running dovecot 1.0.10, but am seeing the "too little data" error
> > that was supposedly fixed in 1.0.9. Not sure how long it's been going on.
> 
> Did you try deleting dovecot.index.cache files from those mailboxes and
> see if it comes back?

I tried that just now, and so far, things are back to normal. Thanks!
I guess I don't need the patch. Do you want me to try it anyway?

Mike


Re: [Dovecot] "too little data" error still occurring in 1.0.10

2008-02-12 Thread Mike Brown
Timo Sirainen wrote:
> On Feb 12, 2008, at 1:14 AM, Mike Brown wrote:
> 
> > Timo Sirainen wrote:
> >> On Sat, 2008-02-09 at 02:53 -0700, Mike Brown wrote:
> >>> I'm running dovecot 1.0.10, but am seeing the "too little data"  
> >>> error
> >>> that was supposedly fixed in 1.0.9. Not sure how long it's been  
> >>> going on.
> >>
> >> Did you try deleting dovecot.index.cache files from those mailboxes  
> >> and
> >> see if it comes back?
> >
> > I tried that just now, and so far, things are back to normal. Thanks!
> > I guess I don't need the patch. Do you want me to try it anyway?
> 
> Try the patch if the problem comes back.
> 

The problem came back, so I will apply the patch. :(

Thanks!


[Dovecot] ACLs - what's the state of play?

2008-02-13 Thread Mike Brudenell

Greetings -

Could someone help me understand what the latest situation id with  
regard to ACLs and sharing mailboxes, please?


Currently we are using Dovecot 1.0.x but will be moving to 1.1 when it  
comes out of Beta (and hopefully I'll get some time before too long to  
try building a test setup to play with).  So I'm happy to talk only  
about ACLs and sharing mailboxes in 1.1...


We are using Maildir storage format, and separate areas for each of  
the Control and Index files.  We are using real system users with  
filestore quotas.  Currently each user's files and directories are  
owner by their own uid and gid (but we can change this if need be),  
and are set to disallow filestore-level access to "group" or  
"others" (but we can change this too if need be).


We need to know (quite urgently) if the following is/will be possible  
with 1.1:


  *  Can person A have some (a subset) of their folders accessible by  
others?

 If so, can this be Read-Only?  can it be Read-Write?

  *  Can person A have all of their currently existing folders  
accessible

 by others, along with any folders they create in the future?

  *  Is there support for the IMAP ACL extension, enabling users to set
 and manage access rights themselves from their mail client?

  *  If system username "abc1" has made their top-level folder  
"Project"
 accessible by system username "def2", how does def2 actually  
specify

 the folder in order to open it?

I have rummaged through the archives and Wiki but mostly these still  
talk about the magical "dovecot-shared" and "dovecot-acl" files, and  
how these need to be created/maintained by the system administrator.


What we're hoping for is the Holy Grail of:

   *  a Manager wanting to give their Secretary read-write (or in  
some cases

  read-only) access to some or all of their folders;

   *  a Project Team wanting to access a common set of mail folders;

   *  etc

Under the old UW IMAP server you would authenticate as yourself, then  
specify someone else's folder with something like (the memory is hazy  
on this now):

~abc1/Project

In the Dovecot Wiki I read a lot about namespaces and so on, but can't  
seem to piece together in my mind what these actually *look* like to  
the end-user wanting to access someone else's shared mailbox.  Nor  
what can be done by the end-users, and what has to be done by the  
system administrator.


Can anyone offer me advice, please?

With many thanks,
Mike B-)

--
The Computing Service, University of York, Heslington, York Yo10 5DD, UK
Tel:+44-1904-433811  FAX:+44-1904-433740

* Unsolicited commercial e-mail is NOT welcome at this e-mail address. *



Re: [Dovecot] "too little data" error still occurring in 1.0.10

2008-02-27 Thread Mike Brown
Timo Sirainen wrote:
> On Tue, 2008-02-12 at 20:28 -0700, Mike Brown wrote:
> > Timo Sirainen wrote:
> > > On Feb 12, 2008, at 1:14 AM, Mike Brown wrote:
> > > 
> > > > Timo Sirainen wrote:
> > > >> On Sat, 2008-02-09 at 02:53 -0700, Mike Brown wrote:
> > > >>> I'm running dovecot 1.0.10, but am seeing the "too little data"  
> > > >>> error
> > > >>> that was supposedly fixed in 1.0.9. Not sure how long it's been  
> > > >>> going on.
> > > >>
> > > >> Did you try deleting dovecot.index.cache files from those mailboxes  
> > > >> and
> > > >> see if it comes back?
> > > >
> > > > I tried that just now, and so far, things are back to normal. Thanks!
> > > > I guess I don't need the patch. Do you want me to try it anyway?
> > > 
> > > Try the patch if the problem comes back.
> > > 
> > 
> > The problem came back, so I will apply the patch. :(
> 
> Did the patch fix it?
> 

As far as I can tell. The problem hasn't returned since I applied the patch
2 weeks ago. Thanks!


[Dovecot] Panic: IMAP(...): Trying to close mailbox INBOX with open transactions

2008-05-16 Thread Mike Abbott
I have been seeing this crash, which has been reported before but  
apparently not yet resolved.  As with the previous reporters, I do not  
know how to reproduce it reliably.


Dovecot version: 1.1.rc5
Operating system: Mac OS X 10.5.2
CPU architecture: x86
File system: HFS+
Activity:  From the backtrace it appears the client logged out while  
in the middle of some operation.

Backtrace:
0   libSystem.B.dylib   0x946210ea __kill + 10
1   libSystem.B.dylib   0x946983f2 raise + 26
2   libSystem.B.dylib   0x946a79af abort + 73
3   imap  	0x000743e2 i_internal_fatal_handler  
+ 102

4   imap0x00073e03 i_fatal + 0
5   imap0x0004614c mailbox_close + 48
6   imap0x53c4 cmd_logout + 74
7   imap0x7f14 client_command_input + 41
8   imap0x80d9 client_command_input + 494
9   imap0x81c5 client_handle_input + 218
10  imap0x835d client_input + 176
11  imap0x0007c001 io_loop_handler_run + 350
12  imap0x0007af06 io_loop_run + 44
13  imap0x00010732 main + 1972
14  imap0x1e76 start + 54



[Dovecot] Maildir locking by LDA of dovecot

2008-05-21 Thread Mike Grozak

Hi all!

First of all, I want ti thank the whole Dovecot community (developers 
for developing and fast responses, users for populating and responses 
too). Dovecot is a really good and fast IMAP server - it serves near 
3000 in our installation.


Now I have a problem and request community's help its resolving;)
Dovecot version: 1.0.13, compiled with vpopmail support.
I have an account [EMAIL PROTECTED] (:-), in which we put all our spam (we 
gather statistic later). There can be 10 and more delivery attempts in a 
second to maildir of this account during the spam attacks on our server. 
The queue of our server can grow up to 20k messages, and all of these 
messages are sent to [EMAIL PROTECTED] I found a lot of such strings in 
dovecot.log file during the such DoS attack:
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:18:48 Info: 
msgid=<[EMAIL PROTECTED]>: save failed to INBOX: Timeout 
while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:18:59 Info: 
msgid=<[EMAIL PROTECTED]>: 
save failed to INBOX: Timeout while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:20:06 Info: 
msgid=<[EMAIL PROTECTED]>: save failed to INBOX: Timeout 
while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:20:14 Info: 
msgid=<[EMAIL PROTECTED]>: save failed to INBOX: 
Timeout while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:20:50 Info: 
msgid=<[EMAIL PROTECTED]>: save failed to INBOX: Timeout 
while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:21:00 Info: 
msgid=<[EMAIL PROTECTED]>: save 
failed to INBOX: Timeout while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:21:01 Info: 
msgid=<[EMAIL PROTECTED]>: save failed to INBOX: 
Timeout while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:22:32 Info: 
msgid=<[EMAIL PROTECTED]>: save failed to INBOX: 
Timeout while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:22:45 Info: 
msgid=<[EMAIL PROTECTED]>: save failed to INBOX: 
Timeout while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:22:45 Info: 
msgid=<[EMAIL PROTECTED]>: save failed to INBOX: 
Timeout while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:23:08 Info: 
msgid=<[EMAIL PROTECTED]>: save failed to INBOX: Timeout 
while waiting for lock


My dovecot.conf:
$ cat /etc/dovecot.conf | grep -v \# | grep -v ^\n
protocols = imap pop3
log_path = /var/log/dovecot.log
ssl_disable = yes
login_user = dovecot
login_process_per_connection = no
login_max_connections = 1024
login_greeting = Server is ready.
>>dotlock_use_excl = yes - can it be the reason?
fsync_disable = yes
first_valid_uid = 39
last_valid_uid = 39
first_valid_gid = 39
last_valid_gid = 39
max_mail_processes = 1024
maildir_copy_with_hardlinks = yes
maildir_copy_preserve_filename = yes

protocol imap {
 mail_plugins = quota imap_quota
 login_greeting_capability = yes
 imap_client_workarounds = outlook-idle
}

protocol pop3 {
 pop3_lock_session = no
 pop3_uidl_format = %08Xu%08Xv
 mail_plugins = quota
}

protocol lda {
 postmaster_address = [EMAIL PROTECTED]
 mail_plugins = quota cmusieve
 sendmail_path = /usr/lib/sendmail
 fsync_disable = no
}

auth_cache_size = 10240
auth_username_format = %Lu

auth default {
   mechanisms = plain login cram-md5
   socket listen {
  master {
  path = /var/run/dovecot/auth-master
  mode = 0666
 }
 client {
   path = /var/spool/postfix/private/auth
   mode = 0666
   user = postfix
   group = postfix
   }
   }

 passdb vpopmail {
   args = cache_key=%u dovecot
 }
 userdb vpopmail {
 }

 user = vpopmail

 ssl_require_client_cert = no
}

dict {
}


plugin {
 quota = maildir:ignore=Trash
}


What can I do for resolving this locks?
May be, while looking into uidlist file, can dovecot LDA lock it? And 
other deliver processes can't open it and wait for him?


---
WBR, Mike Grozak, TvSU IC


[Dovecot] Clients hang because imap-login discards post-login commands

2008-05-21 Thread Mike Abbott
Some of my IMAP clients hang when connecting to Dovecot 1.1.rc5.  I  
believe the problem is that imap-login reads eagerly rather than  
sparingly.  If a client sends

a login user password
b select Inbox
all at once, without waiting for the login reply before sending the  
select, imap-login eats the second command (reads it from the socket  
and does nothing with it; system call tracing confirms this) and the  
client hangs waiting for a reply to the select command.  I can  
reproduce this simply using telnet to the dovecot on localhost, as  
long as I send both lines at once (I paste them in together).


$ telnet localhost 143
* OK Dovecot ready.
a login user password
b select Inbox
a OK Logged in.


This may also be true with pop3-login, I have not checked.  It does  
happen (with IMAP) when authentication is delayed and Dovecot responds  
with "* OK Waiting for authentication process to respond.." but I  
believe that shares the same underlying cause as the simpler case above.


I believe the login processes should read only as much as they need to  
satisfy the login request and leave subsequent commands in the socket  
for post-login processing.  Or, the login processes should pass the  
remainder of their input buffers to the mail processes so no commands  
are dropped.  This section of RFC 2060 explains why I think this:


5.5.Multiple Commands in Progress

   The client MAY send another command without waiting for the
   completion result response of a command, subject to ambiguity rules
   (see below) and flow control constraints on the underlying data
   stream.  Similarly, a server MAY begin processing another command
   before processing the current command to completion, subject to
   ambiguity rules.  [...]

   The exception is if an ambiguity would result because of a command
   that would affect the results of other commands.  Clients MUST NOT
   send multiple commands without waiting if an ambiguity would result.
   If the server detects a possible ambiguity, it MUST execute commands
   to completion in the order given by the client.

So it appears that both the client and Dovecot may be in violation,  
depending on how you define "ambiguity."  The RFC does not explicitly  
define whether login causes an ambiguity, but I personally believe  
that login does "affect the results of other commands" (the login may  
fail, for instance).  So the client should not issue commands before  
receiving the login reply, and Dovecot should not drop commands during  
login.  I have reported the client issue to the developers of the IMAP  
client, as I am reporting the server issue to you.  Fortunately for  
me, only one or the other needs to change to erase the symptom (hung  
clients), but fixing both would be best.


Thanks for your attention.

[Dovecot] Maildir locking by LDA of dovecot

2008-05-22 Thread Mike Grozak

Hi all!

First of all, I want ti thank the whole Dovecot community (developers
for developing and fast responses, users for populating and responses
too). Dovecot is a really good and fast IMAP server - it serves near
3000 in our installation.

Now I have a problem and request community's help its resolving;)
Dovecot version: 1.0.13, compiled with vpopmail support.
I have an account [EMAIL PROTECTED] (:-), in which we put all our spam (we
gather statistic later). There can be 10 and more delivery attempts in a
second to maildir of this account during the spam attacks on our server.
The queue of our server can grow up to 20k messages, and all of these
messages are sent to [EMAIL PROTECTED] I found a lot of such strings in
dovecot.log file during such DoS attack:

dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:18:48 Info:
msgid=<[EMAIL PROTECTED]>: save failed to INBOX: Timeout
while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:18:59 Info:
msgid=<[EMAIL PROTECTED]>:
save failed to INBOX: Timeout while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:20:06 Info:
msgid=<[EMAIL PROTECTED]>: save failed to INBOX: Timeout
while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:20:14 Info:
msgid=<[EMAIL PROTECTED]>: save failed to INBOX:
Timeout while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:20:50 Info:
msgid=<[EMAIL PROTECTED]>: save failed to INBOX: Timeout
while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:21:00 Info:
msgid=<[EMAIL PROTECTED]>: save
failed to INBOX: Timeout while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:21:01 Info:
msgid=<[EMAIL PROTECTED]>: save failed to INBOX:
Timeout while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:22:32 Info:
msgid=<[EMAIL PROTECTED]>: save failed to INBOX:
Timeout while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:22:45 Info:
msgid=<[EMAIL PROTECTED]>: save failed to INBOX:
Timeout while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:22:45 Info:
msgid=<[EMAIL PROTECTED]>: save failed to INBOX:
Timeout while waiting for lock
dovecot.log:deliver([EMAIL PROTECTED]): May 16 04:23:08 Info:
msgid=<[EMAIL PROTECTED]>: save failed to INBOX: Timeout
while waiting for lock

What can I do for resolving this locks? The queue of my server becomes 
really big!

May be, while looking into uidlist file, can dovecot LDA lock it? And
other deliver processes can't open it and wait for him?

$ dovecot --version
1.0.13

# dovecot -n
# 1.0.13: /etc/dovecot.conf
log_path: /var/log/dovecot.log
protocols: imap pop3
ssl_disable: yes
login_dir: /var/run/dovecot/login
login_executable(default): /usr/libexec/dovecot/imap-login
login_executable(imap): /usr/libexec/dovecot/imap-login
login_executable(pop3): /usr/libexec/dovecot/pop3-login
login_greeting: Server is ready.
login_process_per_connection: no
login_greeting_capability(default): yes
login_greeting_capability(imap): yes
login_greeting_capability(pop3): no
login_max_connections: 1024
first_valid_uid: 39
last_valid_uid: 39
first_valid_gid: 39
last_valid_gid: 39
fsync_disable: yes
maildir_copy_with_hardlinks: yes
mail_executable(default): /usr/libexec/dovecot/imap
mail_executable(imap): /usr/libexec/dovecot/imap
mail_executable(pop3): /usr/libexec/dovecot/pop3
mail_plugins(default): quota imap_quota
mail_plugins(imap): quota imap_quota
mail_plugins(pop3): quota
mail_plugin_dir(default): /usr/lib/dovecot/imap
mail_plugin_dir(imap): /usr/lib/dovecot/imap
mail_plugin_dir(pop3): /usr/lib/dovecot/pop3
auth default:
  mechanisms: plain login cram-md5
  default_realm: tversu.ru
  cache_size: 10240
  user: vpopmail
  username_format: %Lu
  passdb:
driver: vpopmail
args: cache_key=%u dovecot
  userdb:
driver: vpopmail
  socket:
type: listen
client:
  path: /var/spool/postfix/private/auth
  mode: 438
  user: postfix
  group: postfix
master:
  path: /var/run/dovecot/auth-master
  mode: 438
plugin:
  quota: maildir:ignore=Trash

---
WBR, Mike Grozak, TvSU IC



Re: [Dovecot] Maildir locking by LDA of dovecot

2008-05-22 Thread Mike Grozak

Charles Marcus wrote:

On 5/22/2008, Mike Grozak ([EMAIL PROTECTED]) wrote:


First of all, I want ti thank the whole Dovecot community (developers
for developing and fast responses, users for populating and responses
too). Dovecot is a really good and fast IMAP server - it serves near
3000 in our installation. 


What filesystem is this on?

ext3.

How can I escape dovecot-uidlist locking? it really locks my system!
---
WBR, Mike Grozak, TvSU IC


[Dovecot] typo in failures.c

2008-06-06 Thread Mike Abbott
Hi, I found a typo on line 101 of dovecot-1.1.rc8/src/lib/failures.c.   
The first two arguments to io_add() are reversed.  The fd should be  
first, and IO_WRITE second.


[Dovecot] Corrupted index cache files

2008-08-08 Thread Mike Abbott
I see these errors more often than I'd like from Dovecot-1.1.2 on Mac  
OS X 10.5.4 (names and numbers elided):


Corrupted index cache file %s: Corrupted virtual size for uid=%d: %d ! 
= %d

Corrupted index cache file %s: Broken virtual size for mail UID %d
Corrupted index cache file %s: used_file_size too large

How bad are these?  What should I look for to find out why they happen?

Other details:
File system is HFS+
Mail store is maildir
Hardware is Intel (Mac Pro)

Thanks.


Re: [Dovecot] Corrupted index cache files

2008-08-13 Thread Mike Abbott

One or more users?


Many different users.


Post your dovecot -n output?


Here's some of it.  Not very enlightening.
# 1.1.2: /etc/dovecot/dovecot.conf
base_dir: /var/run/dovecot/
verbose_proctitle: yes
first_valid_uid: 6
last_valid_uid: 5
first_valid_gid: 6
last_valid_gid: 5
mail_access_groups: mail
mail_privileged_group: mail
mail_location: maildir:~/mail


Can you reproduce these easily with my imaptest tool? 
http://imapwiki.org/ImapTest


Some of them.  When running imaptest I see these dovecot errors:
Corrupted index cache file %s: record continues outside its allocated  
size

Corrupted index cache file %s: record points outside file
Corrupted index cache file %s: used_file_size too large

Plus I see LOTS of errors from imaptest itself:
Error: UIVALIDITY changed: %d -> %d
Error: user%d[%d]: <...>: Header CC changed
Error: user%d[%d]: <...>: Header DELIVERED-TO changed
Error: user%d[%d]: <...>: Header FROM changed
Error: user%d[%d]: <...>: Header IN-REPLY-TO changed
Error: user%d[%d]: <...>: Header MESSAGE-ID changed
Error: user%d[%d]: <...>: Header REFERENCES changed
Error: user%d[%d]: <...>: Header SUBJECT changed
Error: user%d[%d]: <...>: Header SUBJECT changed
Error: user%d[%d]: <...>: Header TO changed
Error: user%d[%d]: UID %d changed Message-Id
Error: user%d[%d]: UID=%d INTERNALDATE changed
Error: user%d[%d]: uid=%d <...>: BODY changed
Error: user%d[%d]: uid=%d <...>: BODYSTRUCTURE changed
Error: user%d[%d]: uid=%d <...>: BODY[%d] size changed
Error: user%d[%d]: uid=%d <...>: BODY[HEADER] size changed
Error: user%d[%d]: uid=%d <...>: BODY[TEXT] size changed
Error: user%d[%d]: uid=%d <...>: BODY[] size changed
Error: user%d[%d]: uid=%d <...>: ENVELOPE changed
Error: user%d[%d]: uid=%d <...>: RFC822.SIZE size changed

One problem with HFS+ is that hard links are more or less buggy. But  
v1.1's default settings should include dotlock_use_excl=yes. You  
maybe should set maildir_copy_with_hardlinks=no, but that shouldn't  
cause this bug.


Changing maildir_copy_with_hardlinks makes no difference.

You say that the dovecot errors are harmless because dovecot fixes  
them, but still there must be some downside, if only a performance  
hit.  Any other info I can provide to help you figure this out?


Re: [Dovecot] Corrupted index cache files

2008-08-13 Thread Mike Abbott
How soon? With what kind of imaptest parameters? I can't reproduce  
this on my Macbook (OS X 10.5.4, HFS+).


I ran imaptest for just a few minutes and saw all these errors in that  
time.  Default imaptest parameters except for user/host names etc.



Error: UIVALIDITY changed: %d -> %d


Did you test with a single user or multiple users? imaptest's  
support for testing multiple users is currently a bit broken, but  
this shouldn't happen with a single user..


This error happens with clients=1, clients=10 and clients=100.


Error: user%d[%d]: <...>: Header CC changed
Error: user%d[%d]: <...>: Header DELIVERED-TO changed
Error: user%d[%d]: <...>: Header FROM changed


These shouldn't be happening as long as you use a test mbox file  
that has unique Message-ID headers. Were you using the recommended  
dovecot-crlf as the input?


I passed in your dovecot-crlf file to imaptest, but the message store  
was cloned from elsewhere first.  So you're saying that dovecot only  
works with special hand-crafted input, and not with real-world mail?   
Hmmm :) :)


Actually I do see plenty of duplicate Message-ID headers in the mail  
store (not from your input file).  I'll investigate that further.   
Thanks for the tip.


Re: [Dovecot] Corrupted index cache files

2008-08-14 Thread Mike Abbott
I re-ran imaptest on an empty mail store, single client, multiple  
users, using your dovecot-crlf input file, for a couple hours.  Here's  
the distribution of errors that imaptest reports:

 100 Error: user%d[%d]: <...>: Header DELIVERED-TO changed
 167 Error: user%d[%d]: <...>: Header CC changed
 417 Error: user%d[%d]: <...>: Header TO changed
 438 Error: user%d[%d]: <...>: Header IN-REPLY-TO changed
 445 Error: user%d[%d]: <...>: Header REFERENCES changed
 485 Error: user%d[%d]: <...>: Header FROM changed
 503 Error: user%d[%d]: <...>: Header SUBJECT changed
 544 Error: user%d[%d]: <...>: Header MESSAGE-ID changed
 764 Error: user%d[%d]: UID=%d INTERNALDATE changed
 823 Error: user%d[%d]: UID %d changed
1040 Error: user%d[%d]: uid=%d <...>: BODY changed
1052 Error: user%d[%d]: uid=%d <...>: BODYSTRUCTURE changed
1546 Error: user%d[%d]: uid=%d <...>: ENVELOPE changed
1833 Error: user%d[%d]: uid=%d <...>: RFC822.SIZE size changed
3493 Error: user%d[%d]: uid=%d <...>: BODY[] size changed
3691 Error: user%d[%d]: uid=%d <...>: BODY[HEADER] size changed
3695 Error: user%d[%d]: uid=%d <...>: BODY[TEXT] size changed
3880 Error: user%d[%d]: uid=%d <...>: BODY[%d] size changed
376365 Error: UIVALIDITY changed: %d -> %d

During that time dovecot reported no corruption errors.

What does it mean that imaptest is having such trouble?


[Dovecot] Migrating mbox to maildir

2008-08-14 Thread Mike Hobbs
Sorry to bother everyone but I was wondering if it is possible for 
Dovecot to handle mbox AND maildir at the same time?


Example:

I want to convert from UW Imap using mbox to Dovecot using maildir.

Do I need to convert ALL my users mbox mailboxes to maildir right away 
or can I convert them one at a time?


I'd like to use maildir with all my new users, but I'd like to be able 
to continue using mbox for my old users and slowly convert them as I get 
time.


Is this possible?  I know Dovecot supports both formats, I just couldn't 
find anything in the install notes about using both at the same time.


Thank you,

mike


[Dovecot] Multiple network interface question

2008-08-25 Thread Mike Henry

Hi all,

Sorry if this question has been posted before. I have dug through the  
archives but haven't found any relevant answers to this question.


I am running Dovecot on a server that serves a number of (virtual)  
domains each with a number of (virtual) users.


To read mail I am providing a webmail client and have configured HTTPS  
connections using reverse DNS so that each domain has its own IP  
address and that each IP address gets mapped to a different virtual  
host. Each virtual host presents and HTTPS connection particular to  
their own domain using the SSL certificate for that domain so that  
each user only sees his or her own domain throughout.


Is it possible to configure Dovecot so that mail-clients like  
Thunderbird or Outlook can connect via the default port using their  
own domain (maybe also using reverse DNS) and be presented with an SSL  
connection particular to that domain (i.e. using that domains  
certificate)?


Any comments welcome.

Thanks in advance,

-Mike


[Dovecot] Dovecot-1.1.2 segfaults in mail_cache_header_fields_get_offset

2008-08-29 Thread Mike Abbott
Dovecot 1.1.2 crashes reliably for me now on a Mac OS X machine.   
Here's some info:


--- Telnet session ---
$ telnet localhost 143
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
* OK Dovecot ready.
a login user1 password
a OK Logged in.
b select inbox
* FLAGS (\Answered \Flagged \Deleted \Seen \Draft)
* OK [PERMANENTFLAGS (\Answered \Flagged \Deleted \Seen \Draft \*)]  
Flags permitted.

* 1 EXISTS
* 1 RECENT
* OK [UNSEEN 1] First unseen.
* OK [UIDVALIDITY 1218731580] UIDs valid
* OK [UIDNEXT 2] Predicted next UID
b OK [READ-WRITE] Select completed.
c fetch 1 rfc822.size
Connection closed by foreign host.

--- Error log ---
dovecot: Aug 29 11:24:30 Info: imap-login: Login: user=,  
method=PLAIN, rip=127.0.0.1, lip=127.0.0.1, secured
dovecot: Aug 29 11:24:33 Error: IMAP(user1): Corrupted transaction log  
file /Volumes/Spool/spool/user1/mail/dovecot.index.log: hdr.size too  
large (75497472)
dovecot: Aug 29 11:24:33 Warning: IMAP(user1): fscking index file / 
Volumes/Spool/spool/user1/mail/dovecot.index

dovecot: Aug 29 11:24:48 Error: child 66917 (imap) killed with signal 11

--- Backtrace ---
mail_cache_header_fields_get_offset + 214
mail_cache_header_fields_read + 37
mail_cache_open_and_verify + 167
mail_cache_field_exists + 77
index_mail_set_seq + 306
index_storage_search_next_nonblock + 464
mailbox_search_next + 52
imap_fetch + 345
cmd_fetch + 639
client_command_input + 33
client_command_input + 463
client_handle_input + 242
client_input + 151
io_loop_handler_run + 272
io_loop_run + 39
main + 1671
start + 52

If I do the exact same telnet all over again, the imap process crashes  
in the same place, but without reporting the "fscking index file"  
error first.  Attached are all the post-fsck dovecot* files from the  
user's inbox maildir.


For other users I see this error before imap crashes:
dovecot: Aug 29 11:45:23 Error: IMAP(user2): Rebuilding index file / 
Volumes/Spool/spool/user2/mail/dovecot.index: CPU architecture changed
Attached are pre- and post-rebuild copies of that user's dovecot*  
files, and also a copy from after a second telnet session which also  
crashed.


It's possible this is a 32/64-bit incompatibility issue (imap is a 64- 
bit program for me; mail might have been delivered by a 32-bit deliver  
or previously read by a 32-bit imap) but more likely the dovecot*  
files are just hosed in some way.


I can provide more information if you ask soon, but I can't keep this  
server broken for too long.




user1-post.tgz
Description: Binary data






user2-pre.tgz
Description: Binary data

 

user2-post.tgz
Description: Binary data

 

user2-final.tgz
Description: Binary data


[Dovecot] Dovecot-1.1.2 assertion failure in preparsed_parse_next_header_init

2008-08-29 Thread Mike Abbott
Panic: IMAP(user): file message-parser.c: line 684  
(preparsed_parse_next_header_init): assertion failed: (ctx->part- 
>physical_pos >= ctx->input->v_offset)


Linux 2.6.24-19-386
Maildir on ext3

Looks similar to but different from http://dovecot.org/list/dovecot/2008-June/031523.html 
 .


#0  0xb7faf410 in __kernel_vsyscall ()
#1  0xb7e6f085 in raise () from /lib/tls/i686/cmov/libc.so.6
#2  0xb7e70a01 in abort () from /lib/tls/i686/cmov/libc.so.6
#3  0x080d2b65 in default_fatal_finish (type=,  
status=0)

at failures.c:149
#4  0x080d2bba in i_internal_fatal_handler (type=LOG_TYPE_PANIC,  
status=0,

fmt=0x80e5fec "file %s: line %d (%s): assertion failed: (%s)",
args=0xbfb4b1d4 "\017L\017\b?\002") at failures.c:423
#5  0x080d246c in i_panic (
format=0x80e5fec "file %s: line %d (%s): assertion failed: (%s)")
at failures.c:190
#6  0x080cc246 in preparsed_parse_next_header_init (ctx=0x812b650,
block_r=0xbfb4b24c) at message-parser.c:684
#7  0x080cbc0d in message_parser_parse_next_block (ctx=0x812b650,
block_r=0xbfb4b24c) at message-parser.c:753
#8  0x080cbd5e in message_parser_parse_body (ctx=0x812b650,
hdr_callback=0x80968a0 ,
context=0x812e658) at message-parser.c:816
#9  0x08097f21 in index_mail_parse_body (mail=0x8122668,
field=MAIL_CACHE_IMAP_BODYSTRUCTURE) at index-mail.c:753
#10 0x08098026 in index_mail_parse_bodystructure (mail=0x8122668,
field=MAIL_CACHE_IMAP_BODYSTRUCTURE) at index-mail.c:860
#11 0x0809852c in index_mail_get_special (_mail=0x8122668,
field=MAIL_FETCH_IMAP_BODYSTRUCTURE, value_r=0xbfb4b370)
at index-mail.c:983
#12 0x08078a18 in maildir_mail_get_special (_mail=0x6, field=0,
value_r=0xbfb4b370) at maildir-mail.c:437
#13 0x080643f4 in fetch_bodystructure (ctx=0x810b708, mail=0x8122668,
context=0x0) at imap-fetch.c:450
#14 0x08064960 in imap_fetch (ctx=0x810b708) at imap-fetch.c:309
#15 0x0805e44e in cmd_fetch (cmd=0x810b670) at cmd-fetch.c:152
#16 0x080625cc in client_command_input (cmd=0x810b670) at client.c:580
#17 0x08062675 in client_command_input (cmd=0x810b670) at client.c:629
#18 0x08062e43 in client_handle_input (client=0x810b418) at client.c:670
#19 0x0806305e in client_input (client=0x810b418) at client.c:725
#20 0x080da4a7 in io_loop_handler_run (ioloop=0x8109a60) at ioloop- 
epoll.c:201

#21 0x080d9628 in io_loop_run (ioloop=0x8109a60) at ioloop.c:308
#22 0x0806ab5d in main (argc=Cannot access memory at address 0x2acc
) at main.c:293
(gdb) frame 6
#6  0x080cc246 in preparsed_parse_next_header_init (ctx=0x812b650,
block_r=0xbfb4b24c) at message-parser.c:684
684 i_assert(ctx->part->physical_pos >= ctx->input->v_offset);
(gdb) p ctx
$1 = (struct message_parser_ctx *) 0x812b650
(gdb) p ctx->input
$2 = (struct istream *) 0x8113618
(gdb) p ctx->part
$3 = (struct message_part *) 0x812e7c0
(gdb) p *ctx
$4 = {parser_pool = 0x812b638, part_pool = 0x0, input = 0x8113618,
  parts = 0x812e730, part = 0x812e7c0, hdr_flags = 3,
  flags = MESSAGE_PARSER_FLAG_SKIP_BODY_BLOCK, last_boundary = 0x0,
  boundaries = 0x0, skip = 0, last_chr = 0 '\0', want_count = 0,
  hdr_parser_ctx = 0x0,
  parse_next_block = 0x80cc1e0 ,
  part_seen_content_type = 0, broken = 1}
(gdb) p *ctx->part
$5 = {parent = 0x812e778, next = 0x0, children = 0x0, physical_pos =  
688,

  header_size = {physical_size = 90, virtual_size = 93, lines = 0},
  body_size = {physical_size = 505, virtual_size = 514, lines = 9},
  flags = 72, context = 0x0}
(gdb) p *ctx->input
$6 = {v_offset = 759, stream_errno = 0, mmaped = 0, blocking = 1,  
closed = 0,

  seekable = 1, eof = 0, real_stream = 0x81135f0}



Re: [Dovecot] Dovecot-1.1.2 segfaults in mail_cache_header_fields_get_offset

2008-09-02 Thread Mike Abbott
After wondering for a while, I can now reproduce your problems. The  
only

thing I had to do was to define WORDS_BIGENDIAN on a little-endian
machine. Why are you doing that? :)


Er, you're right.  I built a "fat" (multi-architecture) Dovecot  
executable on a big-endian PowerPC/MacOSX machine and ran it on a  
little-endian Intel/MacOSX machine.  The configure script does not  
allow for the build and run systems to have different endianness.   
I'll find a way around that.  Thanks!


Re: [Dovecot] mail_executable's process environment

2008-10-21 Thread Mike Malsman

On Oct 21, 2008, at 11:44 AM, Charles Marcus wrote:

On 10/20/2008, Mike Malsman ([EMAIL PROTECTED]) wrote:

Is this something that would be useful to anyone else?


PopB4smtp is really insecure, and should be avoided if at all
possible... so hopefully , it won't be useful to too many people... ;)


I see this mechanic as not being specific to pop3/imap-before-smtp.   
I'm not sure in what other ways people use replacement imap/pop3  
processes, but the destination address seems like a useful piece of  
information.



You really should set up sasl/smtpauth and just deal with the one time
pain of changing over... it will be worth it...


In fact I have.  Thanks for the suggestion!

-Mike


[Dovecot] mail_executable's process environment

2008-10-21 Thread Mike Malsman

Hello,

I recently had to get Dovecot 1.1.4 to write to a "pop3/imap-before- 
smtp" db such that my MTA could permit relay after a successful  
authentication with Dovecot.


The 'pop3' and 'imap' processes are executed only after a successful  
auth, so replacing them with wrappers which write to the db seemed the  
natural choice.  Lo and behold, someone thought of something like  
this, as the 'mail_executable' directive exists - neat.


Upon inspection of the processes' environment I'm pleased to see that  
there's a load of useful information in there.  However, one essential  
component in my case is the destination network address, which is  
missing.  I added it with the attached patch, exposed as 'LOCAL_IP'.   
Works for me.


Is this something that would be useful to anyone else?

-Mike



dovecot-1.1.4-local.ip.patch
Description: Binary data




[Dovecot] Panic: pop3-login: file sasl-server.c: line 75 (authenticate_callback): assertion failed: (client->auth_request == request)

2008-10-29 Thread Mike Abbott

Running Dovecot-1.1.5, I see this assertion failure:
Panic: pop3-login: file sasl-server.c: line 75  
(authenticate_callback): assertion failed: (client->auth_request ==  
request)

Error: pop3-login: Raw backtrace:
 2   pop3-login  0x0001ac41  
default_fatal_finish + 41 ->
 3   pop3-login  0x0001acac  
i_syslog_fatal_handler + 0 ->
 4   pop3-login  0x0001a446 i_info +  
0 ->
 5   pop3-login  0x000153a2  
authenticate_callback + 126 ->
 6   pop3-login  0x0001841c  
auth_client_input_fail + 280 ->
 7   pop3-login  0x00017910  
auth_client_input + 358 ->
 8   pop3-login  0x0001e074  
io_loop_handler_run + 272 ->
 9   pop3-login  0x0001d449  
io_loop_run + 38 ->
10  pop3-login  0x00014864 main + 1572  
->

11  pop3-login  0x000112fc start + 52
Error: child 1302 (login) killed with signal 6

This happens when I feed multiple user/pass lines to Dovecot all at  
once like this:

$ telnet gromit 110
Connected.
Escape character is '^]'.
+OK Dovecot ready.
user x
pass y
user x
pass y
+OK
+OK
Connection closed by foreign host.

The four user/pass lines I pasted in all at once.

IMAP login does not crash when presented with multiple login commands,  
but it does not read them all at once and needs prodding (in the form  
of extra command lines sent later on) to read them.  Actually it  
appears to read the first two lines then stops reading until more data  
comes in:


$ telnet gromit 143
Connected.
Escape character is '^]'.
* OK Dovecot ready.
a login a b
b login c d
c login e f
d login g h
e login i j
a NO Authentication failed.
b NO Authentication failed.

c NO Authentication failed.

d NO Authentication failed.

e NO Authentication failed.

* BAD Error in IMAP command received by server.
* BAD Error in IMAP command received by server.
* BAD Error in IMAP command received by server.
* BAD Error in IMAP command received by server.
^]
telnet> q
Connection closed.

You probably don't care about the odd imap-login behavior, but I tried  
it and mentioned it just for completeness after seeing pop3-login crash.


Re: [Dovecot] mail_executable's process environment

2008-10-30 Thread Mike Malsman

On 29.Oct.2008, at 11:41 AM, Timo Sirainen wrote:

On Mon, 2008-10-20 at 20:02 -0400, Mike Malsman wrote:

Upon inspection of the processes' environment I'm pleased to see that
there's a load of useful information in there.  However, one  
essential

component in my case is the destination network address, which is
missing.  I added it with the attached patch, exposed as 'LOCAL_IP'.
Works for me.

Is this something that would be useful to anyone else?


OK, added: http://hg.dovecot.org/dovecot-1.1/rev/a5495e3e90c9


Thanks very much, Timo.

I know the patch is trivial but it saves me the effort of remembering  
to patch at all :]


-Mike


[Dovecot] Panic from 1.1.7

2008-11-24 Thread Mike Abbott
dovecot: Nov 24 12:49:06 Panic: IMAP(user): file ioloop-notify- 
kqueue.c: line 66 (event_callback): assertion failed: (io->refcount ==  
1)

dovecot: Nov 24 12:49:06 Error: IMAP(user): Raw backtrace:
 2   imap0x000100068e82 default_fatal_finish + 41 ->
 3   imap0x000100068eed i_syslog_fatal_handler + 0 ->
 4   imap0x000100068687 i_info + 0 ->
 5   imap0x00010006fc0a event_callback + 216 ->
 6   imap0x00010006fdea io_loop_handler_run + 272 ->
 7   imap0x00010006f1bf io_loop_run + 38 ->
 8   imap0x00010006a319 dotlock_create + 532 ->
 9   imap0x00010006ac0f file_dotlock_create + 177 ->
 10  imap0x00010001a925 maildir_uidlist_lock_timeout + 169 ->
 11  imap0x00010001aa14 maildir_uidlist_sync_init + 66 ->
 12  imap0x000100017d48 maildir_sync_context + 299 ->
 13  imap0x00010001809a maildir_storage_sync_init + 104 ->
 14  imap0x00010003e183 mailbox_sync + 31 ->
 15  imap0x0001bcca imap_status_get + 132 ->
 16  imap0x00015355 cmd_status + 230 ->
 17  imap0x00016cb5 client_command_input + 33 ->
 18  imap0x00016e62 client_command_input + 462 ->
 19  imap0x00016f61 client_handle_input + 239 ->
 20  imap0x000170e8 client_input + 151 ->
 21  imap0x00010006fdea io_loop_handler_run + 272 ->
 22  imap0x00010006f1bf io_loop_run + 38 ->
 23  imap0x0001e046 main + 1671 ->
 24  imap0x00011558 start + 52 ->
 25  ??? 0x0001 0x0 + 1

Dovecot-1.1.7 on Mac OS X.

Fixed by http://hg.dovecot.org/dovecot-1.2/rev/2c111b572eee ?  (Just  
guessing.)

Re: [Dovecot] Panic from 1.1.7

2008-11-24 Thread Mike Abbott

Is this random, common or reproducible?


Seen only once so far.

I guess it's possible that kqueue notifications are just completely  
broken currently.


Oh, really?


Re: [Dovecot] Panic from 1.1.7

2008-11-24 Thread Mike Abbott

Is this random, common or reproducible?


Seen only once so far.


Make that twice now, so it does seem to be reproducible.



  1   2   3   4   >