Re: [Dovecot] v2.1.10 released
Am 18.09.2012 20:52, schrieb Timo Sirainen: + Added mailbox_alias plugin. It allows creating mailbox aliases using symlinks. Hi Timo thx for coding, no Problems so far, after update, but mailbox_alias plugin should be described at http://wiki2.dovecot.org/Plugins/ -- Best Regards MfG Robert Schetterer
[Dovecot] ssl cert for mail server
for testing a new ssl cert. it works ok for browsers, but openssl s_client -crlf -connect ms1.trailsandtribulations.net:443 = verify error:num=19:self signed certificate in certificate chain is this ssl cert - as it's constructed - is ok for mail clients? (realize needs to be on mail port etc - right now talking about the cert itself.) have had problems with thunderbird, and was wondering if this might be part of the problem.
[Dovecot] Deleting a folder with character
Hello, One of my users has a mailbox named 'INBOX.Kron SPM' (maybe created a long time ago, when we use courier imap as pop/imap server, but I'm not sure). I can see the maildir with a doveadm list command: amateo_adm@myotis31:~$ sudo doveadm mailbox list -u user ... INBOX.Kron SPM ... but I can't delete it, neithe rename it: amateo_adm@myotis31:~$ sudo doveadm mailbox delete -u user 'INBOX.Kron SPM' doveadm(jrfv): Error: Can't delete mailbox INBOX.Kron SPM: Mailbox doesn't exist: INBOX.Kron - SPM amateo_adm@myotis31:~$ sudo doveadm mailbox delete -u user 'INBOX.Kron \ SPM' doveadm(jrfv): Error: Can't delete mailbox INBOX.Kron \ SPM: Mailbox doesn't exist: INBOX.Kron \- SPM is there any way to delete it with doveadm command? should I use a specific syntax or escape to indicate the name?
Re: [Dovecot] Deleting a folder with character
On 19/09/12 09:22, Angel L. Mateo wrote: Hello, One of my users has a mailbox named 'INBOX.Kron SPM' (maybe created a long time ago, when we use courier imap as pop/imap server, but I'm not sure). I can see the maildir with a doveadm list command: amateo_adm@myotis31:~$ sudo doveadm mailbox list -u user ... INBOX.Kron SPM ... but I can't delete it, neithe rename it: amateo_adm@myotis31:~$ sudo doveadm mailbox delete -u user 'INBOX.Kron SPM' doveadm(jrfv): Error: Can't delete mailbox INBOX.Kron SPM: Mailbox doesn't exist: INBOX.Kron - SPM amateo_adm@myotis31:~$ sudo doveadm mailbox delete -u user 'INBOX.Kron \ SPM' doveadm(jrfv): Error: Can't delete mailbox INBOX.Kron \ SPM: Mailbox doesn't exist: INBOX.Kron \- SPM is there any way to delete it with doveadm command? should I use a specific syntax or escape to indicate the name? Hi, I see something similar when I try to doveadm import maildir folders (to mdbox) with ampersands - I get the same Mailbox doesn't exist: INBOX.Foo - Bar with that extraneous hyphen. Cheers Alex -- This message is intended only for the addressee and may contain confidential information. Unless you are that person, you may not disclose its contents or use it in any way and are requested to delete the message along with any attachments and notify us immediately. Transact is operated by Integrated Financial Arrangements plc Domain House, 5-7 Singer Street, London EC2A 4BQ Tel: (020) 7608 4900 Fax: (020) 7608 5300 (Registered office: as above; Registered in England and Wales under number: 3727592) Authorised and regulated by the Financial Services Authority (entered on the FSA Register; number: 190856)
Re: [Dovecot] Deleting a folder with character
On 19.9.2012, at 11.22, Angel L. Mateo wrote: One of my users has a mailbox named 'INBOX.Kron SPM' (maybe created a long time ago, when we use courier imap as pop/imap server, but I'm not sure). I can see the maildir with a doveadm list command: amateo_adm@myotis31:~$ sudo doveadm mailbox list -u user ... INBOX.Kron SPM ... but I can't delete it, neithe rename it: amateo_adm@myotis31:~$ sudo doveadm mailbox delete -u user 'INBOX.Kron SPM' doveadm(jrfv): Error: Can't delete mailbox INBOX.Kron SPM: Mailbox doesn't exist: INBOX.Kron - SPM amateo_adm@myotis31:~$ sudo doveadm mailbox delete -u user 'INBOX.Kron \ SPM' doveadm(jrfv): Error: Can't delete mailbox INBOX.Kron \ SPM: Mailbox doesn't exist: INBOX.Kron \- SPM is there any way to delete it with doveadm command? should I use a specific syntax or escape to indicate the name? It's an invalid mailbox name and you can't access it using doveadm. Either rename it with mv or via IMAP protocol (not entirely sure if it works via IMAP either).
Re: [Dovecot] Syntax for doveadm auth cache
El 18/09/12 18:31, Timo Sirainen escribió: On 18.9.2012, at 9.59, Angel L. Mateo wrote: So I'm running this command. Whenever I run it, I get the message that 3 (sometimes, is 4) entries are removed, but user information isn't really reloaded and I doubt it is really removed from cache (I have the user in a passwd-file and information used by imap processes is still the old one, no the new one, changed before the flush) Works in my tests. Is this cache the same than the user information cache? Yes. The parameter of the user I want to change is his quota, so I have modified quota value in my ldap diretory, then I run: doveadm auth cache flush myuser What is your doveconf -n output and the dovecot-ldap.conf contents? Is myuser with or without @domain? Also try this: doveadm auth cache flush foo # make sure it isn't there doveadm user foo doveadm auth cache flush foo Does the second flush return 1 or 0 entries? If 0, then there's a problem. If 1, then it really should have worked. You could try also if disabling userdb prefetch makes any difference. And if you still have multiple userdb try with only one. I have made the test in my test server (it has no real activity). In this server, user entry is refreshed correctly. But the same test in my production servers fails. I have checked (in the production one) that the second flush delete entries (in fact, 2, not 1): amateo_adm@myotis31:/etc/dovecot/conf.d$ sudo doveadm auth cache flush angel.luis 2 cache entries flushed amateo_adm@myotis31:/etc/dovecot/conf.d$ sudo doveadm user angel.luis userdb: angel.luis home : /home/alumnos/46/113246 uid : 113246 gid : 1001 quota_rule: *:storage=400M amateo_adm@myotis31:/etc/dovecot/conf.d$ sudo doveadm auth cache flush angel.luis 2 cache entries flushed amateo_adm@myotis31:/etc/dovecot/conf.d$ sudo doveadm user angel.luis userdb: angel.luis home : /home/alumnos/46/113246 uid : 113246 gid : 1001 quota_rule: *:storage=400M but quota information is not reloaded from ldap server. I have also checked my ldap server, and dovecot is not performing any search operation for the user after flushing him from the cache. I have attached my doveconf -n. In my ldap configuration I have: user_attrs = irisMailbox=mail,homeDirectory=home,uidNumber=uid,gidNumber=gid,quota=quota_rule pass_attrs = irisMailbox=userdb_mail,userPassword=password,homeDirectory=userdb_home,uidNumber=userdb_uid,gidNumber=userdb_gid,quota=userdb_quota_rule and I have check that my test and production server has the same configuration (but client_limit and number of processes). Any idea?
[Dovecot] OT: z-Push
Hi, just a short question: I have installed and configured z-Push to use BackendIMAP. On my iPhone I have created an account and I can see my mails. Also sending works. So far so good. Now the question: When I create a new folder i.e. Test under the root (/), then I get an error. And after resyncing the folder has been created not under /, but under /0/Test. Also I can not remove that folder over ActiveSync. Does somebody have z-Push fully working with Dovecot or is z-Push designed for Cyrus and only some features are working with Dovecot? So at the moment folder create/move/delete does not work here with z-Push-2.0.3 and Dovecot 2.1.9 Thanks in advance -Christian Rößner --- Bachelor of Science Informatik Erlenwiese 14, 36304 Alsfeld T: +49 6631 78823400, F: +49 6631 78823409, M: +49 176 93118939 USt-IdNr.: DE225643613, http://www.roessner-network-solutions.com
Re: [Dovecot] OT: z-Push
Am 19.09.2012 11:26, schrieb Christian Rößner: Hi, just a short question: I have installed and configured z-Push to use BackendIMAP. On my iPhone I have created an account and I can see my mails. Also sending works. So far so good. Now the question: When I create a new folder i.e. Test under the root (/), then I get an error. And after resyncing the folder has been created not under /, but under /0/Test. Also I can not remove that folder over ActiveSync. Does somebody have z-Push fully working with Dovecot or is z-Push designed for Cyrus and only some features are working with Dovecot? yes it works with dovecot So at the moment folder create/move/delete does not work here with z-Push-2.0.3 and Dovecot 2.1.9 sorry tested , there is no option for create folder on my android, need test account offlist? Thanks in advance -Christian Rößner --- Bachelor of Science Informatik Erlenwiese 14, 36304 Alsfeld T: +49 6631 78823400, F: +49 6631 78823409, M: +49 176 93118939 USt-IdNr.: DE225643613, http://www.roessner-network-solutions.com -- Best Regards MfG Robert Schetterer
Re: [Dovecot] Deleting a folder with character
On 2012-09-19 5:14 AM, Timo Sirainen t...@iki.fi wrote: It's an invalid mailbox name and you can't access it using doveadm. Either rename it with mv or via IMAP protocol (not entirely sure if it works via IMAP either). Just for clarification... it is invalid because of the '' character? Is there a list of dovecot (or is this simply the IMAP protocol in general?) considers invalid characters in folder names somewhere? Thanks Timo, -- Best regards, Charles
[Dovecot] Dovecot deliver Segmentation fault when arrive the first message
Hi, I have found this strange problem. I'm working with Debian 6, dovecot 2.1.9 and vpopmail-auth. LDA is configured and works fine but the problem is when the first message arrive dovecot-lda return a Segmentation fault, the message is written to the user's Mailbox but the message remains, also, in the queue of qmail (deferral: Segmentation_fault/) and at the second attempt is delivered fine. If disable ACL (acl and imap_acl from mail_plugins) in dovecot.conf Segmentation fault go away. Moreover, without ACL at the first delivery folders like Sent, Drafts, Trash, Spam appear immediately. An example, new user: root@demo-vpop ~ # tree /home/vpopmail/domains/qboxdns.it/cecchi2/Maildir/ -a /home/vpopmail/domains/qboxdns.it/cecchi2/Maildir/ ├── cur ├── maildirsize ├── new └── tmp root@demo-vpop ~ # cat testmail.txt | /usr/local/dovecot-2.1/libexec/dovecot/deliver -d cecc...@qboxdns.it Segmentation fault root@demo-vpop ~ # echo $? 139 root@demo-vpop ~ # tree /home/vpopmail/domains/qboxdns.it/cecchi2/Maildir/ -a /home/vpopmail/domains/qboxdns.it/cecchi2/Maildir/ ├── cur ├── dovecot-acl-list ├── dovecot.index.cache ├── dovecot.index.log ├── dovecot-uidlist ├── dovecot-uidvalidity ├── dovecot-uidvalidity.50599a7f ├── maildirsize ├── new │ └── 1348049535.M21758P19264.demo-vpop.cbsolt.net,S=2025,W=2071 └── tmp dovecot log (with ulimit -c unlimited before starting Dovecot): Sep 19 12:06:50 auth: Debug: Loading modules from directory: /usr/local/dovecot-2.1/lib/dovecot/auth Sep 19 12:06:50 auth: Debug: master in: USER 1 cecc...@qboxdns.it service=lda Sep 19 12:06:50 auth-worker(18728): Debug: Loading modules from directory: /usr/local/dovecot-2.1/lib/dovecot/auth Sep 19 12:06:50 auth-worker(18728): Debug: vpopmail(cecc...@qboxdns.it): lookup user=cecchi2 domain=qboxdns.it Sep 19 12:06:50 auth: Debug: master out: USER 1 cecc...@qboxdns.it uid=89 gid=89 home=/home/vpopmail/domains/qboxdns.it/cecchi2 quota_rule=*:backend=10485760S Sep 19 12:06:50 dict: Info: mysql(localhost): Connected to database dovecot lda log: Sep 19 12:06:50 lda: Debug: Loading modules from directory: /usr/local/dovecot-2.1/lib/dovecot Sep 19 12:06:50 lda: Debug: Module loaded: /usr/local/dovecot-2.1/lib/dovecot/lib01_acl_plugin.so Sep 19 12:06:50 lda: Debug: Module loaded: /usr/local/dovecot-2.1/lib/dovecot/lib10_quota_plugin.so Sep 19 12:06:50 lda: Debug: auth input: cecc...@qboxdns.it uid=89 gid=89 home=/home/vpopmail/domains/qboxdns.it/cecchi2 quota_rule=*:backend=10485760S Sep 19 12:06:50 lda: Debug: Added userdb setting: plugin/quota_rule=*:backend=10485760S Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: Effective uid=89, gid=89, home=/home/vpopmail/domains/qboxdns.it/cecchi2 Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: Quota root: name=UserQuota backend=maildir args= Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: Quota rule: root=UserQuota mailbox=* bytes=10485760 messages=0 Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: Quota rule: root=UserQuota mailbox=Trash bytes=+104857600 messages=0 Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: Quota root: name=User quota backend=dict args=:noenforcing:proxy::quota Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: dict quota: user=cecc...@qboxdns.it, uri=proxy::quota, noenforcing=1 Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: Namespace inbox: type=private, prefix=, sep=/, inbox=yes, hidden=no, list=yes, subscriptions=yes location=maildir:~/Maildir Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: maildir++: root=/home/vpopmail/domains/qboxdns.it/cecchi2/Maildir, index=, control=, inbox=/home/vpopmail/domains/qboxdns.it/cecchi2/Maildir, alt= Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: acl: initializing backend with data: vfile:/usr/local/dovecot-2.1/etc/dovecot/global-acls:cache_secs=300 Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: acl: acl username = cecc...@qboxdns.it Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: acl: owner = 1 Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: acl vfile: Global ACL directory: /usr/local/dovecot-2.1/etc/dovecot/global-acls Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: Namespace : type=shared, prefix=shared/%n/, sep=/, inbox=no, hidden=no, list=children, subscriptions=no location=maildir:%h/Maildir:INDEX=~/Maildir/shared/%u Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: shared: root=/usr/local/dovecot-2.1/var/run/dovecot, index=, control=, inbox=, alt= Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: acl: initializing backend with data: vfile:/usr/local/dovecot-2.1/etc/dovecot/global-acls:cache_secs=300 Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: acl: acl username = cecc...@qboxdns.it Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: acl: owner = 0 Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: acl vfile: Global ACL directory: /usr/local/dovecot-2.1/etc/dovecot/global-acls Sep 19 12:06:50 lda(cecc...@qboxdns.it): Debug: Quota root: name=UserQuota backend=maildir args= Sep 19 12:06:50
Re: [Dovecot] ssl cert for mail server
Am 19.09.2012 10:00, schrieb cc maco young: for testing a new ssl cert. it works ok for browsers, but openssl s_client -crlf -connect ms1.trailsandtribulations.net:443 = verify error:num=19:self signed certificate in certificate chain is this ssl cert - as it's constructed - is ok for mail clients? (realize needs to be on mail port etc - right now talking about the cert itself.) have had problems with thunderbird, and was wondering if this might be part of the problem. Hi, first of all this is likely off topic for this ML, I'll still answer though, since I'm always intrigued by TLS problems. The reason openssl doesn't accept this cert, while your browser does, is quite likely that your system wide accepted CAs don't include Starfield Technologies, while your browser's CAs do (This is the case for Firefox and Thunderbird). However, I suspect that your mail addresses are of the form u...@trailsandtribulations.net, and ms1.trailsandtribulations.net is what is in your MX record. As such the certificate needs to be valid for trailsandtribulations.net, and not ms1.trailsandtribulations.net. So you either need trailsandtribulations.net as your CN, or a SAN of type DNSName for trailsandtribulations.net. Cf. https://tools.ietf.org/html/rfc6125 for best practices on generating certificates. Regards, Florian
Re: [Dovecot] Wrong quota calculation
On 12/09/2012 10:58, Cibest ML wrote: On 11/09/2012 20:48, Timo Sirainen wrote: On 8.9.2012, at 18.07, Cibest ML wrote: - Message delivered by LMTP Quota name TypeValue Limit User quota STORAGE 2653 524288 User quota MESSAGE 1 - - quota recalc Quota name TypeValue Limit User quota STORAGE 5307 524288 User quota MESSAGE 2 - Quota recalculation is clearly seeing the message twice. My first guess was that you had two namespaces pointing to the same location, but you seem to have only one. Do you have symlinks in your Maildir? Hi, Nothing specific on the namespace side. The only entry is the default one in 10-mail.conf namespace inbox { inbox = yes } I tried to comment it out but it doesn't change anything And no symlinks in the Maildir. Here's the file structure of Maildir for the test mailbox ./dovecot-uidvalidity.504df4e7 ./dovecot-uidvalidity ./.Sent ./.Sent/maildirfolder ./.Sent/new ./.Sent/dovecot.index.log ./.Sent/tmp ./.Sent/dovecot-uidlist ./.Sent/cur ./.Spam ./.Spam/maildirfolder ./.Spam/new ./.Spam/dovecot.index.log ./.Spam/tmp ./.Spam/dovecot-uidlist ./.Spam/cur ./new ./subscriptions ./.Drafts ./.Drafts/maildirfolder ./.Drafts/new ./.Drafts/dovecot.index.log ./.Drafts/tmp ./.Drafts/dovecot-uidlist ./.Drafts/cur ./.Drafts/dovecot-keywords ./dovecot.index.log ./tmp ./dovecot.mailbox.log ./dovecot-uidlist ./.Trash ./.Trash/maildirfolder ./.Trash/new ./.Trash/dovecot.index.log ./.Trash/tmp ./.Trash/dovecot-uidlist ./.Trash/cur ./cur ./cur/1347286291.M194531P4329.mspooll01,S=3748,W=3847:2,Sa ./dovecot-keywords ./dovecot.index.cache -- Regards Sébastien We did some more investigations as we had to enable the no enforcing quota option to prevent too many compltains from our customers. As the issue seems to be linked to the inbox folder, we tried to focus on that. According to Timo's last post, that could be linked to namespace or symlinks (we don't have any). There's one quite strange thing we've seen. Display the subscription windows in Thunderbird and unchecking INBOX then shows two entries. INBOX that isn't selected and Inbox that is selected and cannot been unselected. Checking INBOX again makes Inbox disappear (subscription window need to be closed reopened after each action). Now doing some check via telnet doesn't show any mysterious Inbox list * * LIST (\HasNoChildren) . Sent * LIST (\HasNoChildren) . Spam * LIST (\HasNoChildren) . Drafts * LIST (\HasNoChildren) . Trash * LIST (\HasNoChildren) . INBOX lsub * * LSUB () . Trash * LSUB () . Sent * LSUB () . Spam * LSUB () . Drafts * LSUB () . Inbox 04 select INBOX * FLAGS (\Answered \Flagged \Deleted \Seen \Draft NonJunk) * OK [PERMANENTFLAGS (\Answered \Flagged \Deleted \Seen \Draft NonJunk \*)] Flags permitted. * 1 EXISTS * 0 RECENT * OK [UIDVALIDITY 1346832313] UIDs valid * OK [UIDNEXT 82] Predicted next UID * OK [HIGHESTMODSEQ 51] Highest 04 OK [READ-WRITE] Select completed. 04 select Inbox * OK [CLOSED] Previous mailbox closed. * FLAGS (\Answered \Flagged \Deleted \Seen \Draft NonJunk) * OK [PERMANENTFLAGS (\Answered \Flagged \Deleted \Seen \Draft NonJunk \*)] Flags permitted. * 1 EXISTS * 0 RECENT * OK [UIDVALIDITY 1346832313] UIDs valid * OK [UIDNEXT 82] Predicted next UID * OK [HIGHESTMODSEQ 51] Highest 04 OK [READ-WRITE] Select completed. It's working for both but I checked on other working dovecot servers, that seems to be a normal behavior for Inbox folder I'm not sure that what we see in Thunderbird is related to the problem but who knows. Any help is of course welcome as we're out of ideas :) -- Sébastien
Re: [Dovecot] Deleting a folder with character
On 19.9.2012, at 13.36, Charles Marcus wrote: On 2012-09-19 5:14 AM, Timo Sirainen t...@iki.fi wrote: It's an invalid mailbox name and you can't access it using doveadm. Either rename it with mv or via IMAP protocol (not entirely sure if it works via IMAP either). Just for clarification... it is invalid because of the '' character? Is there a list of dovecot (or is this simply the IMAP protocol in general?) considers invalid characters in folder names somewhere? mUTF7 uses the character for encoding non-ASCII data. The character is encoded in mUTF7 as -. Dovecot nowadays uses UTF8 internally for all mailbox names, and it's simply not possible to create from UTF8 string a valid mUTF7 string that contains alone. Dovecot has also some additional restrictions on characters (mainly control chars), but they are only enforced when creating new mailboxes. Opening existing mailboxes with control chars is allowed.
Re: [Dovecot] Wrong quota calculation
On 19.9.2012, at 15.15, Cibest ML wrote: There's one quite strange thing we've seen. Display the subscription windows in Thunderbird and unchecking INBOX then shows two entries. INBOX that isn't selected and Inbox that is selected and cannot been unselected. Checking INBOX again makes Inbox disappear (subscription window need to be closed reopened after each action). No idea. INBOX is treated case-insensitively by IMAP protocol. I'm not sure that what we see in Thunderbird is related to the problem but who knows. Any help is of course welcome as we're out of ideas :) Create a test server. Make your Dovecot config minimal. Test with another quota backend. Test with local filesystem. See what change breaks the quota calculation. It is somehow related to your current config, since it's not broken for everybody.
Re: [Dovecot] Dovecot deliver Segmentation fault when arrive the first message
On 19.9.2012, at 13.54, Alessio Cecchi wrote: LDA is configured and works fine but the problem is when the first message arrive dovecot-lda return a Segmentation fault, the message is written to the user's Mailbox but the message remains, also, in the queue of qmail (deferral: Segmentation_fault/) and at the second attempt is delivered fine. gdb backtrace would be very helpful in figuring out the problem: http://dovecot.org/bugreport.html
Re: [Dovecot] Changing Quota downward for special Mailboxes? (2.1.6)
On Tue 18 Sep 2012 07:17:50 PM GMT, Timo Sirainen wrote: On 18.9.2012, at 14.40, Jost Krieger wrote: ... The idea is to not eat up the users storage with spam, so that spam stays in the queue (for some time) while real mail gets delivered. Interesting idea. This was pretty easy to fix: http://hg.dovecot.org/dovecot-2.1/rev/74d639b2a5bf Thank you! Now, the next problem is that if LDA can't save the message to UCE-TMP because of quota failure it saves it to INBOX. I'm not really sure how that should be fixed, since generally it's a good idea to do it.. Oops, that's not what I want! How about another command line parameter for lda to suppress the emergency save? We know exactly when we are trying to save probable spam. Yours Jost Krieger -- | jost.krieger+...@ruhr-uni-bochum.de Please help stamp out spam! | | Postmaster, JAPH, resident answer machineat RUB Comp. Center | | Sincere words are not sweet, sweet words are not sincere.| | Lao Tse, Tao Te King 81 |
Re: [Dovecot] Changing Quota downward for special Mailboxes? (2.1.6)
On Tue 18 Sep 2012 07:47:09 PM GMT, Robert Schetterer wrote: some allready existing way is i.e with milter and postfix tagged spam get in hold queue for i.e human admin investigate, or some quarantaine with amavis Human admin is not a good idea if you have 5 users :-) Quarantine's a possibility, but that's taking it out of Mail and adds complexity. for sure there are benefits getting dovecot involved in spam tagging but i would leave spam tagging to the mailserver in first way and deliver it to Junk folder by global sieve rule with giving more quota or ignoring Quota to Junk folder, but i see this isnt the same what you might wanna goal That's just what we want to do, *but* although it's in the Wiki I don't think it a good idea to *raise* the limit for the junk folder if you *deliver* to it. It's somewhat ok if you move mail there and someone picks it up (we do that with a different folder). But on delivery it means at some point you can receive spam but no real messages. Not nice. ignore may work if it does what I think (never even count bytes and messages in this folder) but it is open to abuse ... Yours Jost Krieger -- | jost.krieger+...@ruhr-uni-bochum.de Please help stamp out spam! | | Postmaster, JAPH, resident answer machineat RUB Comp. Center | | Sincere words are not sweet, sweet words are not sincere.| | Lao Tse, Tao Te King 81 |
Re: [Dovecot] Syntax for doveadm auth cache
(I forgot the attach) El 19/09/12 11:15, Angel L. Mateo escribió: El 18/09/12 18:31, Timo Sirainen escribió: On 18.9.2012, at 9.59, Angel L. Mateo wrote: So I'm running this command. Whenever I run it, I get the message that 3 (sometimes, is 4) entries are removed, but user information isn't really reloaded and I doubt it is really removed from cache (I have the user in a passwd-file and information used by imap processes is still the old one, no the new one, changed before the flush) Works in my tests. Is this cache the same than the user information cache? Yes. The parameter of the user I want to change is his quota, so I have modified quota value in my ldap diretory, then I run: doveadm auth cache flush myuser What is your doveconf -n output and the dovecot-ldap.conf contents? Is myuser with or without @domain? Also try this: doveadm auth cache flush foo # make sure it isn't there doveadm user foo doveadm auth cache flush foo Does the second flush return 1 or 0 entries? If 0, then there's a problem. If 1, then it really should have worked. You could try also if disabling userdb prefetch makes any difference. And if you still have multiple userdb try with only one. I have made the test in my test server (it has no real activity). In this server, user entry is refreshed correctly. But the same test in my production servers fails. I have checked (in the production one) that the second flush delete entries (in fact, 2, not 1): amateo_adm@myotis31:/etc/dovecot/conf.d$ sudo doveadm auth cache flush angel.luis 2 cache entries flushed amateo_adm@myotis31:/etc/dovecot/conf.d$ sudo doveadm user angel.luis userdb: angel.luis home : /home/alumnos/46/113246 uid : 113246 gid : 1001 quota_rule: *:storage=400M amateo_adm@myotis31:/etc/dovecot/conf.d$ sudo doveadm auth cache flush angel.luis 2 cache entries flushed amateo_adm@myotis31:/etc/dovecot/conf.d$ sudo doveadm user angel.luis userdb: angel.luis home : /home/alumnos/46/113246 uid : 113246 gid : 1001 quota_rule: *:storage=400M but quota information is not reloaded from ldap server. I have also checked my ldap server, and dovecot is not performing any search operation for the user after flushing him from the cache. I have attached my doveconf -n. In my ldap configuration I have: user_attrs = irisMailbox=mail,homeDirectory=home,uidNumber=uid,gidNumber=gid,quota=quota_rule pass_attrs = irisMailbox=userdb_mail,userPassword=password,homeDirectory=userdb_home,uidNumber=userdb_uid,gidNumber=userdb_gid,quota=userdb_quota_rule and I have check that my test and production server has the same configuration (but client_limit and number of processes). Any idea? # 2.1.9: /etc/dovecot/dovecot.conf # OS: Linux 3.2.19um1 x86_64 Ubuntu 12.04.1 LTS auth_cache_size = 20 M auth_cache_ttl = 1 days auth_debug = yes auth_master_user_separator = * auth_verbose = yes default_process_limit = 1024 disable_plaintext_auth = no log_timestamp = %Y-%m-%d %H:%M:%S login_trusted_networks = 155.54.211.176/28 mail_debug = yes mail_location = maildir:~/Maildir:INDEX=/var/indexes/%n mail_plugins = quota mail_privileged_group = mail maildir_very_dirty_syncs = 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 ihave imapflags mdbox_rotate_size = 20 M namespace { inbox = yes location = prefix = separator = . } namespace { hidden = yes list = no location = maildir:~/Maildir/expunged prefix = BORRADOS. separator = . } passdb { args = /etc/dovecot/master-users driver = passwd-file master = yes pass = yes } passdb { args = /etc/dovecot/dovecot-ldap.conf.ext driver = ldap } passdb { args = session=yes dovecot driver = pam } plugin { lazy_expunge = BORRADOS. quota = dict:User quota::file:%h/Maildir/dovecot.quota quota_rule = *:storage=10G quota_rule2 = Trash:storage=+1G sieve = ~/.dovecot.sieve sieve_dir = ~/sieve sieve_extensions = +imapflags sieve_max_redirects = 15 zlib_save = gz zlib_save_level = 6 } postmaster_address = postmas...@um.es protocols = imap pop3 lmtp sieve service anvil { client_limit = 3075 } service auth { client_limit = 4096 unix_listener auth-userdb { mode = 0666 } } service doveadm { inet_listener { port = 24245 } } service imap { process_limit = 5120 process_min_avail = 6 vsz_limit = 512 M } service ipc { unix_listener ipc { user = dovecot } } service lmtp { inet_listener lmtp { port = 24 } process_min_avail = 10 vsz_limit = 512 M } service pop3 { process_min_avail = 6 } ssl = no ssl_cert = /etc/ssl/certs/dovecot.pem ssl_key = /etc/ssl/private/dovecot.pem userdb { driver = prefetch } userdb { args = /etc/dovecot/dovecot-ldap.conf.ext
Re: [Dovecot] Dovecot deliver Segmentation fault when arrive the first message
Il 19/09/2012 14:48, Timo Sirainen ha scritto: On 19.9.2012, at 13.54, Alessio Cecchi wrote: LDA is configured and works fine but the problem is when the first message arrive dovecot-lda return a Segmentation fault, the message is written to the user's Mailbox but the message remains, also, in the queue of qmail (deferral: Segmentation_fault/) and at the second attempt is delivered fine. gdb backtrace would be very helpful in figuring out the problem: http://dovecot.org/bugreport.html Obvious ... :-) Reading symbols from /usr/local/dovecot-2.1/lib/dovecot/lib01_acl_plugin.so...done. Loaded symbols for /usr/local/dovecot-2.1/lib/dovecot/lib01_acl_plugin.so Reading symbols from /usr/local/dovecot-2.1/lib/dovecot/lib10_quota_plugin.so...done. Loaded symbols for /usr/local/dovecot-2.1/lib/dovecot/lib10_quota_plugin.so Core was generated by `/usr/local/dovecot-2.1/libexec/dovecot/deliver -d cecch...@qboxdns.it'. Program terminated with signal 11, Segmentation fault. #0 acl_lookup_dict_rebuild (dict=0x0) at acl-lookup-dict.c:221 221if (dict-dict == NULL) is enough? Thanks -- Alessio Cecchi is: @ ILS - http://www.linux.it/~alessice/ on LinkedIn - http://www.linkedin.com/in/alessice Assistenza Sistemi GNU/Linux - http://www.cecchi.biz/ @ PLUG - ex-Presidente, adesso senatore a vita, http://www.prato.linux.it
Re: [Dovecot] Dovecot deliver Segmentation fault when arrive the first message
Il 19/09/2012 15:03, Alessio Cecchi ha scritto: Il 19/09/2012 14:48, Timo Sirainen ha scritto: On 19.9.2012, at 13.54, Alessio Cecchi wrote: LDA is configured and works fine but the problem is when the first message arrive dovecot-lda return a Segmentation fault, the message is written to the user's Mailbox but the message remains, also, in the queue of qmail (deferral: Segmentation_fault/) and at the second attempt is delivered fine. gdb backtrace would be very helpful in figuring out the problem: http://dovecot.org/bugreport.html Obvious ... :-) Reading symbols from /usr/local/dovecot-2.1/lib/dovecot/lib01_acl_plugin.so...done. Loaded symbols for /usr/local/dovecot-2.1/lib/dovecot/lib01_acl_plugin.so Reading symbols from /usr/local/dovecot-2.1/lib/dovecot/lib10_quota_plugin.so...done. Loaded symbols for /usr/local/dovecot-2.1/lib/dovecot/lib10_quota_plugin.so Core was generated by `/usr/local/dovecot-2.1/libexec/dovecot/deliver -d cecch...@qboxdns.it'. Program terminated with signal 11, Segmentation fault. #0 acl_lookup_dict_rebuild (dict=0x0) at acl-lookup-dict.c:221 221if (dict-dict == NULL) is enough? This is the full bt: (gdb) bt full #0 acl_lookup_dict_rebuild (dict=0x0) at acl-lookup-dict.c:221 ns = value optimized out ids_arr = {arr = {buffer = 0x0, element_size = 26492496}, v = 0x0, v_modifiable = 0x0} ids = 0x1928658 i = value optimized out dest = value optimized out ret = -883075307 #1 0x7f2fc9fc41b4 in acl_backend_vfile_acllist_try_rebuild ( backend=0x1944240) at acl-backend-vfile-acllist.c:297 auser = 0x1949a08 iter = 0x0 acllist_path = 0x1928658 /home/vpopmail/domains/qboxdns.it/cecchi10/Maildir/dovecot-acl-list ret = value optimized out ns = 0x1943e50 output = 0x0 st = {st_dev = 2051, st_ino = 662103, st_nlink = 1, st_mode = 33152, st_uid = 89, st_gid = 89, __pad0 = 0, st_rdev = 0, st_size = 0, st_blksize = 4096, st_blocks = 0, st_atim = {tv_sec = 1348059559, tv_nsec = 0}, st_mtim = {tv_sec = 1348059559, tv_nsec = 0}, st_ctim = {tv_sec = 1348059559, tv_nsec = 0}, __unused = {0, 0, 0}} path = 0x1928210 file_mode = 384 dir_mode = 448 gid = 4294967295 list = value optimized out info = value optimized out rootdir = 0x1928610 Sent origin = 0x194d178 /home/vpopmail/domains/qboxdns.it/cecchi10/Maildir fd = 8 #2 acl_backend_vfile_acllist_rebuild (backend=0x1944240) at acl-backend-vfile-acllist.c:311 acllist_path = value optimized out #3 0x7f2fc9fc4563 in acl_backend_vfile_acllist_refresh (backend=0x1944240) at acl-backend-vfile-acllist.c:153 __FUNCTION__ = acl_backend_vfile_acllist_refresh #4 0x7f2fc9fc46d5 in acl_backend_vfile_acllist_verify (backend=0x0, name=0x1944a60 , mtime=0) at acl-backend-vfile-acllist.c:343 acllist = value optimized out #5 0x7f2fc9fc30b8 in acl_backend_vfile_object_refresh_cache ( _aclobj=0x19444e0) at acl-backend-vfile.c:858 old_validity = value optimized out validity = {global_validity = {last_check = 0, last_read_time = 1348059559, last_mtime = 0, last_size = 0}, local_validity = {last_check = 0, last_read_time = 0, last_mtime = 0, last_size = 0}, mailbox_validity = { last_check = 0, last_read_time = 0, last_mtime = 0, last_size = 0}} mtime = 0 ret = 26515976 #6 0x7f2fc9fc125e in acl_backend_get_default_rights (backend=0x1944240, mask_r=0x28) at acl-backend.c:164 No locals. #7 0x7f2fc9fc75bd in acl_mailbox_try_list_fast (list=0x194cc00, patterns=0x7fff362dff50, flags=MAILBOX_LIST_ITER_RETURN_NO_FLAGS) at acl-mailbox-list.c:107 alist = value optimized out nonowner_list_ctx = value optimized out ret = value optimized out backend = 0x1944240 acl_mask = 0x1 ns = 0x1943e50 update_ctx = {iter_ctx = 0x7f2fcb80d2c8, tree_ctx = 0x7f2fcbf2ba88, glob = 0x0, leaf_flags = 4294967295, parent_flags = 0, update_only = 0, match_parents = 0} name = value optimized out #8 acl_mailbox_list_iter_init (list=0x194cc00, patterns=0x7fff362dff50, flags=MAILBOX_LIST_ITER_RETURN_NO_FLAGS) at acl-mailbox-list.c:194 _data_stack_cur_id = 2 ctx = 0x1946b20 pool = value optimized out i = value optimized out inboxcase = value optimized out #9 0x7f2fcb886d33 in mailbox_list_iter_init_multiple (list=0x194cc00, patterns=0x7fff362dff50, flags=MAILBOX_LIST_ITER_RETURN_NO_FLAGS) at mailbox-list-iter.c:158 ctx = value optimized out ret = value optimized out __FUNCTION__ = mailbox_list_iter_init_multiple #10 0x7f2fcb887459 in mailbox_list_iter_init (list=0x0, pattern=value optimized out,
Re: [Dovecot] Changing Quota downward for special Mailboxes? (2.1.6)
Am 19.09.2012 14:53, schrieb Jost Krieger: On Tue 18 Sep 2012 07:47:09 PM GMT, Robert Schetterer wrote: some allready existing way is i.e with milter and postfix tagged spam get in hold queue for i.e human admin investigate, or some quarantaine with amavis Human admin is not a good idea if you have 5 users :-) Quarantine's a possibility, but that's taking it out of Mail and adds complexity. as ever ,this is different in different places specially Quarantine is wide used for sure there are benefits getting dovecot involved in spam tagging but i would leave spam tagging to the mailserver in first way and deliver it to Junk folder by global sieve rule with giving more quota or ignoring Quota to Junk folder, but i see this isnt the same what you might wanna goal That's just what we want to do, *but* although it's in the Wiki I don't think it a good idea to *raise* the limit for the junk folder if you *deliver* to it. It's somewhat ok if you move mail there and someone picks it up (we do that with a different folder). But on delivery it means at some point you can receive spam but no real messages. Not nice. ignore may work if it does what I think (never even count bytes and messages in this folder) but it is open to abuse ... there is no good or evil to this case, its a design question which may change in different places,, the abuse case might be acceptable, as the Junk folder i.e is imap special used autoconfigured and has auto empty feature, i give 50 mb plus quota on Junk folder and delete mail older then 3 month there Yours Jost Krieger -- Best Regards MfG Robert Schetterer
Re: [Dovecot] v2.1.10 released / indexer errors / lucene
Am 18.09.2012 20:52, schrieb Timo Sirainen: http://dovecot.org/releases/2.1/dovecot-2.1.10.tar.gz http://dovecot.org/releases/2.1/dovecot-2.1.10.tar.gz.sig Hi Timo, i see a few rare errors with lucene and/or indexer since update /lucene-indexes: IndexWriter() failed (#1): Lock obtain timed out lucene-indexes) failed: Directory not empty Error: unlink_directory(/usr/local/virtual/.../.../lucene-indexes) failed: Directory not empty lucene-indexes: IndexReader::open() failed (#1): File does not exist Sep 19 14:46:19 mail01 dovecot: indexer-worker: Error: pure virtual method called Sep 19 14:46:19 mail01 dovecot: indexer-worker: Error: terminate called without an active exception Error: indexer failed to index mailbox INBOX should i care -- Best Regards MfG Robert Schetterer
Re: [Dovecot] Changing Quota downward for special Mailboxes? (2.1.6)
On Wed 19 Sep 2012 04:03:45 PM GMT, Robert Schetterer wrote: as ever ,this is different in different places specially Quarantine is wide used Of course, it's often useful. there is no good or evil to this case, its a design question which may change in different places,, the abuse case might be acceptable, as the Junk folder i.e is imap special used autoconfigured and has auto empty feature, i give 50 mb plus quota on Junk folder and delete mail older then 3 month there The abuse may be tolerable, but I just don't get how your +50M works. For me it would mean that someone with a large Junk folder just wouldn't get an more mail except something delivered straight to Junk. And if you don't deliver to Junk but the clients move stuff there, there's still a problem. I'm justing raising the limit for folders that clients use for deleting (like Trash or whatever it is called). Yours Jost Krieger -- | jost.krieger+...@ruhr-uni-bochum.de Please help stamp out spam! | | Postmaster, JAPH, resident answer machineat RUB Comp. Center | | Sincere words are not sweet, sweet words are not sincere.| | Lao Tse, Tao Te King 81 |
Re: [Dovecot] Changing Quota downward for special Mailboxes? (2.1.6)
Am 19.09.2012 16:25, schrieb Jost Krieger: On Wed 19 Sep 2012 04:03:45 PM GMT, Robert Schetterer wrote: as ever ,this is different in different places specially Quarantine is wide used Of course, it's often useful. there is no good or evil to this case, its a design question which may change in different places,, the abuse case might be acceptable, as the Junk folder i.e is imap special used autoconfigured and has auto empty feature, i give 50 mb plus quota on Junk folder and delete mail older then 3 month there The abuse may be tolerable, but I just don't get how your +50M works. the situation isnt really comparable, the plus is more configured for copy by human to i.e Junk folder, or i.e a client filter does this auto it makes most sense with trash, so user should mostly able to copy to trash, even if they have got full quota, this should avoid some errors in clients http://wiki2.dovecot.org/Quota/Configuration ... quota_rule = *:storage=1G quota_rule2 = Trash:storage=+100M quota_rule3 = SPAM:ignore ... For me it would mean that someone with a large Junk folder just wouldn't get an more mail except something delivered straight to Junk. And if you don't deliver to Junk but the clients move stuff there, with auto loosing mail after some time in my setup which is the anounced policy, Trash and Junk are autodeleted folders no mail there ,rests forever *g there's still a problem. I'm justing raising the limit for folders that clients use for deleting (like Trash or whatever it is called). as i said its a design question, your policy is ok too no flame ,having your idea as alternative is always fine to have Yours Jost Krieger -- Best Regards MfG Robert Schetterer
Re: [Dovecot] 2.1.10 crashes at login (buf-used = buf-alloc)
Did you recompile antispam plugin? Is it the latest antispam? This line doesn't seem to match the current code. You are correct, it had not been compiled in a while. Here is a new backtrace: (gdb) bt full #0 0x10709ebc in kill () from /lib/libc.so.7 No symbol table info available. #1 0x10708e43 in abort () from /lib/libc.so.7 No symbol table info available. #2 0x105b8e65 in default_fatal_finish.14395 () from /usr/lib/dovecot/libdovecot.so.0 No symbol table info available. #3 0x10588e3d in i_internal_fatal_handler.14399 () from /usr/lib/dovecot/libdovecot.so.0 No symbol table info available. #4 0x105e4941 in i_panic () from /usr/lib/dovecot/libdovecot.so.0 No symbol table info available. #5 0x105e7c77 in buffer_check_limits.13467 () from /usr/lib/dovecot/libdovecot.so.0 No symbol table info available. #6 0x105e7a6a in buffer_write () from /usr/lib/dovecot/libdovecot.so.0 No symbol table info available. #7 0x105ce9f9 in array_idx_set_i () from /usr/lib/dovecot/libdovecot.so.0 No symbol table info available. #8 0x10e2a1b5 in antispam_user_created (user=0x10a83040) at user.c:96 _module_tmp = (void *) 0x10a84d18 asu = (struct antispam_user *) 0x10a84d18 tmp = Variable tmp is not available. Cheers, Olivier
Re: [Dovecot] 2.1.10 crashes at login (buf-used = buf-alloc)
On 19.9.2012, at 17.55, interfaSys sàrl wrote: Did you recompile antispam plugin? Is it the latest antispam? This line doesn't seem to match the current code. You are correct, it had not been compiled in a while. Here is a new backtrace: .. #6 0x105e7a6a in buffer_write () from /usr/lib/dovecot/libdovecot.so.0 No symbol table info available. #7 0x105ce9f9 in array_idx_set_i () from /usr/lib/dovecot/libdovecot.so.0 No symbol table info available. #8 0x10e2a1b5 in antispam_user_created (user=0x10a83040) at user.c:96 _module_tmp = (void *) 0x10a84d18 asu = (struct antispam_user *) 0x10a84d18 tmp = Variable tmp is not available. This still looks some kind of a version mismatch. Did you compile antispam against v2.1.10 headers? /usr/lib/dovecot/libdovecot.so.0 is also really from v2.1.10?
Re: [Dovecot] 2.1.10 crashes at login (buf-used = buf-alloc)
On Wed, 2012-09-19 at 17:59 +0300, Timo Sirainen wrote: On 19.9.2012, at 17.55, interfaSys sàrl wrote: Did you recompile antispam plugin? Is it the latest antispam? This line doesn't seem to match the current code. You are correct, it had not been compiled in a while. Here is a new backtrace: .. #6 0x105e7a6a in buffer_write () from /usr/lib/dovecot/libdovecot.so.0 No symbol table info available. #7 0x105ce9f9 in array_idx_set_i () from /usr/lib/dovecot/libdovecot.so.0 No symbol table info available. #8 0x10e2a1b5 in antispam_user_created (user=0x10a83040) at user.c:96 _module_tmp = (void *) 0x10a84d18 asu = (struct antispam_user *) 0x10a84d18 tmp = Variable tmp is not available. This still looks some kind of a version mismatch. Did you compile antispam against v2.1.10 headers? /usr/lib/dovecot/libdovecot.so.0 is also really from v2.1.10? Attached a helpful antispam patch. diff -r 7f94cc6b4d8e src/antispam-plugin.c --- a/src/antispam-plugin.c Fri May 11 04:05:59 2012 +0300 +++ b/src/antispam-plugin.c Wed Sep 19 18:00:59 2012 +0300 @@ -6,6 +6,8 @@ #include mailbox.h #include backends.h +const char *antispam_plugin_version = DOVECOT_VERSION; + static struct mail_storage_hooks antispam_plugin_hooks = { .mail_user_created = antispam_user_created, .mailbox_allocated = antispam_mailbox_allocated
Re: [Dovecot] 2.1.10 crashes at login (buf-used = buf-alloc)
You are once again correct. The update script had an error and thus the plugin was not recompiled for 2.1.10... Thank you! Olivier On 19/09/2012 16:02, Timo Sirainen wrote: On Wed, 2012-09-19 at 17:59 +0300, Timo Sirainen wrote: On 19.9.2012, at 17.55, interfaSys sàrl wrote: Did you recompile antispam plugin? Is it the latest antispam? This line doesn't seem to match the current code. You are correct, it had not been compiled in a while. Here is a new backtrace: .. #6 0x105e7a6a in buffer_write () from /usr/lib/dovecot/libdovecot.so.0 No symbol table info available. #7 0x105ce9f9 in array_idx_set_i () from /usr/lib/dovecot/libdovecot.so.0 No symbol table info available. #8 0x10e2a1b5 in antispam_user_created (user=0x10a83040) at user.c:96 _module_tmp = (void *) 0x10a84d18 asu = (struct antispam_user *) 0x10a84d18 tmp = Variable tmp is not available. This still looks some kind of a version mismatch. Did you compile antispam against v2.1.10 headers? /usr/lib/dovecot/libdovecot.so.0 is also really from v2.1.10? Attached a helpful antispam patch.
Re: [Dovecot] v2.1.10 released / indexer errors / lucene
On 19.9.2012, at 17.25, Robert Schetterer wrote: Am 18.09.2012 20:52, schrieb Timo Sirainen: http://dovecot.org/releases/2.1/dovecot-2.1.10.tar.gz http://dovecot.org/releases/2.1/dovecot-2.1.10.tar.gz.sig Hi Timo, i see a few rare errors with lucene and/or indexer since update Hmm. But not before? I did one change to fts-lucene, but it wasn't supposed to change the existing behavior. /lucene-indexes: IndexWriter() failed (#1): Lock obtain timed out lucene-indexes) failed: Directory not empty Error: unlink_directory(/usr/local/virtual/.../.../lucene-indexes) failed: Directory not empty lucene-indexes: IndexReader::open() failed (#1): File does not exist The above errors are also from indexer-worker? I wonder how it gets to unlink_directory(). That shouldn't happen I think, at least I don't see by grepping the sources how it could, unless something is configured wrong (user is able to see lucene-indexes as a mailbox and is able to delete it). Sep 19 14:46:19 mail01 dovecot: indexer-worker: Error: pure virtual method called Sep 19 14:46:19 mail01 dovecot: indexer-worker: Error: terminate called without an active exception Error: indexer failed to index mailbox INBOX should i care -- Best Regards MfG Robert Schetterer
Re: [Dovecot] 2.1.10 crashes at login (buf-used = buf-alloc)
On Wed, 19 Sep 2012 18:02:07 +0300, Timo Sirainen t...@iki.fi wrote: On Wed, 2012-09-19 at 17:59 +0300, Timo Sirainen wrote: On 19.9.2012, at 17.55, interfaSys sàrl wrote: Did you recompile antispam plugin? Is it the latest antispam? This line doesn't seem to match the current code. You are correct, it had not been compiled in a while. Here is a new backtrace: .. #6 0x105e7a6a in buffer_write () from /usr/lib/dovecot/libdovecot.so.0 No symbol table info available. #7 0x105ce9f9 in array_idx_set_i () from /usr/lib/dovecot/libdovecot.so.0 No symbol table info available. #8 0x10e2a1b5 in antispam_user_created (user=0x10a83040) at user.c:96 _module_tmp = (void *) 0x10a84d18 asu = (struct antispam_user *) 0x10a84d18 tmp = Variable tmp is not available. This still looks some kind of a version mismatch. Did you compile antispam against v2.1.10 headers? /usr/lib/dovecot/libdovecot.so.0 is also really from v2.1.10? Attached a helpful antispam patch. Erm... Am I missing something? http://hg.dovecot.org/dovecot-antispam-plugin/annotate/7f94cc6b4d8e/src/antispam-plugin.c line 26, or actually line 32 given http://hg.dovecot.org/dovecot-antispam-plugin/annotate/e902fcd40d1d/antispam-plugin.c#l32 -- Eugene Paskevich | *==)--- | Plug me into eug...@raptor.kiev.ua| ---(==* | The Matrix
Re: [Dovecot] Released Pigeonhole v0.3.2 for Dovecot v2.1.9
On 18/09/2012 20:49, Stephan Bosch wrote: On 9/18/2012 8:18 PM, Juan C. Blanco wrote: Hi Stephan, I'm traying to rebuild the RH (Centos) EL5 RPM with the new pigeonhole version, however I've got the follwing errors when compiling: It seems that the error is related to the ld.gold fix, If I revert the c52a0c561311 patch the error is not produced Oh d'oh. Yes, it related to that. I fixed it for Dovecot v2.2 before, but I forgot the Dovecot v2.1 tree. Fixed now: http://hg.rename-it.nl/dovecot-2.2-pigeonhole/rev/66adbdd89d5c This only happens when you compile against installed Dovecot headers, people using --with-dovecot= (like me) would not have seen this. I'll push out a new release once 2.1.10 comes out. I'm being told that is imminent. Sorry, but using the new 0.3.3 version I'm getting the same error and I'm also using --with-dovecot=... with the dovecot 2.1.10 tree in configure, not the installed headers. If needed I can send you the configure invocation command. Regards Juan C. Blanco Regards, Stephan.
Re: [Dovecot] 2.1.10 crashes at login (buf-used = buf-alloc)
On 19.9.2012, at 19.13, Eugene Paskevich wrote: This still looks some kind of a version mismatch. Did you compile antispam against v2.1.10 headers? /usr/lib/dovecot/libdovecot.so.0 is also really from v2.1.10? Attached a helpful antispam patch. Erm... Am I missing something? http://hg.dovecot.org/dovecot-antispam-plugin/annotate/7f94cc6b4d8e/src/antispam-plugin.c line 26, or actually line 32 given http://hg.dovecot.org/dovecot-antispam-plugin/annotate/e902fcd40d1d/antispam-plugin.c#l32 Oh, didn't notice it there below :) Wonder why it then didn't complain about version mismatch.
Re: [Dovecot] Deleting a folder with character
On 09/19/2012 02:42 PM, Timo Sirainen wrote: mUTF7 uses the character for encoding non-ASCII data. The character is encoded in mUTF7 as -. Dovecot nowadays uses UTF8 internally for all mailbox names, and it's simply not possible to create from UTF8 string a valid mUTF7 string that contains alone. I'm confused. I have no problems with creating and using a folder with utf8 name containing '' character. So, what problem do you describe? doveadm is working with utf8 right? So, why it can't delete such folder. -- Aleksander 'A.L.E.C' Machniak LAN Management System Developer [http://lms.org.pl] Roundcube Webmail Developer [http://roundcube.net] --- PGP: 19359DC1 @@ GG: 2275252 @@ WWW: http://alec.pl
Re: [Dovecot] [PATCH] Generalize HMAC implementation
Am 11.09.2012 20:21, schrieb Timo Sirainen: On 11.9.2012, at 21.07, Florian Zeitz wrote: I think we could simply #define the largest allowed context_size, use it for these buffers' sizes and then add i_assert(meth-context_size = HMAC_MAX_CONTEXT_SIZE) Well, either that, or we could use a union of all known context structs there. That annoyingly requires #including in hmac.h all the different .h files that contain hash contexts. When new hashes are added I doubt anyone remembers to update that. And since the hmac_context is rather rarely used I don't think it matters if we just use a somewhat large context size. Or we could use i_malloc() and i_free() under the assumption hmac_init() + hmac_final() calls are always matched. Yeah, that's not too bad either I guess. Although it is different from other hash_init()+final calls which don't require it, and it's also wasting CPU a bit. Here is an updated version of the patch. It uses the variant defining the largest allowed content size. I choose 1024 bit (128 Byte), since that is what most of the SHA-3 candidates use, so it's hopefully somewhat future proof. It's also rebased to the current head and switches the hmac uses added since the last version over to the changed API. It also fixes an interesting compiler warning I got with clang, which complained about the fact that struct hmac_context* was (re)declared in the prototype of hmac_md5_get_cram_context() and therefore separate from the one declared in hmac.h. Regards, Florian # HG changeset patch # User Florian Zeitz flo...@babelmonkeys.de # Date 1346280236 -7200 # Node ID 0aa0a656176c9ca1c3f187999cd4725bf52665e5 # Parent 488c7dde19ad8baaa1d6bb48ee092c24eb9d44fb lib: Generalize hmac to be hash independent diff --git a/src/auth/auth-token.c b/src/auth/auth-token.c --- a/src/auth/auth-token.c +++ b/src/auth/auth-token.c @@ -11,7 +11,8 @@ #include auth-common.h #include hex-binary.h -#include hmac-sha1.h +#include hmac.h +#include sha1.h #include randgen.h #include read-full.h #include write-full.h @@ -168,16 +169,17 @@ const char *auth_token_get(const char *service, const char *session_pid, const char *username, const char *session_id) { - struct hmac_sha1_context ctx; + struct hmac_context ctx; unsigned char result[SHA1_RESULTLEN]; - hmac_sha1_init(ctx, username, strlen(username)); - hmac_sha1_update(ctx, session_pid, strlen(session_pid)); + hmac_init(ctx, (const unsigned char*)username, strlen(username), + hash_method_sha1); + hmac_update(ctx, session_pid, strlen(session_pid)); if (session_id != NULL *session_id != '\0') - hmac_sha1_update(ctx, session_id, strlen(session_id)); - hmac_sha1_update(ctx, service, strlen(service)); - hmac_sha1_update(ctx, auth_token_secret, sizeof(auth_token_secret)); - hmac_sha1_final(ctx, result); + hmac_update(ctx, session_id, strlen(session_id)); + hmac_update(ctx, service, strlen(service)); + hmac_update(ctx, auth_token_secret, sizeof(auth_token_secret)); + hmac_final(ctx, result); return binary_to_hex(result, sizeof(result)); } diff --git a/src/auth/mech-cram-md5.c b/src/auth/mech-cram-md5.c --- a/src/auth/mech-cram-md5.c +++ b/src/auth/mech-cram-md5.c @@ -7,7 +7,9 @@ #include ioloop.h #include buffer.h #include hex-binary.h -#include hmac-md5.h +#include hmac-cram-md5.h +#include hmac.h +#include md5.h #include randgen.h #include mech.h #include passdb.h @@ -50,7 +52,7 @@ { unsigned char digest[MD5_RESULTLEN]; -struct hmac_md5_context ctx; +struct hmac_context ctx; const char *response_hex; if (size != CRAM_MD5_CONTEXTLEN) { @@ -59,9 +61,10 @@ return FALSE; } + hmac_init(ctx, NULL, 0, hash_method_md5); hmac_md5_set_cram_context(ctx, credentials); - hmac_md5_update(ctx, request-challenge, strlen(request-challenge)); - hmac_md5_final(ctx, digest); + hmac_update(ctx, request-challenge, strlen(request-challenge)); + hmac_final(ctx, digest); response_hex = binary_to_hex(digest, sizeof(digest)); diff --git a/src/auth/mech-scram-sha1.c b/src/auth/mech-scram-sha1.c --- a/src/auth/mech-scram-sha1.c +++ b/src/auth/mech-scram-sha1.c @@ -9,7 +9,8 @@ #include auth-common.h #include base64.h #include buffer.h -#include hmac-sha1.h +#include hmac.h +#include sha1.h #include randgen.h #include safe-memset.h #include str.h @@ -44,23 +45,23 @@ const unsigned char *salt, size_t salt_size, unsigned int i, unsigned char result[SHA1_RESULTLEN]) { - struct hmac_sha1_context ctx; + struct hmac_context ctx; unsigned char U[SHA1_RESULTLEN]; unsigned int j, k; /* Calculate U1 */ - hmac_sha1_init(ctx, str, str_size); - hmac_sha1_update(ctx, salt, salt_size); -
Re: [Dovecot] Dovecot deliver Segmentation fault when arrive the first message
I see the same crashes on FreeBSD. Turning off ACL makes the crashes disappear. I'm getting a different backtrace though and it doesn't seem to be related to ACL: Core was generated by `imap-login'. Program terminated with signal 11, Segmentation fault. Reading symbols from /usr/lib/dovecot/libdovecot-login.so.0...done. Loaded symbols for /usr/lib/dovecot/libdovecot-login.so.0 Reading symbols from /usr/lib/dovecot/libdovecot.so.0...done. Loaded symbols for /usr/lib/dovecot/libdovecot.so.0 Reading symbols from /lib/libc.so.7...done. Loaded symbols for /lib/libc.so.7 Reading symbols from /usr/local/lib/libssl.so.8...done. Loaded symbols for /usr/local/lib/libssl.so.8 Reading symbols from /usr/local/lib/libcrypto.so.8...done. Loaded symbols for /usr/local/lib/libcrypto.so.8 Reading symbols from /usr/lib/librt.so.1...done. Loaded symbols for /usr/lib/librt.so.1 Reading symbols from /lib/libthr.so.3...done. Loaded symbols for /lib/libthr.so.3 Reading symbols from /usr/lib/libz.so...done. Loaded symbols for /usr/lib/libz.so Reading symbols from /libexec/ld-elf.so.1...done. Loaded symbols for /libexec/ld-elf.so.1 #0 0x104b99a6 in hash_table_destroy (_table=0x28) at _ctype.h:143 143 return (_c 0 || _c = __mb_sb_limit) ? _c : [New Thread 10e041c0 (LWP 103332/initial thread)] (gdb) bt full #0 0x104b99a6 in hash_table_destroy (_table=0x28) at _ctype.h:143 table = (struct hash_table *) 0x10e29700 #1 0x10478cf1 in settings_parser_deinit (_ctx=0x10e29778) at array.h:197 ctx = (struct setting_parser_context *) 0x0 #2 0x104ac4ea in master_service_settings_cache_deinit (_cache=0x1045da08) at master-service-settings-cache.c:81 cache = (struct master_service_settings_cache *) 0x10e2e040 entry = (struct settings_entry *) 0x10e29740 next = (struct settings_entry *) 0x0 __FUNCTION__ = master_service_settings_cache_deinit #3 0x1044d1df in login_settings_deinit () at login-settings.c:129 No locals. #4 0x1044dd7e in main_deinit () at main.c:62 No locals. #5 0x1044df5c in login_binary_run (binary=0x4051c0, argc=2, argv=0x7fffebd8) at main.c:62 service_flags = 72 set_pool = 0x10e2d020 allow_core_dumps = true login_socket = 0x10457491 login c = -1 #6 0x004036ee in main (argc=2, argv=0x7fffebd8) at client.c:40 No locals. Cheers, Olivier
Re: [Dovecot] Released Pigeonhole v0.3.2 for Dovecot v2.1.9
On 9/19/2012 6:22 PM, Juan C. Blanco wrote: On 18/09/2012 20:49, Stephan Bosch wrote: On 9/18/2012 8:18 PM, Juan C. Blanco wrote: It seems that the error is related to the ld.gold fix, If I revert the c52a0c561311 patch the error is not produced Oh d'oh. Yes, it related to that. I fixed it for Dovecot v2.2 before, but I forgot the Dovecot v2.1 tree. Fixed now: http://hg.rename-it.nl/dovecot-2.2-pigeonhole/rev/66adbdd89d5c D'oh, this is the v2.2 change. The URL I meant is this one: http://hg.rename-it.nl/dovecot-2.1-pigeonhole/rev/8144fb698cb3 This only happens when you compile against installed Dovecot headers, people using --with-dovecot= (like me) would not have seen this. I'll push out a new release once 2.1.10 comes out. I'm being told that is imminent. Sorry, but using the new 0.3.3 version I'm getting the same error and I'm also using --with-dovecot=... with the dovecot 2.1.10 tree in configure, not the installed headers. If needed I can send you the configure invocation command. Yes, that could be helpful. Regards, Stephan.
Re: [Dovecot] [PATCH] Generalize HMAC implementation
Am 19.09.2012 19:43, schrieb Florian Zeitz: Am 11.09.2012 20:21, schrieb Timo Sirainen: On 11.9.2012, at 21.07, Florian Zeitz wrote: I think we could simply #define the largest allowed context_size, use it for these buffers' sizes and then add i_assert(meth-context_size = HMAC_MAX_CONTEXT_SIZE) Well, either that, or we could use a union of all known context structs there. That annoyingly requires #including in hmac.h all the different .h files that contain hash contexts. When new hashes are added I doubt anyone remembers to update that. And since the hmac_context is rather rarely used I don't think it matters if we just use a somewhat large context size. Or we could use i_malloc() and i_free() under the assumption hmac_init() + hmac_final() calls are always matched. Yeah, that's not too bad either I guess. Although it is different from other hash_init()+final calls which don't require it, and it's also wasting CPU a bit. Here is an updated version of the patch. It uses the variant defining the largest allowed content size. I choose 1024 bit (128 Byte), since that is what most of the SHA-3 candidates use, so it's hopefully somewhat future proof. Forget I said that. Unfortunately the MD5 context is already bigger (the SHA-1 one isn't). So 256 Byte it is I guess. Sorry for the lack of thorough testing. I hope I didn't miss another hash function. # HG changeset patch # User Florian Zeitz flo...@babelmonkeys.de # Date 1346280236 -7200 # Node ID 5e6802858a5bb3a9b278f1cbdabe5c0ffb15248d # Parent 488c7dde19ad8baaa1d6bb48ee092c24eb9d44fb lib: Generalize hmac to be hash independent diff --git a/src/auth/auth-token.c b/src/auth/auth-token.c --- a/src/auth/auth-token.c +++ b/src/auth/auth-token.c @@ -11,7 +11,8 @@ #include auth-common.h #include hex-binary.h -#include hmac-sha1.h +#include hmac.h +#include sha1.h #include randgen.h #include read-full.h #include write-full.h @@ -168,16 +169,17 @@ const char *auth_token_get(const char *service, const char *session_pid, const char *username, const char *session_id) { - struct hmac_sha1_context ctx; + struct hmac_context ctx; unsigned char result[SHA1_RESULTLEN]; - hmac_sha1_init(ctx, username, strlen(username)); - hmac_sha1_update(ctx, session_pid, strlen(session_pid)); + hmac_init(ctx, (const unsigned char*)username, strlen(username), + hash_method_sha1); + hmac_update(ctx, session_pid, strlen(session_pid)); if (session_id != NULL *session_id != '\0') - hmac_sha1_update(ctx, session_id, strlen(session_id)); - hmac_sha1_update(ctx, service, strlen(service)); - hmac_sha1_update(ctx, auth_token_secret, sizeof(auth_token_secret)); - hmac_sha1_final(ctx, result); + hmac_update(ctx, session_id, strlen(session_id)); + hmac_update(ctx, service, strlen(service)); + hmac_update(ctx, auth_token_secret, sizeof(auth_token_secret)); + hmac_final(ctx, result); return binary_to_hex(result, sizeof(result)); } diff --git a/src/auth/mech-cram-md5.c b/src/auth/mech-cram-md5.c --- a/src/auth/mech-cram-md5.c +++ b/src/auth/mech-cram-md5.c @@ -7,7 +7,9 @@ #include ioloop.h #include buffer.h #include hex-binary.h -#include hmac-md5.h +#include hmac-cram-md5.h +#include hmac.h +#include md5.h #include randgen.h #include mech.h #include passdb.h @@ -50,7 +52,7 @@ { unsigned char digest[MD5_RESULTLEN]; -struct hmac_md5_context ctx; +struct hmac_context ctx; const char *response_hex; if (size != CRAM_MD5_CONTEXTLEN) { @@ -59,9 +61,10 @@ return FALSE; } + hmac_init(ctx, NULL, 0, hash_method_md5); hmac_md5_set_cram_context(ctx, credentials); - hmac_md5_update(ctx, request-challenge, strlen(request-challenge)); - hmac_md5_final(ctx, digest); + hmac_update(ctx, request-challenge, strlen(request-challenge)); + hmac_final(ctx, digest); response_hex = binary_to_hex(digest, sizeof(digest)); diff --git a/src/auth/mech-scram-sha1.c b/src/auth/mech-scram-sha1.c --- a/src/auth/mech-scram-sha1.c +++ b/src/auth/mech-scram-sha1.c @@ -9,7 +9,8 @@ #include auth-common.h #include base64.h #include buffer.h -#include hmac-sha1.h +#include hmac.h +#include sha1.h #include randgen.h #include safe-memset.h #include str.h @@ -44,23 +45,23 @@ const unsigned char *salt, size_t salt_size, unsigned int i, unsigned char result[SHA1_RESULTLEN]) { - struct hmac_sha1_context ctx; + struct hmac_context ctx; unsigned char U[SHA1_RESULTLEN]; unsigned int j, k; /* Calculate U1 */ - hmac_sha1_init(ctx, str, str_size); - hmac_sha1_update(ctx, salt, salt_size); - hmac_sha1_update(ctx, \0\0\0\1, 4); - hmac_sha1_final(ctx, U); + hmac_init(ctx, str, str_size, hash_method_sha1); +
Re: [Dovecot] OT: z-Push
Hi, just a short question: I have installed and configured z-Push to use BackendIMAP. On my iPhone I have created an account and I can see my mails. Also sending works. So far so good. Now the question: When I create a new folder i.e. Test under the root (/), then I get an error. And after resyncing the folder has been created not under /, but under /0/Test. Also I can not remove that folder over ActiveSync. Does somebody have z-Push fully working with Dovecot or is z-Push designed for Cyrus and only some features are working with Dovecot? So at the moment folder create/move/delete does not work here with z-Push-2.0.3 and Dovecot 2.1.9 unfortunately z-Push is much too buggy here. So I dropped it in favor of standard IMAP. Best wishes -Christian Rößner --- Bachelor of Science Informatik Erlenwiese 14, 36304 Alsfeld T: +49 6631 78823400, F: +49 6631 78823409, M: +49 176 93118939 USt-IdNr.: DE225643613, http://www.roessner-network-solutions.com
Re: [Dovecot] Trouble implementing Antispam plug-in for Dovecot
On 9/11/2012 10:40 AM, Ben Johnson wrote: You nailed it, Ben. Thanks! I downloaded/installed the dovecot-dev package from the same maintainer and was able to build Antispam without issue. The hang-up now seems to be with my configuration. I'm seeing the following error in my email client whenever I attempt to move an email message from, say, Inbox to Junk folder: [SERVERBUG] BUG Unknown internal error. Nothing at all appears in syslog when this happens. I followed the instructions at http://wiki2.dovecot.org/Plugins/Antispam , to the letter, I believe. The relevant portions of my configuration are as follows: - protocol imap { mail_plugins = quota imap_quota antispam } plugin { quota = dict:user::file:/var/vmail/%d/%n/.quotausage sieve = /var/vmail/%d/%n/.sieve antispam_backend = MAILTRAIN antispam_mail_sendmail = /usr/bin/sa-learn-pipe.sh antispam_mail_spam = --spam antispam_mail_notspam = --ham antispam_spam_pattern_ignorecase = spam;junk } - The permissions and execute bit are set in accordance with other executables in the same directory: # ls -lah /usr/bin/ | grep -i sa-learn-pipe.sh -rwxr-xr-x 1 root root 297 Sep 5 11:17 sa-learn-pipe.sh I would provide more log content, but the debug options seem to be gone in the forked, = 2.0 version of this plug-in. Any ideas are very much appreciated. Thanks, -Ben Given that nobody shared any insight here, I decided to stand-up a completely new VM with Ubuntu 12.04 LTS and see if the same error occurs. While the error is different this time around, I am still unable to get any variant of the dovecot-antispam plug-in working. When I attempt to use the current packages from Ubuntu 12.04.1 LTS, and I use the above configuration, my syslog fills-up with the following: dovecot: imap-login: Login: user=u...@example.com, method=PLAIN, rip=10.0.1.57, lip=10.0.1.8, mpid=2879, TLS dovecot: master: Error: service(imap): child 2879 returned error 3 Surprisingly, I can find only two other mentions of error 3 anywhere on the Internet. Those mentions were from another user to this mailing list: http://www.dovecot.org/list/dovecot/2012-August/067787.html http://www.dovecot.org/list/dovecot/2012-August/067814.html The lack of error 3 ubiquity leads me to believe that I must be doing something stupid. There's no question that this behavior is related to the antispam-plugin, because when I commented-out the relevant lines in Dovecot's configuration file, the error does not occur. I have followed the instructions at http://wiki2.dovecot.org/Plugins/Antispam to the letter, and this is the result. The only instance in which I diverged from the Wiki article is that I used the Ubuntu-provided dovecot-antispam package (instead of compiling the plug-in from source). I am trying to use the mailtrain back-end, per the above-cited Wiki article, to call SpamAssassin's sa-learn utility for real-time learning. I am not using the SpamAssassin daemon (spamd). I'm about to throw in the towel on this plug-in, so any help would be greatly appreciated. Thank you, -Ben
Re: [Dovecot] Trouble implementing Antispam plug-in for Dovecot
On 19/09/12 23:41, Ben Johnson wrote: On 9/11/2012 10:40 AM, Ben Johnson wrote: You nailed it, Ben. Thanks! I downloaded/installed the dovecot-dev package from the same maintainer and was able to build Antispam without issue. The hang-up now seems to be with my configuration. I'm seeing the following error in my email client whenever I attempt to move an email message from, say, Inbox to Junk folder: [SERVERBUG] BUG Unknown internal error. Nothing at all appears in syslog when this happens. I followed the instructions at http://wiki2.dovecot.org/Plugins/Antispam , to the letter, I believe. The relevant portions of my configuration are as follows: - protocol imap { mail_plugins = quota imap_quota antispam } plugin { quota = dict:user::file:/var/vmail/%d/%n/.quotausage sieve = /var/vmail/%d/%n/.sieve antispam_backend = MAILTRAIN antispam_mail_sendmail = /usr/bin/sa-learn-pipe.sh antispam_mail_spam = --spam antispam_mail_notspam = --ham antispam_spam_pattern_ignorecase = spam;junk } - The permissions and execute bit are set in accordance with other executables in the same directory: # ls -lah /usr/bin/ | grep -i sa-learn-pipe.sh -rwxr-xr-x 1 root root 297 Sep 5 11:17 sa-learn-pipe.sh I would provide more log content, but the debug options seem to be gone in the forked, = 2.0 version of this plug-in. Any ideas are very much appreciated. Thanks, -Ben Given that nobody shared any insight here, I decided to stand-up a completely new VM with Ubuntu 12.04 LTS and see if the same error occurs. While the error is different this time around, I am still unable to get any variant of the dovecot-antispam plug-in working. When I attempt to use the current packages from Ubuntu 12.04.1 LTS, and I use the above configuration, my syslog fills-up with the following: dovecot: imap-login: Login: user=u...@example.com, method=PLAIN, rip=10.0.1.57, lip=10.0.1.8, mpid=2879, TLS dovecot: master: Error: service(imap): child 2879 returned error 3 Surprisingly, I can find only two other mentions of error 3 anywhere on the Internet. Those mentions were from another user to this mailing list: http://www.dovecot.org/list/dovecot/2012-August/067787.html http://www.dovecot.org/list/dovecot/2012-August/067814.html The lack of error 3 ubiquity leads me to believe that I must be doing something stupid. There's no question that this behavior is related to the antispam-plugin, because when I commented-out the relevant lines in Dovecot's configuration file, the error does not occur. I have followed the instructions at http://wiki2.dovecot.org/Plugins/Antispam to the letter, and this is the result. The only instance in which I diverged from the Wiki article is that I used the Ubuntu-provided dovecot-antispam package (instead of compiling the plug-in from source). I am trying to use the mailtrain back-end, per the above-cited Wiki article, to call SpamAssassin's sa-learn utility for real-time learning. I am not using the SpamAssassin daemon (spamd). I'm about to throw in the towel on this plug-in, so any help would be greatly appreciated. Thank you, -Ben There are 2 versions of the dovecot-antispam package. The original version was created by Johannes Berg, then died almost a silent death, and was forked by Eugene Paskevitch. Later Johannes revived his original version somewhat. The ubuntu package is based on the 'revived Johannes fork' [1], while the documentation on the dovecot wiki describes the 'Eugene fork'. [2] [1] https://launchpad.net/ubuntu/precise/+source/dovecot-antispam/+copyright [2] http://wiki2.dovecot.org/Plugins/Antispam Thus you'll need to choose which plugin you want, then follow the complete procedure for that plugin only. They both can do what you want, but building and configuration are slightly different. It would be nice if Johannes and Eugene would either agree on a single version of the plugin, or rename one of the forks so they don't get mixed up that easily. I'm not sure if that has been discussed (on- or off-list) in the past. FWIW: I used the 'original Johannes fork' with dovecot 1.x, and the 'Eugene fork' with 2.0.x, both with delight. Didn't get myself to upgrade to 2.1 yet, so no experience there. -- Tom
Re: [Dovecot] Trouble implementing Antispam plug-in for Dovecot
On 9/19/2012 6:19 PM, Tom Hendrikx wrote: On 19/09/12 23:41, Ben Johnson wrote: On 9/11/2012 10:40 AM, Ben Johnson wrote: You nailed it, Ben. Thanks! I downloaded/installed the dovecot-dev package from the same maintainer and was able to build Antispam without issue. The hang-up now seems to be with my configuration. I'm seeing the following error in my email client whenever I attempt to move an email message from, say, Inbox to Junk folder: [SERVERBUG] BUG Unknown internal error. Nothing at all appears in syslog when this happens. I followed the instructions at http://wiki2.dovecot.org/Plugins/Antispam , to the letter, I believe. The relevant portions of my configuration are as follows: - protocol imap { mail_plugins = quota imap_quota antispam } plugin { quota = dict:user::file:/var/vmail/%d/%n/.quotausage sieve = /var/vmail/%d/%n/.sieve antispam_backend = MAILTRAIN antispam_mail_sendmail = /usr/bin/sa-learn-pipe.sh antispam_mail_spam = --spam antispam_mail_notspam = --ham antispam_spam_pattern_ignorecase = spam;junk } - The permissions and execute bit are set in accordance with other executables in the same directory: # ls -lah /usr/bin/ | grep -i sa-learn-pipe.sh -rwxr-xr-x 1 root root 297 Sep 5 11:17 sa-learn-pipe.sh I would provide more log content, but the debug options seem to be gone in the forked, = 2.0 version of this plug-in. Any ideas are very much appreciated. Thanks, -Ben Given that nobody shared any insight here, I decided to stand-up a completely new VM with Ubuntu 12.04 LTS and see if the same error occurs. While the error is different this time around, I am still unable to get any variant of the dovecot-antispam plug-in working. When I attempt to use the current packages from Ubuntu 12.04.1 LTS, and I use the above configuration, my syslog fills-up with the following: dovecot: imap-login: Login: user=u...@example.com, method=PLAIN, rip=10.0.1.57, lip=10.0.1.8, mpid=2879, TLS dovecot: master: Error: service(imap): child 2879 returned error 3 Surprisingly, I can find only two other mentions of error 3 anywhere on the Internet. Those mentions were from another user to this mailing list: http://www.dovecot.org/list/dovecot/2012-August/067787.html http://www.dovecot.org/list/dovecot/2012-August/067814.html The lack of error 3 ubiquity leads me to believe that I must be doing something stupid. There's no question that this behavior is related to the antispam-plugin, because when I commented-out the relevant lines in Dovecot's configuration file, the error does not occur. I have followed the instructions at http://wiki2.dovecot.org/Plugins/Antispam to the letter, and this is the result. The only instance in which I diverged from the Wiki article is that I used the Ubuntu-provided dovecot-antispam package (instead of compiling the plug-in from source). I am trying to use the mailtrain back-end, per the above-cited Wiki article, to call SpamAssassin's sa-learn utility for real-time learning. I am not using the SpamAssassin daemon (spamd). I'm about to throw in the towel on this plug-in, so any help would be greatly appreciated. Thank you, -Ben There are 2 versions of the dovecot-antispam package. The original version was created by Johannes Berg, then died almost a silent death, and was forked by Eugene Paskevitch. Later Johannes revived his original version somewhat. The ubuntu package is based on the 'revived Johannes fork' [1], while the documentation on the dovecot wiki describes the 'Eugene fork'. [2] [1] https://launchpad.net/ubuntu/precise/+source/dovecot-antispam/+copyright [2] http://wiki2.dovecot.org/Plugins/Antispam Thus you'll need to choose which plugin you want, then follow the complete procedure for that plugin only. They both can do what you want, but building and configuration are slightly different. It would be nice if Johannes and Eugene would either agree on a single version of the plugin, or rename one of the forks so they don't get mixed up that easily. I'm not sure if that has been discussed (on- or off-list) in the past. FWIW: I used the 'original Johannes fork' with dovecot 1.x, and the 'Eugene fork' with 2.0.x, both with delight. Didn't get myself to upgrade to 2.1 yet, so no experience there. -- Tom Thank you for your timely response, Tom. Much appreciated. Your remarks clear-up a lot of the confusion for me. I didn't realize that the revived Johannes fork made a comeback for Dovecot 2. Nor did I realize that this is the version that is packaged with Ubuntu 12.04. Given that I'm more-or-less forced to work with Ubuntu LTS, I would prefer to use the OS's package management system wherever possible. I suppose, by extension, that I would prefer to use the revived Johannes fork. I've tried the Johannes versions (for both Dovecot 1 and Dovecot 2), but am unable to get