aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-rtpproxy.c
AgeCommit message (Collapse)AuthorFilesLines
2016-03-20Manually add protocol dependencies derived from find_dissector.Michael Mann1-4/+4
Started by grepping call_dissector_with_data, call_dissector_only and call_dissector and traced the handles passed into them to a find_dissector within the dissector. Then replaced find_dissector with find_dissector_add_dependency and added the protocol id from the dissector. "data" dissector was not considered to be a dependency. Change-Id: I15d0d77301306587ef8e7af5876e74231816890d Reviewed-on: https://code.wireshark.org/review/14509 Petri-Dish: Michael Mann <mmann78@netscape.net> Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-01-24Add the packet number to the packet_info structure, and use it.Guy Harris1-4/+4
That removes most of the uses of the frame number field in the frame_data structure. Change-Id: Ie22e4533e87f8360d7c0a61ca6ffb796cc233f22 Reviewed-on: https://code.wireshark.org/review/13509 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2016-01-23Add more fields to packet_info structure and use them.Guy Harris1-2/+2
Add fields for the absolute time stamp (and another field for a presence flag for the absolute time stamp) and the packet encapsulation for the packet. This lets us remove the field for the packet encapsulation in the frame_data structure; do so. Change-Id: Ifb910a9a192414e2a53086f3f7b97f39ed36aa39 Reviewed-on: https://code.wireshark.org/review/13499 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-12-31Don't cast away constness.Guy Harris1-1/+1
Change-Id: I14130b4be91f36a4dbc187f2eef6d6c438a75774 Reviewed-on: https://code.wireshark.org/review/12975 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2015-12-09new_create_dissector_handle -> create_dissector_handle for dissector directory.Michael Mann1-2/+2
Some of the ASN.1 dissectors still generate a new_create_dissector_handle from the tool itself, so leave those for now. Change-Id: Ic6e5803b1444d7ac24070949f5fd557909a5641f Reviewed-on: https://code.wireshark.org/review/12484 Petri-Dish: Anders Broman <a.broman58@gmail.com> Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-10-14Change proto_tree_add_ipv6() to take a struct e_in6_addr pointerJoão Valverde1-4/+4
tvb_get_ipv6() takes a struct e_in6_addr *, use that here too. Change-Id: Id8b368daa05c151a61d4bc01dc88c00da13e9c88 Reviewed-on: https://code.wireshark.org/review/10953 Reviewed-by: Michael Mann <mmann78@netscape.net> Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Balint Reczey <balint@balintreczey.hu> Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2015-06-23Remove more deprecated tvb_lengthEvan Huus1-1/+1
Change-Id: I36603453c2563406f82663683930088dedd5f39c Reviewed-on: https://code.wireshark.org/review/9041 Reviewed-by: Evan Huus <eapache@gmail.com>
2015-06-04rtp/pm proxy: fix implicit conversion shortens 64-bit value into a 32-bit valueAlexis La Goutte1-1/+1
packet-pmproxy.c:93: warning: implicit conversion shortens 64-bit value into a 32-bit value packet-pmproxy.c:94: warning: implicit conversion shortens 64-bit value into a 32-bit value packet-pmproxy.c:95: warning: implicit conversion shortens 64-bit value into a 32-bit value packet-rtpproxy.c:831: warning: implicit conversion shortens 64-bit value into a 32-bit value Change-Id: Ibf1491c1e56dfe6684fe2fe67edc1a721d5de56f Reviewed-on: https://code.wireshark.org/review/8753 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2015-06-04[RTPproxy] Simplify positive reply parsing and minor cleanupsPeter Lemenkov1-14/+33
* Merge both 'positive reply' and 'version ack' processing into one block. * Also use realsize where possible instead of recalculating packet's size again. * Add a bit more comments. * Remove some 'magic' numbers. Use actual string sizes instead. * Skip trailing zeroes inserted by some old SIP-servers. Change-Id: Ie66aa4d6e807a1f351b62d36333301fdec1550fa Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/8738 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-06-02[RTPproxy] Set column name to RTPProxy-ngPeter Lemenkov1-0/+1
Set column name to RTPProxy-ng if a new protocol is used. Change-Id: I8c79ad5426808ad6944060e9c12fa4ac1f02e432 Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/8737 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-05-26[RTPproxy] Remove non-existent replyPeter Lemenkov1-7/+0
This reply message was never implemented anywhere. Current protocol spec doesn't mention this type of a reply either: * https://github.com/sippy/rtpproxy/wiki/RTPP-%28RTPproxy-protocol%29-technical-specification#information So we should remove this. Change-Id: I4e5efef24c6859d5a4a0ba08e3e4cca6d7b217f2 Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/8656 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-05-22Cosmetic - adjust comments according to the protoPeter Lemenkov1-1/+2
Change-Id: I75b422d3181e93e12d6758d891538fa9fea7d1f7 Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/8574 Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-05-22TypoPeter Lemenkov1-1/+1
Change-Id: Ib50768ccca6e0354d287793ce639e28bee2c9865 Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/8573 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-05-22Don't treat packets w/o line feed differentlyPeter Lemenkov1-5/+6
Change-Id: I7ddd0ecf5e4f02f66b9fea528725a5e29c1062ea Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/8572 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-05-22Change unofficial extension parameterPeter Lemenkov1-3/+3
A character "v" was mapped to a different command parameter. So we should replace it. Change-Id: Ia668b0b0bead7bb4c4ba0a60f51f53daf2095a36 Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/8571 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-04-30Add correct decoding of a Il commandPeter Lemenkov1-8/+13
That's another one protocol shortcoming - the same parameter used twice: * https://github.com/sippy/rtpproxy/wiki/RTPP-%28RTPproxy-protocol%29-technical-specification#createupdatelookup-session * https://github.com/sippy/rtpproxy/wiki/RTPP-%28RTPproxy-protocol%29-technical-specification#get-information Change-Id: I9ccc05579b0a1c28b8180eb56a2eb51fc803c063 Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/8250 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2015-04-30Clarify command parameters meaningsPeter Lemenkov1-4/+4
See these links for a "single file" parameter: * https://github.com/sippy/rtpproxy/wiki/RTPP-%28RTPproxy-protocol%29-technical-specification#record-stream * https://github.com/sippy/rtpproxy/wiki/RTPP-%28RTPproxy-protocol%29-technical-specification#copy-stream Change-Id: I23275898f98121215294c3c1a7a0ee727097d250 Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/8249 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2015-04-30Parse another one missing command modifierPeter Lemenkov1-0/+2
Parse another one missing command modifier - "request New port". See protocol description for the details: https://github.com/sippy/rtpproxy/wiki/RTPP-%28RTPproxy-protocol%29-technical-specification#createupdatelookup-session Change-Id: I4a49b0715022dca250ef0def75fb2e7983aaca1b Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/8248 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2015-04-24Update list of errorsPeter Lemenkov1-14/+38
Update list of errors according to the formal protocol description: https://github.com/sippy/rtpproxy/wiki/RTPP-%28RTPproxy-protocol%29-technical-specification#negative-reply Change-Id: I879521ee2bd69969491fb6e6493b7d1c6adc0c3d Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/8185 Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2015-04-24Update version stringsPeter Lemenkov1-0/+4
Change-Id: I0e83e42ee6080aab2a9a9d4dc0d195f0849137ee Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/8184 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2015-04-24Use alloc0 to simplify further initialisationPeter Lemenkov1-3/+1
Change-Id: Ib333c2827a13927acd3cfcf28c200909d9d38685 Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/8183 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2014-12-25Deleting unnecessary #includes from dissectors.Martin Mathieson1-1/+0
Fifth batch (packet-rtp.c -> end). Will look at cleaning up and committing script afterwards. Change-Id: I8ed61dc941d98d3f7259a9d1f74e214eb7b4bfa2 Reviewed-on: https://code.wireshark.org/review/6052 Reviewed-by: Martin Mathieson <martin.r.mathieson@googlemail.com>
2014-12-21Cleanup use of #includes in non-generated epan/dissector/*.cBill Meier1-2/+1
Specifically: - Set packet.h to be the first wireshark #include after config.h and "system" #includes. packet.h added as an #include in some cases when missing. - Remove some #includes included (directly/indirectly) in packet.h. E.g., glib.h. (Done only for those files including packet.h). - As needed, move "system" #includes to be after config.h and before wireshark #includes. - Rework various #include file specifications for consistency. - Misc. Change-Id: Ifaa1a14b50b69fbad38ea4838a49dfe595c54c95 Reviewed-on: https://code.wireshark.org/review/5923 Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-12-13Use ENC_BIG_ENDIAN when fetching FT_U?INT8 fields ...Bill Meier1-4/+4
Change-Id: Ie8cb993bb9dd3e8dbfa1876a4e731bca10ee0507 Reviewed-on: https://code.wireshark.org/review/5754 Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-10-20Get rid of calls to ctype.h functions.Guy Harris1-2/+1
They don't handle values outside the range -1 to 127, and their behavior is locale-dependent. Use g_ascii_isXXX() and g_ascii_toXXX() instead of isXXX() and toXXX(). If you're checking for printable ASCII, don't use isascii() and don't use iscntrl(), use g_ascii_isprint(). If you're checking for graphical ASCII, i.e. printable ASCII except for a space, use g_ascii_isgraph(). Use ws_xton() to convert a hex digit character to the corresponding numeric value. Change-Id: Id3039bc586fbf66d8736c2df248c790c0d7a2330 Reviewed-on: https://code.wireshark.org/review/4851 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-06Convert (what appear to be) "4 space tabs"; Adjust editor-modelines; Do some ↵Bill Meier1-1272/+1280
minor reformatting. Change-Id: Ie078c826ed38a0d682f61fb3e95450b47a9d2c31 Reviewed-on: https://code.wireshark.org/review/4499 Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-06-19Revert "Fixup: tvb_* -> tvb_captured"Michael Mann1-1/+1
https://www.wireshark.org/lists/wireshark-dev/201406/msg00131.html This reverts commit 246fe2ca4c67d8c98caa84e2f57694f6322e2f96. Change-Id: Ib24bae0198c13a84bd7f731bf4af921212109a8f Reviewed-on: https://code.wireshark.org/review/2430 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-18Fixup: tvb_* -> tvb_capturedDario Lombardo1-1/+1
Change-Id: I9209c1271967405c34c1b6fa43e1726a4d3a5a3f Reviewed-on: https://code.wireshark.org/review/2377 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-06-18Fixup: tvb_get_string(z) -> tvb_get_string(z)_encDario Lombardo1-24/+24
Change-Id: I63a3704effe3fcab01a193dc39b6a22e9f1cf3fe Reviewed-on: https://code.wireshark.org/review/2376 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-06-03packet-bencode: proto_tree_add_text -> somthing filterableMichael Mann1-1/+1
Also, cleanup dissector being called only with tree and a few tvb_new_subset calls. Change-Id: I1dab1b42ef1a27fc85b05d126f51f1582d7e5c58 Reviewed-on: https://code.wireshark.org/review/1932 Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-05-21Add cast to satisfy buildbotEvan Huus1-1/+1
Change-Id: Ib0f66fb6e4a577da7381a75789b08a0d0371ddd2 Reviewed-on: https://code.wireshark.org/review/1709 Reviewed-by: Evan Huus <eapache@gmail.com>
2014-05-20Don't panic in case of mediaproxy-ng/rtpengine extensionPeter Lemenkov1-1/+14
Change-Id: Id0441ec3e68b594051930623c17f45e806b79616 Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/1633 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com> Tested-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-03-04Remove all $Id$ from top of fileAlexis La Goutte1-2/+0
(Using sed : sed -i '/^ \* \$Id\$/,+1 d') Fix manually some typo (in export_object_dicom.c and crc16-plain.c) Change-Id: I4c1ae68d1c4afeace8cb195b53c715cf9e1227a8 Reviewed-on: https://code.wireshark.org/review/497 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-02-20Initial basic RTPproxy-ng dissectorPeter Lemenkov1-1/+31
Initial basic RTPproxy-ng dissector which uses bencode packing. Change-Id: I5b3e9f6e745977b3df12263c3a9f4ee9a3e1445e Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/268 Reviewed-by: Evan Huus <eapache@gmail.com> Tested-by: Evan Huus <eapache@gmail.com>
2014-02-11Add expert info about skipped notify IP addressPeter Lemenkov1-2/+5
- Add expert info about skipped notify IP address - Add a couple of comments (cosmetic) Change-Id: I6caa904cf16b304724c5da1933531cf865daf619 Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/171 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-02-10Use IP types instead of plain strings where possiblePeter Lemenkov1-45/+84
Change-Id: Ia4a78e1ef3a7c45761cc271ecc17e7868b8456d9 Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> Reviewed-on: https://code.wireshark.org/review/157 Reviewed-by: Evan Huus <eapache@gmail.com> Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
2013-12-26Add numeric types instead of string where possible in the RTPproxy ↵Michael Mann1-24/+32
dissector. Bug 9561 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9561) From Peter Lemenkov svn path=/trunk/; revision=54467
2013-12-21Add missing includesJakub Zawadzki1-0/+1
svn path=/trunk/; revision=54332
2013-12-21New functions: str_to_ip6(), str_to_ip()Jakub Zawadzki1-12/+2
This way we can avoid including lot of system header files in some dissectors and it might fix bug #9581 svn path=/trunk/; revision=54330
2013-12-16From Peter Lemenkov:Bill Meier1-4/+4
"This patch removes misleading dereferencing operator from the array's name. E.g. consider the following declaration: guint32 ipaddr[4]; ipaddr points to the address of an array of guint32's, while &ipaddr points to the first' guint32 object. E.g. &ipaddr == &ipaddr[0]. The value is the same, but has different type which is necessary sometimes. However inet_pton treats latest argument as void*, and this information is left anyway. So no need to bother with types and let's just pass pointer to the array." https://bugs.wireshark.org/bugzilla/attachment.cgi?id=12304 From me: Remove dereferencing operator from 'ipaddr' in two calls to wmem_memdup(). svn path=/trunk/; revision=54156
2013-12-15From Peter Lemenkov via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9558Alexis La Goutte1-1/+5
Mark generated fields as generated in RTPproxy dissector This patch is cosmetic. It just marks generated fields as generated (to avoid confusion) Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> svn path=/trunk/; revision=54123
2013-12-13From Peter Lemenkov via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9556Alexis La Goutte1-8/+3
Cosmetic change in a LF field representation in the RTPproxy dissector Don't display any value for LF field Signed-off-by: Peter Lemenkov <lemenkov@gmail.com> svn path=/trunk/; revision=54045
2013-12-13Fix [-Wmissing-prototypes]Anders Broman1-1/+0
svn path=/trunk/; revision=54025
2013-12-12- Make local functions static.Anders Broman1-4/+7
- Forward declaration of register functions. svn path=/trunk/; revision=53958
2013-12-03When including <epan/prefs.h> don't force inclusion of <epan/uat.h>Jakub Zawadzki1-0/+1
svn path=/trunk/; revision=53769
2013-12-03Clean up indentation.Guy Harris1-1/+1
svn path=/trunk/; revision=53742
2013-12-02Fix Coverity CID 1134045: Printf format string issue. (As documented in the ↵Chris Maynard1-1/+1
printf man page for the ' option, "Note that many versions of gcc(1) cannot parse this option and will issue a warning." (r47940 reverted a similar change, so this keeps things consistent.) svn path=/trunk/; revision=53705
2013-11-30From Peter Lemenkov via ↵Pascal Quantin1-3/+17
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9490 : Couple packets in RTPproxy dissector not only with CookieID but also with Call-IDs svn path=/trunk/; revision=53673
2013-11-29From Peter Lemenkov via ↵Pascal Quantin1-2/+5
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9487 : Use RTP payload descriptions from RTP dissector in RTPproxy codec param value svn path=/trunk/; revision=53658
2013-11-28RTPproxy dissector: Add expert info about timeouts. Bug 9484 ↵Michael Mann1-0/+31
(https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9484) From Peter Lemenkov svn path=/trunk/; revision=53622