Ethereal development <ethereal-dev@xxxxxxxxxxxx> schrieb am 29.03.05 21:50:50:
>
> packet-sdp.c
> - bump up SDP_MAX_PAYLOAD_TYPES to 20 (I have an mgcp capture where a media
> gateway responded with 12 media types, resulting in a crash). Probably more
> care needs to be taken while parsing the list of media types though...
>
Simply increasing is a bit simple. If you get a capture with 22 media types Ethereal will probably crash again.
Well, the code:
if (transport_info->media_pt_count < SDP_MAX_RTP_PAYLOAD_TYPES)
transport_info->media_pt_count++;
will make transport_info->media_pt_count to a max of SDP_MAX_RTP_PAYLOAD_TYPES (which is an "off by one" error), so
if (transport_info->media_pt_count < SDP_MAX_RTP_PAYLOAD_TYPES - 1)
transport_info->media_pt_count++;
is a bit ugly, but should prevent Ethereal from a crash here.
I currently only have web access, so no line numbers, no patch and no commits :-(
Regards, ULFL
______________________________________________________________
Verschicken Sie romantische, coole und witzige Bilder per SMS!
Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193