Hi, Attached a patch to fix the decoding of AMF_LONG_STRINGs. Previous code treated it as a 16-bit length string. Does not fix encoding of long strings. There will probably be some nasty overflow if someone tries to encode a string that's too long, and I see no code currently preventing that (apart from buffer length restrictions).
Sorry to bump an old thread, but I just realized this never got a response. :-) On Wed, Jan 20, 2010 at 3:51 PM, NhJm <nhjm449@gmail.com> wrote:
Hi,
Attached a patch to fix the decoding of AMF_LONG_STRINGs. Previous code treated it as a 16-bit length string.
Does not fix encoding of long strings. There will probably be some nasty overflow if someone tries to encode a string that's too long, and I see no code currently preventing that (apart from buffer length restrictions).
NhJm wrote:
Sorry to bump an old thread, but I just realized this never got a response. :-)
Thanks, slipped thru the cracks. Fixed now, and encoding is fixed too.
On Wed, Jan 20, 2010 at 3:51 PM, NhJm<nhjm449@gmail.com> wrote:
Hi,
Attached a patch to fix the decoding of AMF_LONG_STRINGs. Previous code treated it as a 16-bit length string.
Does not fix encoding of long strings. There will probably be some nasty overflow if someone tries to encode a string that's too long, and I see no code currently preventing that (apart from buffer length restrictions).
participants (2)
-
Howard Chu -
NhJm