Re: Sieve_default
Am 12.06.2018 um 01:01 schrieb @lbutlr: I created a sieve_default to move any spam-tagged messages into the Junk mailbox automatically, but it doesn’t appear to be working (though the other imapsieve_mailbox… scripts are working). From doveconf -n plugin { imapsieve_mailbox1_before = file:/usr/lib/dovecot/sieve/report-spam.sieve imapsieve_mailbox1_causes = COPY imapsieve_mailbox1_name = Junk imapsieve_mailbox2_before = file:/usr/lib/dovecot/sieve/report-ham.sieve imapsieve_mailbox2_causes = COPY imapsieve_mailbox2_from = Junk imapsieve_mailbox2_name = * imapsieve_mailbox3_before = file:/usr/lib/dovecot/sieve/mark-read.sieve imapsieve_mailbox3_causes = COPY imapsieve_mailbox3_name = Archive sieve = file:~/.sieve;active=~/.active_sieve sieve_default = /usr/lib/dovecot/sieve/default.sieve sieve_default_name = spamassassin sieve_global_extensions = +vnd.dovecot.pipe +vnd.dovecot.environment sieve_pipe_bin_dir = /usr/lib/dovecot/sieve sieve_plugins = sieve_imapsieve sieve_extprograms } And # cat /usr/lib/dovecot/sieve/default.sieve if header :contains "X-spam-flag" "YES" { fileinto "Junk"; } There are no user sieve files # find /home -name "*sieve*" -type f # The x-spam-flag header in the message in my mailbox is definitely there and definitely set to yes. I think you need to enable the 'fileinto' extension via 'require'. And did you pre-compile the script? -- Alex JOST
cant login to Dovecot
Hi all, I can't login. This is a dovecot server for a small inhouse network, and I doon't use any encryption, and just want to login using the standard Linux login dovecot status gives me the following error messages: un 12 12:30:06 ulmke2 dovecot[5814]: auth: Fatal: APOP mechanism can't be supported with given passdbs Jun 12 12:30:06 ulmke2 dovecot[5811]: master: Error: service(auth): command startup failed, throttling for 32 secs Jun 12 12:30:06 ulmke2 dovecot[5814]: imap-login: Disconnected: Auth process broken (disconnected before auth was ready, waited 10 secs): user=<>, rip=192.168.100.29, lip=192.168.100.2, session= Jun 12 12:30:06 ulmke2 dovecot[5814]: imap-login: Warning: Timeout leak: 0x7fa8a7d372a0 (auth-server-connection.c:397) Jun 12 12:30:16 ulmke2 dovecot[5814]: imap-login: Warning: Auth process not responding, delayed sending initial response (greeting): user=<>, rip=192.168.100.29, lip=192.168.100.2, session= Jun 12 12:30:36 ulmke2 dovecot[5814]: imap-login: Error: Timeout waiting for handshake from auth server. my pid=5874, input bytes=0 Jun 12 12:30:36 ulmke2 dovecot[5814]: imap-login: Disconnected: Auth process broken (disconnected before auth was ready, waited 30 secs): user=<>, rip=192.168.100.29, lip=192.168.100.2, session= Jun 12 12:30:38 ulmke2 dovecot[5814]: auth: Error: stats: open(old-stats-user) failed: Permission denied Jun 12 12:30:38 ulmke2 dovecot[5814]: auth: Fatal: APOP mechanism can't be supported with given passdbs Jun 12 12:30:38 ulmke2 dovecot[5811]: master: Error: service(auth): command startup failed, throttling for 60 secs I'm moving to a new server. stats: open(old-stats-user) failed: Permission denied This file may be somewhere on the old server. Can anyone help me? -- -- Best Regards, Walter Ulmke
Re: cant login to Dovecot
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Tue, 12 Jun 2018, Walter Ulmke wrote: un 12 12:30:06 ulmke2 dovecot[5814]: auth: Fatal: APOP mechanism can't be supported with given passdbs Config error. "Fatal" sounds fatal ;-) stats: open(old-stats-user) failed: Permission denied Likewise config error, but not fatal. Post your config - -- Steffen Kaiser -BEGIN PGP SIGNATURE- Version: GnuPG v1 iQEVAwUBWx+rFMQnQQNheMxiAQL4kgf+NIOIf/sUgrloibuBz2HyTEwsdFma7/OS jb7ibn9GkG5Q+72Jlfei/O6CG/v6t0poUgGrRhEOU6JTMLwkHB5PQgip8Spu4C1S K16HMRBHOibOjAhoS2JB/On2KRTb6qH3gNd//xuPbkM3tjTT3s+YoI3+Yg+2dVbp 3L4Bfb9ajosYzD3fb2L+UH1EFIyXY73GqUriXJCxApMbTTCGrvZQ6mEqObVCUqiR 8mbx72v4Es/RgXpXJT1DAvoJanGEbUk7YE7SWTHYUzQ3JyN9KtUYIgn6pca9mmWI y8GRn3nIHOI6ny2HCDp5SyFKQ7A0GJeVHLECUjD8Wv/uXF/8tpADWQ== =gFZM -END PGP SIGNATURE-
Re: cant login to Dovecot
On 2018-06-12 13:14, Steffen Kaiser wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Tue, 12 Jun 2018, Walter Ulmke wrote: un 12 12:30:06 ulmke2 dovecot[5814]: auth: Fatal: APOP mechanism can't be supported with given passdbs Config error. "Fatal" sounds fatal ;-) stats: open(old-stats-user) failed: Permission denied Likewise config error, but not fatal. Post your config - -- Steffen Kaiser -BEGIN PGP SIGNATURE- Version: GnuPG v1 Hi Steffen, the output from doveconf -n: auth_mechanisms = plain login digest-md5 cram-md5 ntlm rpa apop anonymous gssapi managesieve_notify_capability = mailto managesieve_sieve_capability = fileinto reject envelope encoded-character vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy include variables body enotify environment mailbox date index ihave duplicate mime foreverypart extracttext namespace inbox { inbox = yes location = mailbox Drafts { special_use = \Drafts } mailbox Junk { special_use = \Junk } mailbox Sent { special_use = \Sent } mailbox "Sent Messages" { special_use = \Sent } mailbox Trash { special_use = \Trash } prefix = } passdb { driver = pam } plugin { sieve = file:~/sieve;active=~/.dovecot.sieve } ssl = no ssl_cipher_list = ALL:!aNULL:!eNULL:!EXPORT:!DES:!3DES:!MD5:!PSK:!RC4:!ADH:!LOW@STRENGTH ssl_options = no_compression ssl_prefer_server_ciphers = yes userdb { driver = passwd } -- -- Best Regards, Walter Ulmke
Re: Race condition when setting flags (\Deleted) + expunge quickly, leaving mails not deleted
On 22 April, 2018 - Tomas Forsman wrote: > On 21 March, 2018 - Aki Tuomi wrote: > > > Thank you for your thorough report, we'll look into it. > > Has anyone managed to reproduce this (using my transcript for example)? Anyone? I would guess more people are affected.. /Tomas -- Tomas Forsman, st...@cs.umu.se, http://people.cs.umu.se/stric/ `- SysAdmin at Computing Science, University of Umeå > With mutt, I get this problem.. If I set 'imap_pipeline_depth=0' in > .muttrc, I can't seem to reproduce it anymore. > > /Tomas > -- > Tomas Forsman, st...@cs.umu.se, http://people.cs.umu.se/stric/ > `- SysAdmin at Computing Science, University of Umeå > > > Aki > > > > > > On 20.03.2018 16:56, Tomas Forsman wrote: > > > Hello. > > > > > > I seem to have found a race condition, when setting flags on multiple > > > emails > > > rapidly. 5 commands including login to reproduce. Problem found using > > > mutt in > > > real world usage. > > > > > > Seems to happen both with UID STORE 1:3 and UID STORE 1,2,3 .. > > > > > > I have tried with the following packages, with a minimized config in a > > > throwaway vm: > > > https://packages.debian.org/stretch/dovecot-core > > > Package: dovecot-core (1:2.2.27-3+deb9u2) > > > > > > https://packages.debian.org/stretch-backports/dovecot-core > > > Package: dovecot-core (1:2.2.34-2~bpo9+1) > > > > > > Also tested pristine: > > > https://dovecot.org/releases/2.3/dovecot-2.3.0.1.tar.gz > > > https://dovecot.org/releases/2.2/dovecot-2.2.34.tar.gz > > > https://dovecot.org/releases/2.2/dovecot-2.2.35.tar.gz > > > .. built on Debian9 with: > > > # apt-get build-dep dovecot-core > > > # bash configure --prefix=/scratch/dovecot-test > > > > > > Tried with both mailbox over NFS (backed by ext4), and also mailbox on > > > ext4. > > > > > > On my test systems, I am only able to reproduce it with > > > mbox_lazy_writes=no, > > > but with production settings on a Ubuntu 14.04 with 1:2.2.9-1ubuntu2.4 > > > that has > > > mbox_lazy_writes=yes it is still reproducable with mutt. > > > > > > I have found two different ways to reproduce it with netcat + cut'n'paste, > > > below is done with 2.2.34/35. > > > > > > All servers are VMs in Ganeti/kvm clusters (Debian hosts in one > > > cluster&organization, Ubuntu host in another cluster&organization). > > > > > > > > > Debian minimized config: > > >> doveconf -n > > > # 2.2.34 (874deae): /etc/dovecot/dovecot.conf > > > # Pigeonhole version 0.4.22 (22940fb7) > > > # OS: Linux 4.9.0-6-amd64 x86_64 Debian 9.4 > > > # Hostname: mail2-vm.cs.umu.se > > > auth_mechanisms = plain login > > > auth_verbose = yes > > > debug_log_path = syslog > > > info_log_path = syslog > > > mail_location = mbox:~/Mail:INBOX=/var/mail/%u > > > mail_privileged_group = mail > > > mbox_lazy_writes = no > > > namespace inbox { > > > inbox = yes > > > location = > > > prefix = > > > } > > > passdb { > > > driver = pam > > > } > > > protocols = imap > > > service auth { > > > client_limit = 2500 > > > unix_listener auth-client { > > > group = postfix > > > mode = 0660 > > > } > > > } > > > service imap-login { > > > inet_listener imap { > > > port = 143 > > > } > > > } > > > service imap { > > > executable = imap > > > } > > > ssl = no > > > syslog_facility = local1 > > > userdb { > > > driver = passwd > > > } > > > > > > > > > Attached is a mailbox that can be used to reproduce the problem, called > > > "error-box", anonymized with mbox-anonymize.pl. It was created by sending > > > test > > > messages with mutt 1.7.2 through Dovecot/Postfix/Amavis. > > > > > > > > > > > > Method 1, with IDLE: > > > > > > Setup a local account, MY-USER / MY-PASSWORD (replace below). > > > > > >> mkdir Mail > > >> cp error-box Mail/error1 > > >> nc -v localhost 143 > > > Paste the following 3 lines in a go: > > > a LOGIN "MY-USER" "MY-PASSWORD" > > > a0010 SELECT "error1" > > > a0020 IDLE > > > > > > then wait a second.. then paste the following 3 in a go: > > > DONE > > > a0030 UID STORE 1:3 +FLAGS (\Deleted) > > > a0040 EXPUNGE > > > > > > Notice that the results from UID STORE + EXPUNGE gives: > > > * 2 FETCH (UID 2 FLAGS (\Recent)) > > > * 3 FETCH (UID 3 FLAGS (\Recent)) > > > * 1 EXPUNGE > > > * 3 RECENT > > > a0030 OK Store completed (0.004 + 0.000 + 0.003 secs). > > > a0040 OK Expunge completed (0.004 + 0.000 + 0.003 secs). > > > > > > > > > Verify what's left in the mailbox with: > > > a0050 UID FETCH 1:4 FLAGS > > > * 1 FETCH (UID 2 FLAGS (\Recent)) > > > * 2 FETCH (UID 3 FLAGS (\Recent)) > > > * 3 FETCH (UID 4 FLAGS (\Recent)) > > > a0050 OK Fetch completed (0.001 + 0.000 secs). > > > > > > > > > Since 1 to 3 should be \Deleted and then EXPUNGEd, we should only have > > > UID 4 > > > left, not uid 2-4 without Deleted flag. > > > > > > > > > Try same again, but with 1 inserted delay (use a new mailbox name for > > > every > > > test, otherwise UID numbering will vary, indexes etc): > > >> cp error-box Mail/error2 > > >> nc -v
Re: cant login to Dovecot
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Tue, 12 Jun 2018, Walter Ulmke wrote: Date: Tue, 12 Jun 2018 14:23:30 +0200 From: Walter Ulmke To: dovecot@dovecot.org Subject: Re: cant login to Dovecot On 2018-06-12 13:14, Steffen Kaiser wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Tue, 12 Jun 2018, Walter Ulmke wrote: un 12 12:30:06 ulmke2 dovecot[5814]: auth: Fatal: APOP mechanism can't be supported with given passdbs Config error. "Fatal" sounds fatal ;-) see below. Update your mechs stats: open(old-stats-user) failed: Permission denied There is no stats config. Likewise config error, but not fatal. Post your config auth_mechanisms = plain login digest-md5 cram-md5 ntlm rpa apop anonymous gssapi https://wiki2.dovecot.org/Authentication/Mechanisms?highlight=(apop) APOP: This is a POP3-specific authentication. Similar to CRAM-MD5, but requires storing password in plaintext. But PAM does not offer access to plain/text, IMHO. managesieve_notify_capability = mailto managesieve_sieve_capability = fileinto reject envelope encoded-character vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy include variables body enotify environment mailbox date index ihave duplicate mime foreverypart extracttext namespace inbox { inbox = yes location = mailbox Drafts { special_use = \Drafts } mailbox Junk { special_use = \Junk } mailbox Sent { special_use = \Sent } mailbox "Sent Messages" { special_use = \Sent } mailbox Trash { special_use = \Trash } prefix = } passdb { driver = pam } plugin { sieve = file:~/sieve;active=~/.dovecot.sieve } ssl = no ssl_cipher_list = ALL:!aNULL:!eNULL:!EXPORT:!DES:!3DES:!MD5:!PSK:!RC4:!ADH:!LOW@STRENGTH ssl_options = no_compression ssl_prefer_server_ciphers = yes userdb { driver = passwd } - -- Steffen Kaiser -BEGIN PGP SIGNATURE- Version: GnuPG v1 iQEVAwUBWx/IGsQnQQNheMxiAQLZaQgAwqOE59dZoXqcBkYYmdgiej4glYRhjaSl kwZeY6aFHjoErXK9B2VmrL9atmcMWoI3cocoCzpk5lib5CDuAXdQujCWluT/B/CK 5597D/OG77GhlWhG73Dptytkc03qjx3l4XipkcVrNKtuKVtKO1POFnldfIyUb0mr v73XsTo6trbQu9+S+oK9nZGrUUnirGivz+aVj6Xe2JNke69H8Et6LOJdmQdDxKqR gmGKXwtPMspX5yKOb/4oOLnc6yzif+RVSdC8wcMyGc3dQapVIRKtFOceal5B3eu9 PopaPlTmLTA27GmbxlNbQYP/YZnAxlZTTCvls28fegm1mVfpQeQ9qg== =HFv8 -END PGP SIGNATURE-
2.3.1: Core dump on quota reach
Just upgraded from 2.2.34 to 2.3.1: Jun 12 16:06:38 lmtp(exam...@example.name)<46176><8JrHEW7TH1tgtAAAd9aEAw>: Info: msgid=: save failed to INBOX: The email account that you tried to reach is over quota (Mailbox is full). Jun 12 16:06:38 lmtp(exam...@example.name)<46176><8JrHEW7TH1tgtAAAd9aEAw>: Fatal: master: service(lmtp): child 46176 killed with signal 11 (core dumps disabled - https://dovecot.org/bugreport.html#coredumps) And also, unrelated: Jun 12 16:21:32 lmtp(53430): Error: lmtp-server: conn director.local:39204 [6]: Connection lost during data transfer: read(director.local:39204 [6]) failed: -- Tom
Re: cant login to Dovecot
On 2018-06-12 15:18, Steffen Kaiser wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Tue, 12 Jun 2018, Walter Ulmke wrote: Date: Tue, 12 Jun 2018 14:23:30 +0200 From: Walter Ulmke To: dovecot@dovecot.org Subject: Re: cant login to Dovecot On 2018-06-12 13:14, Steffen Kaiser wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Tue, 12 Jun 2018, Walter Ulmke wrote: un 12 12:30:06 ulmke2 dovecot[5814]: auth: Fatal: APOP mechanism can't be supported with given passdbs Config error. "Fatal" sounds fatal ;-) see below. Update your mechs stats: open(old-stats-user) failed: Permission denied There is no stats config. Likewise config error, but not fatal. Post your config auth_mechanisms = plain login digest-md5 cram-md5 ntlm rpa apop anonymous gssapi https://wiki2.dovecot.org/Authentication/Mechanisms?highlight=(apop) APOP: This is a POP3-specific authentication. Similar to CRAM-MD5, but requires storing password in plaintext. But PAM does not offer access to plain/text, IMHO. managesieve_notify_capability = mailto managesieve_sieve_capability = fileinto reject envelope encoded-character vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy include variables body enotify environment mailbox date index ihave duplicate mime foreverypart extracttext namespace inbox { inbox = yes location = mailbox Drafts { special_use = \Drafts } mailbox Junk { special_use = \Junk } mailbox Sent { special_use = \Sent } mailbox "Sent Messages" { special_use = \Sent } mailbox Trash { special_use = \Trash } prefix = } passdb { driver = pam } plugin { sieve = file:~/sieve;active=~/.dovecot.sieve } ssl = no ssl_cipher_list = ALL:!aNULL:!eNULL:!EXPORT:!DES:!3DES:!MD5:!PSK:!RC4:!ADH:!LOW@STRENGTH ssl_options = no_compression ssl_prefer_server_ciphers = yes userdb { driver = passwd } - -- Steffen Kaiser -BEGIN PGP SIGNATURE- Version: GnuPG v1 iQEVAwUBWx/IGsQnQQNheMxiAQLZaQgAwqOE59dZoXqcBkYYmdgiej4glYRhjaSl kwZeY6aFHjoErXK9B2VmrL9atmcMWoI3cocoCzpk5lib5CDuAXdQujCWluT/B/CK 5597D/OG77GhlWhG73Dptytkc03qjx3l4XipkcVrNKtuKVtKO1POFnldfIyUb0mr v73XsTo6trbQu9+S+oK9nZGrUUnirGivz+aVj6Xe2JNke69H8Et6LOJdmQdDxKqR gmGKXwtPMspX5yKOb/4oOLnc6yzif+RVSdC8wcMyGc3dQapVIRKtFOceal5B3eu9 PopaPlTmLTA27GmbxlNbQYP/YZnAxlZTTCvls28fegm1mVfpQeQ9qg== =HFv8 -END PGP SIGNATURE- PAM war mir immer schon suspekt. Ich habe den Bereich auskommentiert und erhalte nun: auth: Error: stats: open(old-stats-user) failed: Permission denied Jun 12 17:04:44 ulmke2 dovecot[6883]: auth: Fatal: No passdbs specified in configuration file. APOP mechanism need> Jun 12 17:04:44 ulmke2 dovecot[6880]: master: Error: service(auth): command startup failed, throttling for 2 secs Jun 12 17:04:44 ulmke2 dovecot[6883]: imap-login: Disconnected: Auth process broken (disconnected before auth was > -- -- Best Regards, Walter Ulmke
Re: cant login to Dovecot
Am 12.06.2018 um 17:10 schrieb Walter Ulmke: PAM war mir immer schon suspekt. Ich habe den Bereich auskommentiert und erhalte nun: auth: Error: stats: open(old-stats-user) failed: Permission denied Jun 12 17:04:44 ulmke2 dovecot[6883]: auth: Fatal: No passdbs specified ^^ in configuration file. APOP mechanism need> Jun 12 17:04:44 ulmke2 dovecot[6880]: master: Error: service(auth): command startup failed, throttling for 2 secs Jun 12 17:04:44 ulmke2 dovecot[6883]: imap-login: Disconnected: Auth process broken (disconnected before auth was > -- -- Best Regards, Walter Ulmke Wait, you have removed passdb { driver = pam } from your configuration? That's the wrong part. Strip down auth_mechanisms to the mechanism(s) you really want to support and use. Forget about apop and use plain. And and SSL configuration is incomplete. Alexander
Re: 2.3.1: Core dump on quota reach
> On 12 June 2018 at 17:27 Tom Sommer wrote: > > > Just upgraded from 2.2.34 to 2.3.1: > > Jun 12 16:06:38 > lmtp(exam...@example.name)<46176><8JrHEW7TH1tgtAAAd9aEAw>: Info: > msgid=: > > save failed to INBOX: The email account that you tried to reach is over > quota (Mailbox is full). > Jun 12 16:06:38 > lmtp(exam...@example.name)<46176><8JrHEW7TH1tgtAAAd9aEAw>: Fatal: > master: service(lmtp): child 46176 killed with signal 11 (core dumps > disabled - https://dovecot.org/bugreport.html#coredumps) > > > And also, unrelated: > > Jun 12 16:21:32 lmtp(53430): Error: lmtp-server: conn > director.local:39204 [6]: Connection lost during data transfer: > read(director.local:39204 [6]) failed: > > -- > Tom This is fixed with https://github.com/dovecot/core/commit/847790d5aab84df38256a6f9b4849af0eb408419.patch Aki
sievec prints an error if no dovecot running with mail_plugins = stats
Dovecot 2.2.36 + Pigeonhole 0.4.24 Is this an intended behavior? ``` # service dovecot status dovecot is stopped # doveconf mail_plugins mail_plugins = stats # ls foo.* foo.sieve # sievec foo.sieve sievec(root): Error: stats: open(/var/run/dovecot/stats-mail) failed: No such device or address # echo $? 0 # ls foo.* foo.sieve foo.svbin ``` -- -- Name: SATOH Fumiyasu @ OSS Technology Corp. (fumiyas @ osstech co jp) -- Business Home: https://www.OSSTech.co.jp/ -- GitHub Home: https://GitHub.com/fumiyas/ -- PGP Fingerprint: BBE1 A1C9 525A 292E 6729 CDEC ADC2 9DCA 5E1C CBCA
Re: cant login to Dovecot
On Tue, 12 Jun 2018, Walter Ulmke wrote: ... and just want to login using the standard Linux login Depends on what you which "standard" you mean but I'll just assume you're using PAM, as suggested by your config. auth_mechanisms = plain login digest-md5 cram-md5 ntlm rpa apop anonymous Looks like you did a kitchen sink configuration in hopes something will work, but it's probably interfering. Just "plain" and "login" is fine. passdb { driver = pam } I don't use PAM, but it looks like you may be a few parameters short. Did you install pam/dovecot config? https://wiki2.dovecot.org/PasswordDatabase/PAM Joseph Tam