Re: [Dovecot] v1.0.11 released (managesieve updated)

2008-03-04 Thread Stephan Bosch

Timo Sirainen wrote:

http://dovecot.org/releases/1.0/dovecot-1.0.11.tar.gz
http://dovecot.org/releases/1.0/dovecot-1.0.11.tar.gz.sig

Updated ManageSieve patch:

http://www.rename-it.nl/dovecot/1.0/dovecot-1.0.11-MANAGESIEVE-v9.2.diff.gz
http://www.rename-it.nl/dovecot/1.0/dovecot-1.0.11-MANAGESIEVE-v9.2.diff.gz.sig

Regards,

Stephan


Re: [Dovecot] store sieve scripts with maildir

2008-03-04 Thread Timo Sirainen

On Mar 4, 2008, at 12:09 PM, Samuel HAMEAU wrote:

I am using dovecot 1.0.10 and pysieved, in a master/slave cluster  
with ldap (auth_bind=yes). For conceptuals reasons, i would like to  
keep on the same partition the mailstore + sieve scripts.


I have try to set sieve and home variables under the plugin  
section with an absolute path, and i have tried to override home  
variable in user_attrs (dovecot-ldap.conf) as well with an absolute  
path, but in vain.


Set mail_debug=yes and auth_debug=yes. What does deliver log then?



PGP.sig
Description: This is a digitally signed message part


Re: [Dovecot] different mail_locations

2008-03-04 Thread Timo Sirainen

On Mar 3, 2008, at 12:45 PM, Antonio Casado Rodríguez wrote:


Yes, it work well. But the mail still not arrived.

How do I configure /bin/mail to arrive mails with postfix and  
dovecot off? I use dovecot-lda


# su - myuser -c 'echo $MAIL; echo $HOME'
/var/spool/mail/myuser
/var/spool/mail/myuser/home

# echo hello | mail myuser(work if postfix is on and dovecot  
is off)


Why do you want to do that? It's Postfix that receives the mails.

If you really want to deliver mails while Postfix isn't running, run  
Dovecot's deliver directly:


echo hello | /usr/local/libexec/dovecot/deliver



PGP.sig
Description: This is a digitally signed message part


Re: [Dovecot] v1.1.rc1 released

2008-03-04 Thread Timo Sirainen

On Feb 22, 2008, at 9:42 AM, Gerhard Wiesinger wrote:


Hello Timo!
Looks like that mbox index handling still doesn't work with deliver:
1.) 1s mail delivered: Only dovecot.index.log is generated.


This is correct. dovecot.index doesn't need to be created/updated  
always, and dovecot.index.cache isn't created because there's  
nothing that's known wanted to be cached.


Hmmm. But shouldn't this be a feature of 1.1 that deliver updates  
indexes at deliver time? (maybe you can choose the typical indexes  
the clients use).


Updating dovecot.index.log is enough. v1.0 unneededly wastes disk I/O  
writing to dovecot.index way too often.



1. deliver the first mail
2. open the mailbox
3. deliver lots of large mails
4. open the mailbox again

It should be fast. (and I just tested - it is)


Yes, that's exactly the testcase I use. But here it is slow (opening  
is always done with doevecot 1.0.latest/alpine 1.00 and deliver is  
done with 1.1.rc1). I use large files to see a time I see on the  
first look on opening.


Check with v1.1's idxview what the index file contains after steps 2,  
3 and 4. After step 2 it should contain for the first message all the  
cached fields that client needs. Between 3 and 4 steps there should be  
no changes, and the cache fields should be exactly the same with the  
same decision rules as with step 2.




PGP.sig
Description: This is a digitally signed message part


[Dovecot] Missing IMAP folders

2008-03-04 Thread Willem Jan Withagen

Hi,

I'm fresh starting to use dovecot.
Before this I used bincimap, mainly because it was very simple to config.

I've tried to find the FAQ's and tried searching the archives, but little came 
up.

My current config:
server
FreeBSD i386, postfix 2.4
dovecot 1.0.10
client:
windows 2000
thunderbird 2.0.0.12

after some inital config this starts up, and I even have the advantage that I 
can
save in the Sent folder on the server.

However I have over 3500 folders and most of them are more than 3 levels deep.
And I only get to see the first top level of directories.
Searching and/or subscribing does not bring anything.

Does somebody have pointers on how to fix this, other than manually trying to
recreate al subscriptions.

--WjW



Re: [Dovecot] Missing IMAP folders

2008-03-04 Thread Timo Sirainen

On Mar 4, 2008, at 1:44 PM, Willem Jan Withagen wrote:

However I have over 3500 folders and most of them are more than 3  
levels deep.

And I only get to see the first top level of directories.
Searching and/or subscribing does not bring anything.


Are they stored in subdirectories in filesystem? Dovecot v1.1 would  
support that, but v1.0 supports only Maildir++ directory layout. http://wiki.dovecot.org/MailboxFormat/Maildir#maildir++


Although I thought that Binc also supported only maildir++ and  
imapdir, and I thought imapdir also used a maildir++-like flat layout?




PGP.sig
Description: This is a digitally signed message part


Re: [Dovecot] Missing IMAP folders

2008-03-04 Thread Willem Jan Withagen

Timo Sirainen wrote:

On Mar 4, 2008, at 1:44 PM, Willem Jan Withagen wrote:

However I have over 3500 folders and most of them are more than 3 
levels deep.

And I only get to see the first top level of directories.
Searching and/or subscribing does not bring anything.


Are they stored in subdirectories in filesystem? Dovecot v1.1 would 
support that, but v1.0 supports only Maildir++ directory layout. 
http://wiki.dovecot.org/MailboxFormat/Maildir#maildir++


Directories was perhaps the wrong word to use.
No they just follow the maildir format .aaa.bbb.ccc
So ccc is a subfolder of bbb which is a subfolder of aaa

Although I thought that Binc also supported only maildir++ and imapdir, 
and I thought imapdir also used a maildir++-like flat layout?


AFAIK Binc does not understand much other than the basics

--WjW



[Dovecot] Outlook 2003 marks email for deletion

2008-03-04 Thread Jan van den Berg
Hi,

 

Im running Dovecot 1.1RC1 (only IMAP). 

I noticed that when I connect with Outlook 2003; and I start reading new
email some mails get marked (completely random) for deletion (,S - ,ST)
??

 

I can set this mail to unread, undo the deletion read it again and it
will stay OK. But other emails will still get marked.

This only seems to happen with Outlook 2003 not with Outlook Express or
Thunderbird and only with new unread mail.

 

Any ideas why Outlook marks this mail for deletion?



Cheers,

 

Jan



Re: [Dovecot] Security issue #5: mail_extra_groups setting is often used insecurely

2008-03-04 Thread Benoit Branciard

Timo Sirainen a écrit :

2a) mbox: Any files/directories under mail group-writable directories
can be created/deleted/renamed by symlinking the directory under
~/mail/. For example ln -s /var/mail ~/mail/var, DELETE var/root will
happily delete root's mailbox. This I hadn't thought about before.


Not if /var/mail is set sticky, which is the case on all good modern 
Unix systems:


Right. That's why it was included in the workarounds. :)

Anyway I also thought that /var/mail would be sticky in at least some 
systems. I couldn't find a single one. CentOS 5, Debian, FreeBSD 6.2, 
Solaris 10 none have it sticky by default.


All our Debian Sarge and Etch systems (with Sendmail and procmail 
packages) have /var/mail sticky by default, we didn't modify it ourselves.



--
Ce message a ete verifie par MailScanner
pour des virus ou des polluriels et rien de
suspect n'a ete trouve.



Re: [Dovecot] Outlook 2003 marks email for deletion

2008-03-04 Thread Maarten Bezemer
Hi Jan,

On Tue, 4 Mar 2008, Jan van den Berg wrote:

 I noticed that when I connect with Outlook 2003; and I start reading new
 email some mails get marked (completely random) for deletion (,S - ,ST)
 ??

Did you enable content filtering in Outlook? I've seen things like this
before, when Outlook decides the contents of a message are spam or
otherwise unwanted.
Another possible explanation could be that Outlook has an inconsistent
view of the mail 'folder'. Either because you are also using different
MUA's with the same IMAP account, or because Outlook's local cache gets
bigger than the ANSI limit of 1 (or 2?) GB.

[side note: does anybody know how to disable this cache crap? Outlook
converts Base64 Unicode-messages to 'parsed' text. In case the original
was e.g. in Cyrillic, the local cache will contain '?' for every character
not in US-ASCII orso. Moving mails to other folders does not copy the
base64 contents, but the 'translated' contents. Thus destroying the
message...]


Maarten



Re: [Dovecot] Missing IMAP folders

2008-03-04 Thread Timo Sirainen
On Tue, 2008-03-04 at 12:58 +0100, Willem Jan Withagen wrote:
 Timo Sirainen wrote:
  On Mar 4, 2008, at 1:44 PM, Willem Jan Withagen wrote:
  
  However I have over 3500 folders and most of them are more than 3 
  levels deep.
  And I only get to see the first top level of directories.
  Searching and/or subscribing does not bring anything.
  
  Are they stored in subdirectories in filesystem? Dovecot v1.1 would 
  support that, but v1.0 supports only Maildir++ directory layout. 
  http://wiki.dovecot.org/MailboxFormat/Maildir#maildir++
 
 Directories was perhaps the wrong word to use.
 No they just follow the maildir format .aaa.bbb.ccc
 So ccc is a subfolder of bbb which is a subfolder of aaa

OK, then I suspect the problem happens because hierarchy separator
changed from '/' to '.' and Thunderbird keeps caching the old one and
breaking itself. Try

a) Deleting/rebuilding TB's cache

b) Changing Dovecot's separator to '/' also using namespaces.
http://wiki.dovecot.org/Namespaces




signature.asc
Description: This is a digitally signed message part


Re: [Dovecot] Security issue #5: mail_extra_groups setting is often used insecurely

2008-03-04 Thread Timo Sirainen
On Tue, 2008-03-04 at 13:42 +0100, Benoit Branciard wrote:
 Timo Sirainen a écrit :
  2a) mbox: Any files/directories under mail group-writable directories
  can be created/deleted/renamed by symlinking the directory under
  ~/mail/. For example ln -s /var/mail ~/mail/var, DELETE var/root will
  happily delete root's mailbox. This I hadn't thought about before.
 
  Not if /var/mail is set sticky, which is the case on all good modern 
  Unix systems:
  
  Right. That's why it was included in the workarounds. :)
  
  Anyway I also thought that /var/mail would be sticky in at least some 
  systems. I couldn't find a single one. CentOS 5, Debian, FreeBSD 6.2, 
  Solaris 10 none have it sticky by default.
 
 All our Debian Sarge and Etch systems (with Sendmail and procmail 
 packages) have /var/mail sticky by default, we didn't modify it ourselves.

My test Debian image came from debian-40r1-amd64-businesscard.iso and it
had no MTA installed. After installing Exim /var/mail still wasn't
sticky. After installing sendmail-bin it got sticky.



signature.asc
Description: This is a digitally signed message part


Re: [Dovecot] store sieve scripts with maildir

2008-03-04 Thread Samuel HAMEAU

Timo Sirainen a écrit :

On Mar 4, 2008, at 12:09 PM, Samuel HAMEAU wrote:

I am using dovecot 1.0.10 and pysieved, in a master/slave cluster 
with ldap (auth_bind=yes). For conceptuals reasons, i would like to 
keep on the same partition the mailstore + sieve scripts.


I have try to set sieve and home variables under the plugin 
section with an absolute path, and i have tried to override home 
variable in user_attrs (dovecot-ldap.conf) as well with an absolute 
path, but in vain.


Set mail_debug=yes and auth_debug=yes. What does deliver log then?


Thanks for your fast answer.


With the plugin options, i get :
- for the deliver :
deliver(shameau): 2008-03-04 13:38:06 Info: Loading modules from 
directory: /usr/lib/dovecot/modules/lda
deliver(shameau): 2008-03-04 13:38:06 Info: Module loaded: 
/usr/lib/dovecot/modules/lda/lib90_cmusieve_plugin.so
deliver(shameau): 2008-03-04 13:38:06 Info: Home dir not found: 
/var/spool/imap/user1/sieve
deliver(shameau): 2008-03-04 13:38:06 Info: maildir: 
data=/var/spool/imap/user1
deliver(shameau): 2008-03-04 13:38:06 Info: maildir: 
root=/var/spool/imap/user1, index=/var/spool/imap/user1, control=, inbox=
deliver(shameau): 2008-03-04 13:38:06 Info: 
msgid=[EMAIL PROTECTED]: saved mail to INBOX

- for smartsieve/pysieved login, i get :
dovecot: 2008-03-04 13:39:22 Info: auth(default): new auth connection: 
pid=15871
dovecot: 2008-03-04 13:39:22 Info: auth(default): client in: 
AUTH   1   PLAIN   service=pysievedresp=hidden
dovecot: 2008-03-04 13:39:22 Info: auth(default): ldap(user1): bind: 
dn=uid=user1,ou=Users,dc=company,dc=com
dovecot: 2008-03-04 13:39:22 Info: auth(default): client in (unknown 
command):
dovecot: 2008-03-04 13:39:22 Info: auth(default): client out: 
OK1   user=user1
dovecot: 2008-03-04 13:39:22 Info: auth(default): master in: 
USER   1   user1 service=pysieved
dovecot: 2008-03-04 13:39:22 Info: auth(default): ldap(shameau): user 
search: base=ou=Users,dc=company,dc=com scope=subtree 
filter=((objectClass=posixAccount)(uid=shameau)) 
fields=homeDirectory,uidNumber,gidNumber
dovecot: 2008-03-04 13:39:22 Info: auth(default): master out: 
USER  1   user1 uid=1428home=/home/user1  gid=1000



So, it seems it works for deliver (the home dir is the equivalent of my 
home variable in the plugin section, but not the sieve variable (which 
would be /var/spool/imap/user1/pysieved/sieve). However, it doesn't for 
the auth (from auth-master socket) which keeps the home value fetched 
from ldap.


I am using the auth-master/auth-client sockets with pysieved. When i 
connect using the smartsieve php frontal, pysieved seeks data in 
/home/user1 insted of /var/spool/imap/user1/sieve ...


is it a dovecot or pysieved issue ?

sam




Re: [Dovecot] v1.0.11 released

2008-03-04 Thread Wolfram Schlich
* Timo Sirainen [EMAIL PROTECTED] [2008-03-04 07:39]:
 http://dovecot.org/releases/1.0/dovecot-1.0.11.tar.gz
 http://dovecot.org/releases/1.0/dovecot-1.0.11.tar.gz.sig
 
   * mail_extra_groups setting was commonly used insecurely. This setting
 is now deprecated. Most users should switch to using
 mail_privileged_group setting, but if you really need the old
 functionality use mail_access_groups instead.
 
   - mbox: Dropped some of the physical size fetch optimizations added
 in v1.0.8. This makes some commands slower, but should fix the rest
 of the problems.
   - IMAP: SEARCH BEFORE/ON/SINCE didn't handle timezones correctly.
   - ldap: auth_bind was doing lookups using subtree scope instead of
 the scope specified in config file.
   - zlib plugin crashfixes by Richard Platel
   - master passdbs: pass=yes setting was broken with blocking passdbs
 (e.g. MySQL)

Thanks, bumped the Gentoo ebuild to 1.0.11 including the
MANAGESIEVE patch 9.2 :)
-- 
Regards,
Wolfram Schlich [EMAIL PROTECTED]
Gentoo Linux * http://dev.gentoo.org/~wschlich/


[Dovecot] /var/mail stickyness

2008-03-04 Thread Edgar Fuß
 Anyway I also thought that /var/mail would be sticky in at least some 
 systems. I couldn't find a single one. CentOS 5, Debian, FreeBSD 6.2, 
 Solaris 10 none have it sticky by default.
It seems to be sticky on NetBSD.



Re: [Dovecot] /var/mail stickyness

2008-03-04 Thread Bill Cole

At 3:35 PM +0100 3/4/08, Edgar Fuß wrote:

 Anyway I also thought that /var/mail would be sticky in at least some
 systems. I couldn't find a single one. CentOS 5, Debian, FreeBSD 6.2,
 Solaris 10 none have it sticky by default.

It seems to be sticky on NetBSD.


Whether a directory used for system mboxes 
(sometimes /var/mail, sometimes /var/spool/mail, 
sometimes /usr/spool/mail *EWWW* ) needs to be 
1777 or 0775 or Something Else is a function of 
what sort of LDA(s) and MUA(s) and mailstore 
server(s) need to access it and what some admin 
has done in the past to make it work.


The core problem is that anything changing 
mailboxes there probably needs to be able to 
create and delete both mailbox files and 
lockfiles there, so either you need to have a 
bunch of well-vetted setgid software or you need 
to use a 1777 or 3777 mail spool.


The best alternative would be a working mandatory 
lock system in the OS and good gatekeeping on the 
creation and deletion of mboxes, but that's not a 
combination that multi-platform software can 
count on...



--
Bill Cole
[EMAIL PROTECTED]



[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


Re: [Dovecot] Outlook 2003 marks email for deletion

2008-03-04 Thread Jan van den Berg
Hi,

It seems it might have something to do with the Junk email setting.
I noticed all the marked-for-deletion mail was automatically moved to
the 'Junk email' folder.
But here is what I don't understand:

Why my previous Courier IMAP server never did this; with the same
Outlook Junk email settings.

What is so specific about Dovecot that this happens? Could it be that
Dovecot and Outlook have a certain negotiation about this. Outlook sends
a message to Dovecot about a Junk email and Dovecot then moves this. Can
this be confirmed? Can I look for this 'negotiation' in strace?

Cheers,

Jan


-Oorspronkelijk bericht-
Van: Maarten Bezemer [mailto:[EMAIL PROTECTED] 
Verzonden: dinsdag 4 maart 2008 13:45
Aan: Jan van den Berg
CC: Dovecot Mailing List
Onderwerp: Re: [Dovecot] Outlook 2003 marks email for deletion

Hi Jan,

On Tue, 4 Mar 2008, Jan van den Berg wrote:

 I noticed that when I connect with Outlook 2003; and I start reading
new
 email some mails get marked (completely random) for deletion (,S -
,ST)
 ??

Did you enable content filtering in Outlook? I've seen things like this
before, when Outlook decides the contents of a message are spam or
otherwise unwanted.
Another possible explanation could be that Outlook has an inconsistent
view of the mail 'folder'. Either because you are also using different
MUA's with the same IMAP account, or because Outlook's local cache gets
bigger than the ANSI limit of 1 (or 2?) GB.

[side note: does anybody know how to disable this cache crap? Outlook
converts Base64 Unicode-messages to 'parsed' text. In case the original
was e.g. in Cyrillic, the local cache will contain '?' for every
character
not in US-ASCII orso. Moving mails to other folders does not copy the
base64 contents, but the 'translated' contents. Thus destroying the
message...]


Maarten



[Dovecot] Building Dovecot with OpenLDAP break PAM LDAP on Solaris

2008-03-04 Thread Laurent Blume
Hi all,

I'm back with more data on a problem  Iposted about one month ago.

To sum it up, my Solaris 10 box has local accounts as well as LDAP ones
via PAM. They work well as-is, with no special configuratio, for WU IMAP
(using the «other» entry in pam.conf.

When I tried a self-built Dovecot, all accounts were authenticated
without problem. Then I tried the Blastwave version, same release, but
with more option, and this one didn't work with the exact same
configuration: local accounts were authenticated, not the PAM LDAP ones.

Now, it turns out that when Dovecot is built using OpenLDAP, then PAM
LDAP account won't work. If it's built with Solaris LDAP, they work,
everything else being equal.

Is there any way to fix that?

There's the Blastwave bug report with more details if needed:
http://www.blastwave.org/mantis/view_bug_page.php?f_id=0002760

Thanks in advance for any help,

Laurent
-- 
/ Leader de Projet  Communauté| I'm working, but not speaking for
\ G11N   http://fr.opensolaris.org | Bull Services http://www.bull.com
/ FOSUG  http://guses.org  |


[Dovecot] User Unknown Sendmail Error

2008-03-04 Thread Paul Roberts
I am totally stumped here.  I have setup a dovecot user and I can telnet to
port 110 and login no problem with that user.  When I try to send mail I get
an error from sendmail:
Mar  4 13:39:56 flashyhome sendmail[5014]: m24JdtGp005014: [EMAIL 
PROTECTED]...
User unknown

Now apparenly I need to setup the sendmail.mc file...which I have:

MAILER(smtp)dnl
MAILER(procmail)dnl
MAILER(dovecot)

And:

more /usr/share/sendmail-cf/mailer/dovecot.m4
##*##
###   DOVECOT Mailer specification  ###
##*##
Mdovecot,   P=/usr/local/libexec/dovecot/deliver, F=DFMPhnu9,
 S=EnvFromSMTP/HdrFromSMTP, R=EnvToSMTP/HdrFromSMTP,
 T=DNS/RFC822/X-Unix,
 A=deliver -d $u

If anyone can give me any advice on what I need to do it would be much
appreciated.  Thanks so much in advance!

-Paul


Re: [Dovecot] constant mailbox rebuilding with dovecot 1.0.10

2008-03-04 Thread Philip J. Hollenback
On 02/26/08, Timo Sirainen wrote:
 On Tue, 2008-02-26 at 15:56 -0500, Philip J. Hollenback wrote:
  I've recently upgraded to 1.0.10 in hopes that this problem would go
  away but no luck.  I've got some users at my company with large
  inboxes on maildir (say 22,000 messages).  Their mailboxes are hosted
  on nfs and dovecot is configured to do dotlocking.
 
 Are there multiple Dovecot servers accessing the mailboxes? Can the same
 user have different connections to different servers at the same time?
 
 This sounds like NFS caching problems that are described in
 http://wiki.dovecot.org/NFS

The real problem seemed to be when users run multiple imap clients and
they stomp on each others' index files on the nfs filesystem.

I believe I have this fixed.  I should clarify that there is only
one dovecot server which in turn nfs-mounts the mailbox filesystem from
a netapp.  I realized after reading all the dovecot nfs documentation
that I could point the INDEX variable to a local filesystem on the
dovecot server.  I did that with the following dovecot.conf
default_mail_env:

default_mail_env = mbox:%h/mail:INBOX=/var/mail/%u:INDEX=/opt/dcache/%u

because the default at my company is mbox.  Then for each maildir user I
set a dovecot.passwd entry as follows:

user:X:501:100::/home/user:/bin/false::Maildir:/home/%u/Maildir:INDEX=/opt/dcache/%u

finally I set my dovecot.conf locking/nfs options as follows:

mmap_disable=yes
dotlock_use_excl = no
lock_method = fcntl
mbox_read_locks = dotlock
mbox_write_locks = dotlock

since I'm using dovecot 1.0 I believe this is the correct way to do
dotlocking on the mbox files and fcntl locking on the index files (which
remember are on the local filesystem under /opt/dcache).

Since I've made this change I've seen no more corrupted index files.

P.

-- 
Phil Hollenback
[EMAIL PROTECTED]
Schrodinger, Inc.


Re: [Dovecot] Multiple SSL certs

2008-03-04 Thread Lampa
Hello,

AFAIK it's planned for 2.x version.

If you need run separate instance of dovecot (bind separate ip address
and use separate certificate).

I'm running this on 5 ip addresses and no problem.

2008/3/4, Daniel L. Miller [EMAIL PROTECTED]:
 Does 1.1 support multiple certs?

  --

 Daniel



-- 
Lampa


Re: [Dovecot] [Dovecot-news] Security issue #5: mail_extra_groups setting is often used insecurely

2008-03-04 Thread Jérémie Bouttier

  Hi,

It seems to me that many versions of Debian (where /var/mail is 
root:mail 2775) are vulnerable.


Timo Sirainen wrote :

a) Upgrade to v1.0.11 and use the new mail_privileged_group setting
instead of mail_extra_groups.


We tried this but now the mail.log has a number of lines :
« dovecot: IMAP(someuser): open(/var/mail/.temp.) failed: Permission 
denied »


This with mail_location: mbox:~/Mail:INBOX=/var/mail/%u and no specific 
settings for mbox_*_locks.



mail_privileged_group setting works by keeping the group in process's
saved GID while it's not in use and temporarily switching it to
effective GID while dotlocks are created. Currently this is done only
when:

1. It's only done for INBOX mbox which doesn't exist under the same
location as other mailboxes (so typically under /var/mail).

2. It's used only after initial dotlock creation try failed with EACCES
error.


This might be the explanation, but is there any way to avoid the logs to 
get flooded ?


Cheers,

  Jeremie



Re: [Dovecot] [Dovecot-news] Security issue #5: mail_extra_groups setting is often used insecurely

2008-03-04 Thread Timo Sirainen
On Tue, 2008-03-04 at 17:31 +0100, Jérémie Bouttier wrote:
  a) Upgrade to v1.0.11 and use the new mail_privileged_group setting
  instead of mail_extra_groups.
 
 We tried this but now the mail.log has a number of lines :
 « dovecot: IMAP(someuser): open(/var/mail/.temp.) failed: Permission 
 denied »

Oh, this is actually harmless. You can get rid of it (and improve the
performance) by setting dotlock_use_excl=yes.

But maybe I should release v1.0.12 anyway with that error message
silenced..




signature.asc
Description: This is a digitally signed message part


[Dovecot] Multiple SSL certs

2008-03-04 Thread Daniel L. Miller

Does 1.1 support multiple certs?

--
Daniel


Re: [Dovecot] Security issue #5: mail_extra_groups setting is often used insecurely

2008-03-04 Thread Karsten Bräckelmann
On Wed, 2008-03-05 at 00:29 +0200, Timo Sirainen wrote:

   a) Upgrade to v1.0.11 and use the new mail_privileged_group setting
   instead of mail_extra_groups.
  
  We tried this but now the mail.log has a number of lines :
  « dovecot: IMAP(someuser): open(/var/mail/.temp.) failed: Permission 
  denied »
 
 Oh, this is actually harmless. You can get rid of it (and improve the
 performance) by setting dotlock_use_excl=yes.
 
 But maybe I should release v1.0.12 anyway with that error message
 silenced..

You mean seeing that error message only is actually not an error,
because the next locking method just works?

In that case, great -- I'll go change dotlock_use_excl, revert the scary
option (b) of chmod world-writable, and see how it works out. Not using
NFS anyway.

  guenther


-- 
char *t=[EMAIL PROTECTED];
main(){ char h,m=h=*t++,*x=t+2*h,c,i,l=*x,s=0; for (i=0;il;i++){ i%8? c=1:
(c=*++x); c128  (s+=h); if (!(h=1)||!t[s+h]){ putchar(t[s]);h=m;s=0; }}}



Re: [Dovecot] Security issue #5: mail_extra_groups setting is often used insecurely

2008-03-04 Thread Timo Sirainen
On Tue, 2008-03-04 at 23:41 +0100, Karsten Bräckelmann wrote:
 On Wed, 2008-03-05 at 00:29 +0200, Timo Sirainen wrote:
 
a) Upgrade to v1.0.11 and use the new mail_privileged_group setting
instead of mail_extra_groups.
   
   We tried this but now the mail.log has a number of lines :
   « dovecot: IMAP(someuser): open(/var/mail/.temp.) failed: Permission 
   denied »
  
  Oh, this is actually harmless. You can get rid of it (and improve the
  performance) by setting dotlock_use_excl=yes.
  
  But maybe I should release v1.0.12 anyway with that error message
  silenced..
 
 You mean seeing that error message only is actually not an error,
 because the next locking method just works?

Right. Also fixed it now:
http://hg.dovecot.org/dovecot-1.0/rev/a9ac53bc191b

 In that case, great -- I'll go change dotlock_use_excl, revert the scary
 option (b) of chmod world-writable, and see how it works out. Not using
 NFS anyway.

dotlock_use_excl=yes works also in all modern NFS systems. I doubt
anyone is still using NFSv2. This setting is now default in v1.1.



signature.asc
Description: This is a digitally signed message part


Re: [Dovecot] Security issue #5: mail_extra_groups setting is often used insecurely

2008-03-04 Thread Karsten Bräckelmann
On Tue, 2008-03-04 at 23:41 +0100, Karsten Bräckelmann wrote:
 On Wed, 2008-03-05 at 00:29 +0200, Timo Sirainen wrote:

  Oh, this is actually harmless. You can get rid of it (and improve the
  performance) by setting dotlock_use_excl=yes.
  
  But maybe I should release v1.0.12 anyway with that error message
  silenced..
 
 You mean seeing that error message only is actually not an error,
 because the next locking method just works?
 
 In that case, great -- I'll go change dotlock_use_excl, revert the scary
 option (b) of chmod world-writable, and see how it works out. Not using
 NFS anyway.

Seems it did the trick, judging by some quick tests. :)

  guenther


-- 
char *t=[EMAIL PROTECTED];
main(){ char h,m=h=*t++,*x=t+2*h,c,i,l=*x,s=0; for (i=0;il;i++){ i%8? c=1:
(c=*++x); c128  (s+=h); if (!(h=1)||!t[s+h]){ putchar(t[s]);h=m;s=0; }}}



[Dovecot] Mercurial repository

2008-03-04 Thread Timo Sirainen
I removed dovecot repository for now. It was almost the same as
dovecot-1.1, with the exception that I had forgotten to commit a few
things there and also messed up some other commits (oh, hg export can
export multiple changesets at a time, cool. oh, hg import imported it
all in one changeset, not cool.).

So for now v1.2 code doesn't exist. I'll clone it again from dovecot-1.1
once I have something real to commit. Although I guess that's probably
going to be pretty soon.


signature.asc
Description: This is a digitally signed message part


Re: [Dovecot] User Unknown Sendmail Error

2008-03-04 Thread Uldis Pakuls

Paul Roberts wrote:

I am totally stumped here.  I have setup a dovecot user and I can telnet to
port 110 and login no problem with that user.  When I try to send mail I get
an error from sendmail:
Mar  4 13:39:56 flashyhome sendmail[5014]: m24JdtGp005014: [EMAIL 
PROTECTED]...
User unknown

  


When I try to send mail I get an error from sendmail

dovecot _is not_ sendmail your MX setup is separate thing. check 
your MX setup or at least provide your sendmail: (postfix, sendmai,l 
exim?) config.


Uldis



Re: [Dovecot] multiple namespaces, Mac OS X

2008-03-04 Thread David Koski
Never mind.  I found:  http://www.dovecot.org/doc/NEWS

snip
v1.0.rc29 2007-03-28  Timo Sirainen [EMAIL PROTECTED]
snip
IMAP: LIST   didn't return anything if there didn't exist a namespace with 
empty prefix. This broke some clients
snip

I upgraded using backport binaries 1.0.10-1~bpo40+1 and it works with Mac OS X 
mail clients now.

Regards,
David

On Tuesday 04 March 2008 14:37, David Koski wrote:
 After installing a new server with postfix/dovecot I found that the Mac OS
 X mail client does not see email in subfolders.  It seemed to be related to
 the namespace.  From dovecot.conf:

 namespace private {
 separator = .
 prefix = INBOX.
 inbox = yes
 hidden = no
 }

 After googling I found that I might need to add a default namespace with an
 empty prefix so I added this:

 namespace private {
 separator = .
 prefix =
 inbox = yes
 hidden = no
 }

 Then I was able to access mail in subfolders using the Mac mail client.
 However, using Kmail I can see both namespaces, where all the folders are
 listed under the inbox at the same level, and where all folders are listed
 one level below the inbox.  I don't really want to keep my INBOX. prefix
 so existing accounts remain unchanged.  How do I solve this?

 The current dovecot.conf is below.

 Regards,
 David Koski
 [EMAIL PROTECTED]

 log_timestamp: %Y-%m-%d %H:%M:%S
 login_dir: /var/run/dovecot/login
 login_executable: /usr/lib/dovecot/imap-login
 first_valid_uid: 104
 last_valid_uid: 104
 mail_extra_groups: mail
 mail_location: /var/vmail
 maildir_copy_with_hardlinks: yes
 mail_plugins: quota imap_quota
 imap_client_workarounds: outlook-idle delay-newmail
 namespace:
   type: private
   separator: .
   prefix: INBOX.
   inbox: yes
 auth default:
   mechanisms: PLAIN LOGIN CRAM-MD5 APOP NTLM
   user: nobody
   passdb:
 driver: pam
   passdb:
 driver: sql
 args: /etc/dovecot/dovecot-sql.conf
   userdb:
 driver: sql
 args: /etc/dovecot/dovecot-sql.conf
   userdb:
 driver: prefetch
   socket:
 type: listen
 client:
   path: /var/spool/postfix/private/auth
   mode: 432
   user: postfix
   group: mail
 master:
   path: /var/run/dovecot/auth-master
   mode: 432
   user: vmail
   group: mail


Re: [Dovecot] User Unknown Sendmail Error

2008-03-04 Thread Paul Roberts
Sorry I wasn't clearer...when I send mail to that user from an  
external account (in this case my gmail account) I get the user  
unknown error from sendmail.


-Paul



On Mar 4, 2008, at 6:12 PM, Uldis Pakuls [EMAIL PROTECTED] wrote:


Paul Roberts wrote:
I am totally stumped here.  I have setup a dovecot user and I can  
telnet to
port 110 and login no problem with that user.  When I try to send  
mail I get

an error from sendmail:
Mar  4 13:39:56 flashyhome sendmail[5014]: m24JdtGp005014: [EMAIL PROTECTED] 
...

User unknown




When I try to send mail I get an error from sendmail

dovecot _is not_ sendmail your MX setup is separate thing. check  
your MX setup or at least provide your sendmail: (postfix,  
sendmai,l exim?) config.


Uldis



[Dovecot] Problem with Thunderbird hang, multiple retry to .Sent/.Draft

2008-03-04 Thread tlum
I have begun havening a problem when sending or when Thunderbird tries 
to write copy to .Draft. Usually only happens when the message is 
longer. While in the Thunderbird editor will say Copying message to 
Draft folder. It will try indefinitely. The copy is successful but it 
looks like it is believed to have failed so its retried. Same then 
happens when sending. Send happens but then hangs on copy to .Sent. Copy 
works, but apparently is not seen and just keeps getting retried. If you 
let it go hundreds of copies of message end up in .Sent and .Draft. Have 
logs from Thunderbird and rawlog but they are huge and don't want to 
post them to the list until after determining there is no quick answer 
for this behavior.


dovecot --version = 1.0.rc15

dovecot -n

# /etc/dovecot.conf
base_dir: /var/run/dovecot/
log_timestamp: ¦%Y-%m-%d %H:%M:%S ¦
protocols: imap imaps
listen: 127.0.0.1:143
ssl_listen: *:993
ssl_ca_file: /etc/pki/mydomain/mailserver/certs/class3.crt
ssl_cert_file: /etc/pki/mydomain/mailserver/certs/ms1srvp01.mydomain.net.crt
ssl_key_file: 
/etc/pki/mydomain/mailserver/private/ms1srvp01.mydomain.net.key

disable_plaintext_auth: yes
verbose_ssl: yes
login_dir: /var/run/dovecot//login
login_executable: /usr/libexec/dovecot/imap-login
verbose_proctitle: yes
first_valid_uid: 5000
last_valid_uid: 5000
mail_extra_groups: vmail
mail_location: maildir:/home/vmail/%d/%u:INDEX=/var/indexes/%d/%n
mail_debug: yes
maildir_copy_with_hardlinks: yes
mbox_read_locks: dotlock
mbox_write_locks: dotlock
mail_executable: /usr/libexec/dovecot/rawlog /usr/libexec/dovecot/imap
imap_client_workarounds: outlook-idle, tb-extra-mailbox-sep
auth default:
 user: nobody
 passdb:
   driver: sql
   args: /etc/dovecot/dovecot-sql.conf
 userdb:
   driver: prefetch
 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: 432
 user: vmail
 group: vmail


mail_location: gets an override from userdb SQL lookup. /home/vmail is 
nfs mounted, /var/indexes is is local ext3.


No error messages are logged any place. I think Thunderbird asks for the 
copy and then verifies it. It seems dovecot never confirms they copy 
happened.


--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.



Re: [Dovecot] Multiple SSL certs

2008-03-04 Thread Anil
Has anyone tried to set this up (multiple certs for multiple
hostnames) with something like stunnel wrapper for SSL instead of
using dovecot's SSL?

On Tue, Mar 4, 2008 at 2:10 PM, Lampa [EMAIL PROTECTED] wrote:
 Hello,

  AFAIK it's planned for 2.x version.

  If you need run separate instance of dovecot (bind separate ip address
  and use separate certificate).

  I'm running this on 5 ip addresses and no problem.

  2008/3/4, Daniel L. Miller [EMAIL PROTECTED]:

  Does 1.1 support multiple certs?
  
--
  
   Daniel
  


  --
  Lampa



Re: [Dovecot] different mail_locations

2008-03-04 Thread Steffen Kaiser

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Tue, 4 Mar 2008, Antonio Casado Rodríguez wrote:


# echo hello | /usr/libexec/dovecot/deliver
Fatal: destination user parameter (-d user) not given


Deliver cannot know where to deliver to, if you run it as root.


# echo hello | /usr/libexec/dovecot/deliver -d foo
# tail /var/log/dovecot/dovecot-deliver.log
deliver(foo): Mar 04 14:36:27 Error: Can't connect to auth server at 
/var/run/dovecot/auth-master: No such file or directory


Ran as root, deliver must know where the homedirectory of foo is, because 
Deliver uses the Dovecot authentification framework, Dovecot must be 
running and configured to expose the auth socket.



foo$ echo hello | /usr/libexec/dovecot/deliver
foo$ more  foo/cur/1204638363.P28199Q0M553430.blade25,S=11:2,S
hello

It haven't headers  :(


Well, where should be headers come from? You tell deliver to put the 
single line message hello\n into the mail storage of foo. No more no 
less.


MUAs (like mail command) require a working MTA they connect to. However, 
you can create the headers yourself, e.g.:


echo From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: Dumm Di Dumm
Reply-To: [EMAIL PROTECTED]
X-Header: Dunno
Preference: junk

Hello | su foo -c deliver

Though, running deliver without Dovecot auth socket makes no sense to me 
with Maildir. Just generate a new filename and put the message right into 
the Maildir/new of the user. Because deliver relies on the Dovecot 
framework it does not perform LDAP queries or the like on its own.


Bye,

- -- 
Steffen Kaiser

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFHzk3dVJMDrex4hCIRAjXuAKCM6zOOWkRxOcjdSF7QHyrzY0OBLwCg03cD
rE70t2y0EZFqGWFQXmhg8nw=
=H+og
-END PGP SIGNATURE-

Re: [Dovecot] User Unknown Sendmail Error

2008-03-04 Thread Steffen Kaiser

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Tue, 4 Mar 2008, Scott Silva wrote:


on 3-4-2008 4:22 PM Paul Roberts spake the following:
Sorry I wasn't clearer...when I send mail to that user from an external 
account (in this case my gmail account) I get the user unknown error from 
sendmail.


-Paul

Still not a dovecot issue. It is your MTA that is at fault, or its 
configuration.


To phrase Scott's answer differently:

sendmail does not use the Dovecot framework to authentificate or validate 
users (unfortunately). Therefore you have to configure sendmail to use the 
same user DB or forward (alias) your users via a special MDA line.


Bye.

- -- 
Steffen Kaiser

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFHzk/kVJMDrex4hCIRAo2XAJkBzy5Or1L1RiXVxxxctBFL+PY5gACeLGMn
nXMlLJOcEdas+nGlL5nRYWw=
=Brg/
-END PGP SIGNATURE-


[Dovecot] v1.0.12 released

2008-03-04 Thread Timo Sirainen

http://dovecot.org/releases/1.0/dovecot-1.0.12.tar.gz
http://dovecot.org/releases/1.0/dovecot-1.0.12.tar.gz.sig

- Using mail_privileged_group with dotlock_use_excl=no worked, but it
  logged access denied errors.



PGP.sig
Description: This is a digitally signed message part