charset_to_utf8 assertion of remaining src_size

Xin Li delphij at delphij.net
Fri May 22 21:44:49 UTC 2015


On 05/22/15 13:18, Cassidy Larson wrote:
> We're using FreeBSD 10.1

I see.  Yes that's the same problem I have seen.

There is a behavioral difference (I think it's a FreeBSD bug) between
FreeBSD's iconv(3) and GNU implementation, and there is arguably a bug
with Dovecot that iconv(3) state should be reset for each multipart
part.  The two together would trigger the problem when the previous part
was ended with UTF-7 shift sequence.  Timo have applied a fix (hg:
18721:9809f68aaa36) for Dovecot which should mitigates this issue at
Dovecot side a few days ago.

I have created a reproduction program and discussed the issue with our
iconv(3) developer, Tijl Coosemans <tijl@>, who have created a patch to
correct this FreeBSD iconv(3) bug (not yet committed against -HEAD but
I'd expect it happening soon).

Cheers,
-- 
Xin LI <delphij at delphij.net>    https://www.delphij.net/
FreeBSD - The Power to Serve!           Live free or die
-------------- next part --------------
A non-text attachment was scrubbed...
Name: iconv-utf7.patch
Type: text/x-patch
Size: 2887 bytes
Desc: not available
URL: <http://dovecot.org/pipermail/dovecot/attachments/20150522/78061d7c/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <http://dovecot.org/pipermail/dovecot/attachments/20150522/78061d7c/attachment.sig>


More information about the dovecot mailing list