Re: [Dovecot] Segfault in quota-fs plugin

2009-09-28 Thread Timo Sirainen
On Tue, 2009-09-22 at 18:41 -0700, Brandon Davidson wrote:
 I've attached a patch which seems to fix the obvious code issue. I can't
 guarantee it's the correct fix since this is my first poke at the
 Dovecot source, but it seems to have stopped the crashing on our test
 host.

It's the right fix. http://hg.dovecot.org/dovecot-1.2/rev/3132464fbe9c



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


Re: [Dovecot] Segfault in quota-fs plugin

2009-09-23 Thread Ralf Becker
Hi Brandon,

since our patches are very similar, they should be a good way to fix
this issue. For me it's working since 7 days now without a harm.

See: http://markmail.org/message/p736w5f4dmamfnom

Ralf

Brandon Davidson schrieb am 23.09.2009 03:41:
 Hi all,
 
 We recently attempted to update our Dovecot installation to version
 1.2.5. After doing so, we noticed a constant stream of crash messages in
 our log file:
 
 Sep 22 15:58:41 hostname dovecot: imap-login: Login: user=USERNAME,
 method=PLAIN, rip=X.X.X.X, lip=X.X.X.X, TLS
 Sep 22 15:58:41 hostname dovecot: dovecot: child 6339 (imap) killed with
 signal 11 (core dumps disabled)
 
 We rolled back to version 1.2.4, and installed 1.2.5 on a test system -
 something we'll have to make sure to do *before* rolling new versions
 into production.
 
 Anyway, after examining a few core files from the test system, it looks
 like the recent changes to the quota plugin (specifically the maildir
 backend's late initialization fix) have broken the other backends. Stack
 trace and further debugging are available here:
 http://uoregon.edu/~brandond/dovecot-1.2.5/bt.txt
 
 The relevant code seems to have been added in changeset 9380:
 http://hg.dovecot.org/dovecot-1.2/rev/fe063e0d7109
 
 Specifically, quota.c line 447 does not check to see if the backend
 implements init_limits before calling it, resulting in a null function
 call for all backends that do not do so. Since this crash would appear
 to affect all quota backends other than maildir, it should be a pretty
 easy to reproduce.
 
 I've attached a patch which seems to fix the obvious code issue. I can't
 guarantee it's the correct fix since this is my first poke at the
 Dovecot source, but it seems to have stopped the crashing on our test
 host.
 
 Regards,
 
 -Brandon

-- 
__

 Dipl.-Inform. (FH) Ralf Becker Rechenzentrum (r/ft) der FH Trier
 (Network|Mail|Web|Firewall)   University of applied sciences
 Administrator   Schneidershof, D-54293 Trier

   Mail: beck...@fh-trier.deFon: +49 651 8103 499
Web: http://www.fh-trier.de/~beckerrFax: +49 651 8103 214
 PubKey: http://www.fh-trier.de/~beckerr Crypto: GnuPG, S/MIME
__

 Wenn Gott gewollt haette, dass E-Mail in HTML geschrieben wuerden,
 endeten Gebete traditionell mit /amen. (Tom Listen)


smime.p7s
Description: S/MIME Cryptographic Signature


[Dovecot] Segfault in quota-fs plugin

2009-09-22 Thread Brandon Davidson
Hi all,

We recently attempted to update our Dovecot installation to version
1.2.5. After doing so, we noticed a constant stream of crash messages in
our log file:

Sep 22 15:58:41 hostname dovecot: imap-login: Login: user=USERNAME,
method=PLAIN, rip=X.X.X.X, lip=X.X.X.X, TLS
Sep 22 15:58:41 hostname dovecot: dovecot: child 6339 (imap) killed with
signal 11 (core dumps disabled)

We rolled back to version 1.2.4, and installed 1.2.5 on a test system -
something we'll have to make sure to do *before* rolling new versions
into production.

Anyway, after examining a few core files from the test system, it looks
like the recent changes to the quota plugin (specifically the maildir
backend's late initialization fix) have broken the other backends. Stack
trace and further debugging are available here:
http://uoregon.edu/~brandond/dovecot-1.2.5/bt.txt

The relevant code seems to have been added in changeset 9380:
http://hg.dovecot.org/dovecot-1.2/rev/fe063e0d7109

Specifically, quota.c line 447 does not check to see if the backend
implements init_limits before calling it, resulting in a null function
call for all backends that do not do so. Since this crash would appear
to affect all quota backends other than maildir, it should be a pretty
easy to reproduce.

I've attached a patch which seems to fix the obvious code issue. I can't
guarantee it's the correct fix since this is my first poke at the
Dovecot source, but it seems to have stopped the crashing on our test
host.

Regards,

-Brandon


dovecot-1.2.5-check-init_limits.patch
Description: dovecot-1.2.5-check-init_limits.patch