[zeromq-dev] Zproto framesize calculation for UTF-8 in Java
Marcel Möhring
marcel.moehring at catapullt.de
Thu Mar 9 14:56:16 CET 2017
Hi,
I’m experiencing a buffer overflow when using utf-8 with an zproto/gsl generated message class.
The framesize for strings seems to be calculated based on the number of characters in a string.
Later the bytes of the string are put into a buffer and when the string contains multi byte characters, the buffer overflows.
Has anyone else experienced this behavior?
Or is this behavior intended, i.e. am I using it wrong?
Cheers,
Marcel
--
marcel.moehring at catapullt.de <mailto:marcel.moehring at catapullt.de>
http://www.catapullt.de/ <http://www.catapullt.de/>
Büro: +49 202 430427-20
Mobil: +49 173 7265151
Fax: +49 202 430427-09
catapullt GmbH & Co. KG
In der Gelpe 79
42349 Wuppertal
Geschäftsführer: Jürgen Weinrich
Amtsgericht: Wuppertal, HRA: 22523
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.zeromq.org/pipermail/zeromq-dev/attachments/20170309/7cd89c82/attachment.htm>
More information about the zeromq-dev
mailing list