Commit Graph

59 Commits

Author SHA1 Message Date
Anders Broman 3eb06be97d From beroset:
remove C++ incompatibilities 
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8416

svn path=/trunk/; revision=48425
2013-03-19 19:28:57 +00:00
Jeff Morriss 21b1b0c5da Add heuristic MTP3 standard detection to M3UA (not for the draft M3UA versions).
The SCCP heuristics actually don't work all that well here but checking the PCs
(in M3UA) seems to do a decent job at least of differentiating ANSI from ITU.

svn path=/trunk/; revision=47407
2013-02-01 02:42:01 +00:00
Evan Huus 471dde4a21 Use pinfo-scoped memory for mtp3 addresses.
Fixes https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8247

svn path=/trunk/; revision=47266
2013-01-25 00:28:48 +00:00
Jeff Morriss 0266cceef3 Make all enum_val_t's const.
svn path=/trunk/; revision=46292
2012-11-29 20:15:37 +00:00
Jeff Morriss e6d6d7272a Create and start using macros for MTP3 network indicators.
pinfo has a match_uint field: use it instead of passing the SI of the message
to subdissectors in private_data.

svn path=/trunk/; revision=45788
2012-10-25 20:25:06 +00:00
Jeff Morriss 95094bf420 Fix cut-n-pasteo.
svn path=/trunk/; revision=45786
2012-10-25 16:03:38 +00:00
Jeff Morriss d407ce0d36 Create and start using macros for MTP3 network indicators.
Export the network indicator value_string and use it in M3UA.

svn path=/trunk/; revision=45784
2012-10-25 15:34:57 +00:00
Jeff Morriss 2552c750e5 We always HAVE_CONFIG_H so don't bother checking whether we have it or not.
svn path=/trunk/; revision=45017
2012-09-20 02:03:38 +00:00
Jakub Zawadzki 5ad3e5331e MT: move global frame_end_routines to packet_info.
svn path=/trunk/; revision=44748
2012-09-03 12:00:40 +00:00
Bill Meier 638d74d43f Use val_to_str_const() where appropriate;
Also (for a few files):
- create/use some extended value strings;
- remove unneeded #include files;
- remove unneeded variable initialization;
- re-order fcns slightly so prefs_reg_handoff...() at end, etc

svn path=/trunk/; revision=44438
2012-08-10 22:55:02 +00:00
Jakub Zawadzki b18e880040 Update FSF address - part II.
svn path=/trunk/; revision=43538
2012-06-28 23:18:38 +00:00
Jeff Morriss ef218f0735 Export the mtp3_heuristic_standard preference and mtp3_standard_vals[].
Set mtp3_standard back to the preference value after each packet (in addition
to in the frame-end function) in case there are multiple packets of different
standards in the same frame.

svn path=/trunk/; revision=40910
2012-02-07 02:19:11 +00:00
Jeff Morriss 183f0e934c Create a list of MTP Service Indicator macros and use them.
svn path=/trunk/; revision=40828
2012-02-03 18:26:37 +00:00
Jeff Morriss a3fc8f5f45 Register a frame-end routine to reset mtp3_standard back to the preference
value even if an exception was thrown.

svn path=/trunk/; revision=40827
2012-02-03 18:16:21 +00:00
Jeff Morriss 73ce69dcd4 Improve heuristic standard detection:
- Fix various bugs.
 - Add some optional debug.
 - Enable checking of the Calling address.
 - Check that the Called/Calling address has at least a minimum number of
   octets.
 - Handle XUDTS.
 - Reject messages whose mandatory variable pointers are 0 (meaning not
   present).
 - Reject Class-2 messages whose Class-spare bits are non-zero.
 - For (Class-2) messages that have no variable parameters but an optional
   pointer, only accept messages whose optional pointer is 0 (no optional
   parameters) or 1 (optional parameter immediately follows the pointer).
 - (For some of those Class-2 messages) if there are no optional parameters,
   reject messages if we didn't reach the end of the message.

svn path=/trunk/; revision=40819
2012-02-03 04:09:10 +00:00
Anders Broman d29d5bf966 Remove an unused parameter.
svn path=/trunk/; revision=40778
2012-01-30 20:03:29 +00:00
Anders Broman ed5c6cfd71 Try to determine MTP3 Standard heuristically, original code
from Jeff Morris refactored a bit by me.

svn path=/trunk/; revision=40776
2012-01-30 19:47:35 +00:00
Anders Broman 14fbabcb26 Get rid of check_col() and use ENC.
svn path=/trunk/; revision=39153
2011-09-26 17:50:54 +00:00
Jeff Morriss 5262c3f4b0 Update my email address (the old one still works but I don't use it for Wireshark related stuff).
svn path=/trunk/; revision=38841
2011-09-01 14:30:16 +00:00
Alexis La Goutte 7f47f89b1e Fix Dead Store (Dead assignement/Dead increment) Warning found by Clang
svn path=/trunk/; revision=36773
2011-04-21 16:01:26 +00:00
Alexis La Goutte 3e4e507ce0 Fix Dead Store (Dead nested assignment) Warning found by Clang
svn path=/trunk/; revision=36757
2011-04-21 13:33:23 +00:00
Guy Harris a8bc4a0d13 Rename the routines that handle dissector tables with unsigned integer
keys to have _uint in their names, to match the routines that handle
dissector tables with string keys.  (Using _port can confuse people into
thinking they're intended solely for use with TCP/UDP/etc. ports when,
in fact, they work better for things such as Ethernet types, where the
binding of particular values to particular protocols are a lot
stronger.)

svn path=/trunk/; revision=35224
2010-12-20 05:35:29 +00:00
Jeff Morriss 3971cb5d13 Copy hf variables by value, not by reference.
svn path=/trunk/; revision=34682
2010-10-28 18:49:40 +00:00
Jeff Morriss 54e10cb509 Use ENC_LITTLE_ENDIAN and ENC_NA.
svn path=/trunk/; revision=34681
2010-10-28 18:37:41 +00:00
Bill Meier 93b94a23ca Define some fcns & vars as static; Some #includes not req'd; packet-mikey.h not req'd.
svn path=/trunk/; revision=34464
2010-10-10 23:28:40 +00:00
Gerasimos Dimitriadis 3915bb8bab Add routine and tables for analyzing International Signalling Point
Codes (ISPCs) according to Q.708. Update the MTP3 dissector to use
this function when the routing label carries ISPCs

svn path=/trunk/; revision=32329
2010-03-30 22:05:47 +00:00
Kovarththanan Rajaratnam 8b515e9340 Switch a bunch of dissectors over to using tvb_new_subset_remaining()
svn path=/trunk/; revision=29446
2009-08-16 12:36:22 +00:00
Kovarththanan Rajaratnam 4b6090e576 Don't guard col_set_str (COL_INFO) with col_check
svn path=/trunk/; revision=29342
2009-08-09 07:01:26 +00:00
Guy Harris db08b1f783 Get rid of assert() call; either the pointer will never be null, in
which case it won't crash, or it will be null, in which case that just
trades one crash for another, and we should fix the crash.

svn path=/trunk/; revision=28898
2009-06-30 23:49:34 +00:00
Stig Bjørlykke fc3f1b5283 From Artem Tamazov (bug 3472):
Save/Restore pinfo->private_data when used.

svn path=/trunk/; revision=28412
2009-05-19 17:16:14 +00:00
Bill Meier 808a4e2c3c Define certain fcns as static (if not used externally).
Also: whiule we're at it: 
 - fix hf[] blurbs as appropriate to use NULL;
 - fix some indentation

svn path=/trunk/; revision=27890
2009-03-29 22:16:26 +00:00
Bill Meier aa30dcd129 Minor proto_reg_handoff cleanup: use find_dissector when appropriate.
svn path=/trunk/; revision=26308
2008-09-30 14:49:44 +00:00
Bill Meier 558c1b5ee6 Fix some of the Errors/warnings detected by checkapi.
svn path=/trunk/; revision=25306
2008-05-15 12:08:20 +00:00
Guy Harris 08ab8d8734 mtp3_addr_to_str_buf() and mtp3_pc_hash() expect to be passed a pointer
to a mtp3_addr_pc_t; declare them as such, and pass the argument as
such.

svn path=/trunk/; revision=21595
2007-04-26 07:57:44 +00:00
Luis Ontanon 8064e3cc64 When there are multiple mtp3 packets on a single sctp packet (m2ua) have each one has its own pcs and tap structure
svn path=/trunk/; revision=21271
2007-03-29 12:25:50 +00:00
Jeff Morriss 4c178e287e Add a preference (defaulted to off) to have the MTP3 dissector show the priority (which is a national option in ITU) of MSUs.
svn path=/trunk/; revision=20490
2007-01-18 22:06:56 +00:00
Jörg Mayer 8b4aeedaf1 jeff morriss:
Patch for http://bugs.wireshark.org/bugzilla/show_bug.cgi?id=1102


svn path=/trunk/; revision=19252
2006-09-18 10:14:12 +00:00
Jörg Mayer 2a5d217358 Jeff Morriss:
Fix for bug 1036

I looked at this today and found that in fact the PC stuff is pretty
hosed up in the SS7 dissectors.  For example, MTP3 *looks* OK here (DPC is
4-5-6):

    Routing label
        DPC (4-5-6) (394500)

but 394500 == 0x60504 == 6-5-4.  Something's not right.

I made a common PC dissector function for all the SS7 dissectors so as to
concentrate all this code in one place (something I've been wanting to do for a
while anyway) and fixed the reported problem as well as the above problem in
the attached patch.

svn path=/trunk/; revision=19231
2006-09-14 10:51:44 +00:00
Ronnie Sahlberg feab79e328 change a whole bunch of ethereal into wireshark
svn path=/trunk/; revision=18196
2006-05-21 04:49:01 +00:00
Anders Broman ba35e5d4d9 Frof Jeff Morriss:
The attached patch adds support for the Japan SS7 variants (TTC/NTT) to 
the MTP3, MTP3MG, SCCP, and SCCPMG dissectors.  It's not as thoroughly 
implemented nor tested as I'd like, but it does a good job of at least 
the basic dissection and I'm out of time for now.

It also fixes bug I found in the SCCP dissector where it would show an 
End of Optional parameter even when the Optional pointer was 0.

svn path=/trunk/; revision=17815
2006-04-05 16:03:36 +00:00
Luis Ontanon 182553b988 From: Peter Johansson
have mtp3_pc_hash() explicitly returning pc.

From me:
 break; execution inside the switch.


svn path=/trunk/; revision=17643
2006-03-16 10:23:09 +00:00
Luis Ontanon 6e4aa06681 Avoid a coverity false positive (CID 38) from being considered.
svn path=/trunk/; revision=17585
2006-03-11 12:12:10 +00:00
Luis Ontanon e50663a09c Add a function that returns an unique guint32 for each dpc.
svn path=/trunk/; revision=17572
2006-03-10 22:05:23 +00:00
Anders Broman fa04b29920 As per Olivier Jacques mail,
"preferences/mtp3 must be changed accordingly (it is explicitly indicated that the "network address format" is ..."
Change the text and som names.

svn path=/trunk/; revision=16827
2005-12-16 20:36:09 +00:00
Anders Broman 1abb6c1031 Use src and dst instead of net_src.
svn path=/trunk/; revision=16796
2005-12-14 20:01:21 +00:00
Ronnie Sahlberg aff31978c1 remove sprintf from mtp3
svn path=/trunk/; revision=15451
2005-08-20 01:24:23 +00:00
Ulf Lamping 0dc9fb3d4a various code cleanup:
-use g_snprintf instead of sprintf and snprintf
-use g_strdup_printf where appropriate
-remove #include "snprintf.h" (as only g_snprintf should be used)
-replace some more alloc/realloc/calloc/free with their glib pendants

svn path=/trunk/; revision=15264
2005-08-08 18:50:39 +00:00
Ulf Lamping fdb5b1af02 just to get things straight: a dissector should *never* do any g_assert() calls!
in a simple approach, I've replaced all g_assert() and g_assert_not_reached() calls by their exception throwing counterparts DISSECTOR_ASSERT() and DISSECTOR_ASSERT_NOT_REACHED()

this will replace application crash by showing a dissector bug, which is the desired behaviour

there were some g_assert calls in the protocol registering functions, which might not be acting as expected now, but to be able to simply search for g_assert in the future I've replaced that calls too

one g_assert remained, the one when someone throws an unknown exception "into" packet_frame.c, but IMHO this one should remain.

svn path=/trunk/; revision=14608
2005-06-10 18:28:22 +00:00
Michael Tüxen 22012f92d0 Add higher SI values.
svn path=/trunk/; revision=13517
2005-02-25 20:33:28 +00:00
Michael Tüxen 03b78c062f Add mtp3.pc as suggested by Luis Ontanon.
Cleanups

svn path=/trunk/; revision=13241
2005-02-02 13:37:04 +00:00