Commit Graph

14675 Commits

Author SHA1 Message Date
Gerald Combs a6bbdaa849 Fix some dead code and zero division issues found by Clang scan-build.
In convert_string_case() use g_utf8_strup() instead of converting each
character by hand. Hopefully this won't cause any unexpected changes in
behavior.

svn path=/trunk/; revision=36006
2011-02-18 22:43:48 +00:00
Gerald Combs aaeca955a5 Try to fix more Clang scan-build warnings.
svn path=/trunk/; revision=36005
2011-02-18 21:44:06 +00:00
Stephen Fisher e1afac1b89 From Roberto Morro via bug #5701: Change the PCEP dissector's port
from 1010 to the IANA assigned value of 4189.  From me: Add RFC 5440
to the list of references.


svn path=/trunk/; revision=36004
2011-02-18 20:48:49 +00:00
Gerald Combs 3e13ddbadc Fix a few errors found by Clang scan-build.
svn path=/trunk/; revision=36002
2011-02-18 19:46:05 +00:00
Anders Broman 0e6aa74d54 From Pascal Quantin:
NAS EPS] Fix display of Authentication (Failure) Parameter IEs

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5704

svn path=/trunk/; revision=36001
2011-02-18 18:40:29 +00:00
Jeff Morriss 34dc101fcb #if out some (currently) unused functions.
svn path=/trunk/; revision=36000
2011-02-18 17:38:46 +00:00
Jaap Keuter 133cbe7581 From Ivan Lawrow:
The Final CAP Slot field "wpan.cap" in the Superframe Specification for a
beacon is always displayed as zero.

svn path=/trunk/; revision=35999
2011-02-18 08:02:53 +00:00
Anders Broman 29ddaec6a6 Add more MSG dissection.
svn path=/trunk/; revision=35998
2011-02-18 07:00:03 +00:00
Guy Harris eef8820ab6 Nope, the __declspec(noreturn) didn't suffice - either abort() isn't
declared as a noreturn function or declaring except_throw() as a
noreturn function isn't good enough.

svn path=/trunk/; revision=35997
2011-02-18 02:49:46 +00:00
Guy Harris ed86bc8023 Just for fun, see whether using __declspec(noreturn) on the exception
routines is sufficient to convince the Visual Studio code analyzer that
REPORT_DISSECTOR_BUG() never returns.  (That would probably require that
abort() be tagged with __declspec(noreturn); let's hope Microsoft did
the right thing there.)

svn path=/trunk/; revision=35996
2011-02-18 01:28:18 +00:00
Gerald Combs c223ebe718 Fix more Visual C++ analysis errors.
svn path=/trunk/; revision=35995
2011-02-18 01:18:44 +00:00
Gerald Combs d60527b94f Put WS_MSVC_NORETURN back.
svn path=/trunk/; revision=35993
2011-02-18 00:08:03 +00:00
Guy Harris e654a29b1c config.h is now included, and it defines _WIN32_WINNT.
svn path=/trunk/; revision=35992
2011-02-17 23:36:39 +00:00
Gerald Combs 301a4ac9de Fix compilation on Windows.
svn path=/trunk/; revision=35991
2011-02-17 23:35:46 +00:00
Gerald Combs 33819c43c8 Add a hint for Visual C++ to DISSECTOR_ASSERT. Hopefully this will
reduce some of the /analyze false positives.

svn path=/trunk/; revision=35990
2011-02-17 23:21:07 +00:00
Guy Harris b4f663a29b On Windows, try putting __declspec(noreturn) in front of declarations of
routines that don't return.  (This requires that some files include
config.h to get WS_MSVC_NORETURN declared properly.)

svn path=/trunk/; revision=35989
2011-02-17 23:11:49 +00:00
Gerald Combs dae5200002 Fix some Visual C++ analysis warnings.
svn path=/trunk/; revision=35988
2011-02-17 23:00:34 +00:00
Gerald Combs da198b3083 Fix gcc compilation errors.
svn path=/trunk/; revision=35986
2011-02-17 20:31:11 +00:00
Gerald Combs 1b0516a27e Fix various Visual C++ analysis warnings.
svn path=/trunk/; revision=35985
2011-02-17 19:43:16 +00:00
Gerald Combs 51e5e75373 Don't allocate a bunch of memory on the stack for strings that will be
fed to col_append_fstr; columns have a maximum length of 240 characters
(ITEM_LABEL_LENGTH). Make sure our column text is properly formatted.

svn path=/trunk/; revision=35984
2011-02-17 19:28:30 +00:00
Stephen Fisher 56d74752d1 Fix dead initialization error found by clang:
"Value stored to 's' during its initialization is never read"

(it's assigned by a later g_hash_table_lookup call)


svn path=/trunk/; revision=35983
2011-02-17 18:53:35 +00:00
Guy Harris b32b4d08bd It wasn't complaining about that null pointer reference.
svn path=/trunk/; revision=35981
2011-02-17 18:43:38 +00:00
Stig Bjørlykke 17485dbd86 Fixed no_sua_assoc init.
svn path=/trunk/; revision=35980
2011-02-17 11:00:54 +00:00
Anders Broman 31f1c264fb - Introduce association tracking(might not work well with multihoming).
- prefix hf variables with sua ( hf_sua...)

svn path=/trunk/; revision=35979
2011-02-17 10:13:05 +00:00
Guy Harris 0b229a4202 Is there an SAL tag that says "this function never returns"?
svn path=/trunk/; revision=35978
2011-02-17 09:13:38 +00:00
Guy Harris d36684f364 Can we reassure Microsoft's static analyzer that 0 <= mask <= 48?
svn path=/trunk/; revision=35977
2011-02-17 09:08:11 +00:00
Guy Harris 71b71d920e Oops, wrong pointer comparison.
svn path=/trunk/; revision=35976
2011-02-17 08:39:41 +00:00
Guy Harris 8eb8623b15 OK, let's try a couple more explicit checks against NULL, to see whether
that de-confuses Microsoft's code analyzer.

svn path=/trunk/; revision=35975
2011-02-17 08:15:05 +00:00
Jaap Keuter 3884e987b6 From Alexis La Goutte :
A patch to add Vendor ID of VIA Client & Remote AP (from Aruba Networks)
Also add ett_ value for rohc, ike & ike2.

svn path=/trunk/; revision=35974
2011-02-17 08:03:48 +00:00
Gerald Combs 7b254f46fb Fix some Visual C++ static analyzer complaints.
svn path=/trunk/; revision=35971
2011-02-17 01:11:05 +00:00
Gerald Combs 69901e8eba Fix Visual C++ code analysis errors.
svn path=/trunk/; revision=35970
2011-02-16 22:57:36 +00:00
Stephen Fisher 64666812e9 Change protocol column from "IEEE 802.11" to "802.11" so it fits in
the default column width.


svn path=/trunk/; revision=35969
2011-02-16 21:56:28 +00:00
Guy Harris ae86d3b411 Put the "MCS known information" field into the protocol tree; yes, it's
somewhat redundant, as items aren't displayed if they're not known, but
it can make it a little clearer to people who aren't familiar with the
gory details of radiotap (which people just looking at network traffic
might not be).

Clean up some capitalization of field names.

svn path=/trunk/; revision=35968
2011-02-16 21:08:40 +00:00
Stig Bjørlykke d3051fa55d Generate correct type (FT_OID) for "x420.compression_algorithm_id".
I suspect this should have been fixed in asn2wrs...

svn path=/trunk/; revision=35965
2011-02-16 11:04:28 +00:00
Jeff Morriss edb9220dee Make swap_mac_addr() take a pointer to a TVB and an offset rather than
(generally) a pointer into the TVB.

svn path=/trunk/; revision=35964
2011-02-16 03:36:49 +00:00
Jeff Morriss 45f7c05411 Use tvb_ether_to_str()
svn path=/trunk/; revision=35963
2011-02-16 03:30:59 +00:00
Jeff Morriss feeafce765 Use tvb_ether_to_str().
There's no need to pass the result of tvb_get_ptr() as the 'value' in
proto_tree_add_*(): just use proto_tree_add_item().

svn path=/trunk/; revision=35962
2011-02-16 03:26:57 +00:00
Jeff Morriss 66b6391c6b Use tvb_ip_to_str() when it can eliminate a tvb_get_ptr() call.
svn path=/trunk/; revision=35961
2011-02-16 03:08:45 +00:00
Jeff Morriss fb99707fa5 Use tvb_ether_to_str() when it can eliminate a tvb_get_ptr() call.
svn path=/trunk/; revision=35960
2011-02-16 03:05:13 +00:00
Jeff Morriss deabd5ce3a Use tvb_ether_to_str()
svn path=/trunk/; revision=35959
2011-02-16 03:01:19 +00:00
Jeff Morriss 76edd1b8f5 Rename the _to_str() functions in this dissector to tvb_*_to_str() and make
the functions take a pointer to a TVB and an offset rather than (generally)
a pointer into a TVB.

Use NULL as the value_ptr in proto_tree_add_bytes_format() since the bytes are
coming straight from the TVB anyway.

Remove unnecessary include file.

svn path=/trunk/; revision=35958
2011-02-16 02:55:58 +00:00
Jörg Mayer 77047f4ea4 Previously 1 byte TCP payload to port 2000 got interpreted as malformed Skinny
svn path=/trunk/; revision=35950
2011-02-15 12:06:39 +00:00
Jaap Keuter 1be49d98a5 From Matthew Parris:
Display "Day of Year" for January 1 as 1, not 0.

svn path=/trunk/; revision=35949
2011-02-15 07:14:22 +00:00
Jaap Keuter bc1832599b From Ania:
Patch enables decoding CM 7.1(3b) messages and CM5 CallInfoMessage (0x14A).

svn path=/trunk/; revision=35948
2011-02-14 22:52:14 +00:00
Jaap Keuter fdca1ea223 Make sure RTP conversations are created.
svn path=/trunk/; revision=35947
2011-02-14 20:51:40 +00:00
Stig Bjørlykke 0ac8e7cc8d Put error messages and expert info for illegal UTCTime elements as a
subtree on the UTCTime element.

svn path=/trunk/; revision=35945
2011-02-14 10:18:03 +00:00
Jaap Keuter 3c54ea00a9 From Fulko Hew:
The 'upper bound field is not being displayed in Register and Unregister PDU's.

svn path=/trunk/; revision=35943
2011-02-13 21:19:26 +00:00
Gerald Combs 5a7ac9140e [Automatic manuf, services and enterprise-numbers update for 2011-02-13]
svn path=/trunk/; revision=35940
2011-02-13 16:03:49 +00:00
Anders Broman f9b379bab5 Advance offsets in the "default" branch to avoid infinite loops.
** (tshark.exe:4392): WARNING **: Dissector bug, protocol GSM BSSMAP, in packet
194520: More than 1000000 items in the tree -- possible infinite loop
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5688

svn path=/trunk/; revision=35939
2011-02-13 15:43:17 +00:00
Anders Broman fcec56cd31 Register BICC by name.
svn path=/trunk/; revision=35938
2011-02-13 15:01:34 +00:00
Anders Broman d8a87d589b Update standard references.
svn path=/trunk/; revision=35937
2011-02-13 13:56:30 +00:00
Guy Harris adfedf3600 Use the p2p_dir names for the direction values, and also list
P2P_DIR_UNKNOWN as "Unspecified" (to distinguish it from "Unknown" as in
"I don't know what that value means").

svn path=/trunk/; revision=35936
2011-02-12 20:59:43 +00:00
Anders Broman 35bde0d589 Update dissection of
3.2.2.103 Speech Codec List
3.2.2.104 Speech Codec
to 3GPP TS 48.008 version 9.4.0 Release 9.

svn path=/trunk/; revision=35935
2011-02-12 20:17:47 +00:00
Guy Harris 38c6d248e8 When generating the Info column, don't assume the direction is either
P2P_DIR_SENT or P2P_DIR_RECV - it might be unknown.

Use some #defines for SDP data element IDs, and rename the routine that
gets data elements tor reflect what it does.

svn path=/trunk/; revision=35934
2011-02-12 20:08:47 +00:00
Guy Harris a595f69ce4 The lack of _WITH_PHDR in WTAP_ENCAP_BLUETOOTH_H4 means there's no
pseudo-header, and hence there's no direction indication. Don't set
pinfo->p2p_dir for it.  Use WTAP_ENCAP_BLUETOOTH_H4_WITH_PHDR, not
WTAP_ENCAP_BLUETOOTH_H4, for capture files where we have the direction.

Don't assume pinfo->p2p_dir is either P2P_DIR_SENT or P2P_DIR_RECV when
setting the info column in various Bluetooth dissectors; it might be
unknown.

In the HCI H4 dissector, put the direction into the info column
regardless of whether we have a type match or not; the dissectors for
HCI packet types appear to assume it's been set (as they put a blank at
the beginning of the stuff they append to the direction).

svn path=/trunk/; revision=35933
2011-02-12 19:59:41 +00:00
Jeff Morriss ba3f31d873 Register an ett_ variable.
svn path=/trunk/; revision=35928
2011-02-12 03:52:05 +00:00
Jeff Morriss 21cf6ff3ce Remove an unused ett_ variable.
svn path=/trunk/; revision=35927
2011-02-12 03:51:12 +00:00
Jeff Morriss e92dd56b71 Register a bunch of ett_ variables.
Use gint (instead of int) for ett_ variables (for consistency only).

svn path=/trunk/; revision=35922
2011-02-11 21:27:46 +00:00
Anders Broman 5fbe65d670 Update 8.12 Indication IE to 3GPP TS 29.274 version 9.4.0 Release 9
svn path=/trunk/; revision=35921
2011-02-11 21:21:45 +00:00
Jeff Morriss 947ca59731 Register a couple of ett_ variables.
Move the declaration of all the ett_ variables after the hf_ variables
(instead of in between some of them).

svn path=/trunk/; revision=35920
2011-02-11 21:15:41 +00:00
Jeff Morriss fc45d04c22 Register a couple ett_ variables. Declare all the ett_ variables together.
svn path=/trunk/; revision=35919
2011-02-11 21:13:38 +00:00
Guy Harris ab15a35f65 Don't assume we're on port 631.
svn path=/trunk/; revision=35916
2011-02-11 09:28:05 +00:00
Jaap Keuter ff7eeffdb9 From Joe McEachern:
Add support the 6RD DHCP option defined in RFC 5969.

svn path=/trunk/; revision=35915
2011-02-11 08:00:21 +00:00
Guy Harris 0d9152e782 Register for the media type "application/ipp", so *any* HTTP request or
response with that content type will be dissected as IPP.

svn path=/trunk/; revision=35914
2011-02-11 05:54:34 +00:00
Jeff Morriss be81bc949a Rename arphrdaddr_to_str() to tvb_arphrdaddr_to_str() and make it take a pointer a TVB
and an offset instead of (generally) a pointer into a TVB.

svn path=/trunk/; revision=35913
2011-02-11 03:33:11 +00:00
Jeff Morriss 0f59bc7c45 Rename vines_to_str() to tvb_vines_to_str() and make it take a pointer a TVB
and an offset instead of (generally) a pointer into a TVB.

Move most of the contents of packet-vines.h into packet-vines.c: the moved
content is only needed in that file.

svn path=/trunk/; revision=35912
2011-02-11 03:13:24 +00:00
Jeff Morriss d8659693ef Check for places where tvb_bytes_to_str() or tvb_get_bytes_to_str_punct()
should be used (instead of the non-tvb functions with a call to tvb_get_ptr()).

Use those functions in a bunch of places.

svn path=/trunk/; revision=35911
2011-02-11 02:43:07 +00:00
Martin Mathieson f30d00e00a Show subheaders summary in subheader root item.
svn path=/trunk/; revision=35908
2011-02-11 00:29:40 +00:00
Jeff Morriss b1d4ef8851 Use tvb_ip_to_str() and tvb_ether_to_str().
svn path=/trunk/; revision=35905
2011-02-10 22:14:05 +00:00
Jeff Morriss b58b5b5c67 Pass NULL as the value_ptr to proto_tree_add_bytes_format().
Simplify the code a bit since tvb_ensure_bytes_exist() was already throwing
an exception if all the bytes weren't there.

Use tvb_ether_to_str().

svn path=/trunk/; revision=35904
2011-02-10 22:07:29 +00:00
Anders Broman 61515ab830 From Alexis La Goutte:
Cleanup 802.11 Dissector :Enhance SSID, Supported Rates, DS, FH, CFP.. Information Element sub dissector 

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5660

svn path=/trunk/; revision=35903
2011-02-10 21:45:36 +00:00
Chris Maynard 8d47cebd00 Declare ett's as gint, not guint.
svn path=/trunk/; revision=35902
2011-02-10 20:55:26 +00:00
Jeff Morriss 50e1634f4c Modify proto_tree_add_bytes_format() and proto_tree_add_bytes_format_value()
so that if the start_ptr is NULL the bytes are extracted from the given TVB
using the given offset and length.

Replace a bunch of:

proto_tree_add_bytes_format*(tree, hf, tvb, offset, length, tvb_get_ptr(tvb, offset, length), [...])

with:

proto_tree_add_bytes_format*(tree, hf, tvb, offset, length, NULL, [...])

svn path=/trunk/; revision=35896
2011-02-10 16:31:00 +00:00
Michael Tüxen 7154ed5689 Obtained from Thomas Dreibholz: Update SCTP PPIDs.
svn path=/trunk/; revision=35895
2011-02-10 12:54:20 +00:00
Stig Bjørlykke 1ba57f4c04 Added a dissector table for AttributeId localForm.
Use correct object identifier in ModificationList.

svn path=/trunk/; revision=35894
2011-02-10 10:11:38 +00:00
Anders Broman 60297df554 - Add message name to info col in case of SERVICE REQUEST.
- Get rid of check_col
- proto_tree_add_item -> ENC_BIG_ENDIAN

svn path=/trunk/; revision=35893
2011-02-10 08:28:18 +00:00
Jeff Morriss a67d2b9bf7 Use tvb_bytes_to_str_punct() instead of a homegrown version.
svn path=/trunk/; revision=35892
2011-02-09 22:43:06 +00:00
Jeff Morriss 685c29d386 Use tvb_bytes_to_str_punct() instead of bytestring_to_str(tvb_get_ptr(), ...)
svn path=/trunk/; revision=35891
2011-02-09 22:37:26 +00:00
Jeff Morriss 1d396a69e0 Register ett_gtp_bcm.
Replace some tabs with spaces.


svn path=/trunk/; revision=35890
2011-02-09 18:45:32 +00:00
Jaap Keuter 4ac0559b63 From Grzegorz Szczytowski:
Update of packet-e212.c dissector according to local national regulatory 
MNC assignment document.
www.uke.gov.pl/uke/redir.jsp?place=galleryStats&id=24439

svn path=/trunk/; revision=35889
2011-02-09 08:46:21 +00:00
Jeff Morriss 13d8e41e0f A couple of dissectors have/need an NTP-to-nstime routine, so put it in
packet-ntp and export it to the other dissectors.

Move some macros (now) only used in packet-ntp.c into that file.

svn path=/trunk/; revision=35887
2011-02-09 03:24:12 +00:00
Jeff Morriss 92cd49b4c2 Rename ntp_fmt_ts() to tvb_ntp_fmt_ts() and make it take a pointer to a TVB and
an offset instead of (generally) a pointer into the TVB. Then use the standard
accessor functions to get data out of the TVB.


svn path=/trunk/; revision=35886
2011-02-09 03:00:51 +00:00
Jeff Morriss 5d3a4a06bc Rewrite this dissector's NTP-to-nstime routine to take a TVB and an offset
instead of a pointer into the TVB.  Then use the standard accessor functions
to get data out of the TVB.


svn path=/trunk/; revision=35885
2011-02-09 02:54:12 +00:00
Jeff Morriss a527fa4b49 Add NTP times using proto_tree_add_item().
Replace a couple not-very-descriptive blurbs with NULL.

svn path=/trunk/; revision=35883
2011-02-09 02:27:41 +00:00
Anders Broman 87aaac83ce From Holger Freyther:
Fix the GSMTAP to TETRA table

GSMTAP has the BSCH at 1... this means the table needs to have 9 entries, the
first being 0. 


--------------------------------------------------------------------------------

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5659

svn path=/trunk/; revision=35882
2011-02-08 22:01:33 +00:00
Anders Broman 771445d49a from Václav Horčák:
Bug 5663 - [PATCH] Fix for MEGACO dissector context tracking.
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5663

svn path=/trunk/; revision=35880
2011-02-08 12:33:34 +00:00
Anders Broman 211e3a1eef - Use ENC_BIG_ENDIAN.
- GSM_A_PDU_TYPE_BSSMAP.

svn path=/trunk/; revision=35879
2011-02-08 12:32:34 +00:00
Guy Harris fd941f3906 Don't look at any of the fields that come from the Auxiliary Security
Header unless there *is* an Auxiliary Security Header.

svn path=/trunk/; revision=35878
2011-02-08 06:55:53 +00:00
Jeff Morriss 045037dc71 Add NTP times using proto_tree_add_item().
svn path=/trunk/; revision=35876
2011-02-08 03:16:35 +00:00
Jeff Morriss b87a80f196 Add support for 4-byte NTP times (only the seconds) in proto_tree_add_item().
Use it in packet-diameter.c .  Eliminate an unnecessary local variable.

svn path=/trunk/; revision=35875
2011-02-08 02:38:51 +00:00
Guy Harris 9d6671bbab The checkAPI script doesn't understand arrays of value_string tables,
and that flavor of two-dimensional array requires you to declare a
maximum size for the value_string tables in the array.  Don't use an
array of value_string tables.

svn path=/trunk/; revision=35871
2011-02-08 00:57:21 +00:00
Stephen Fisher 68b0cd7030 Fix bug #5657: Update my mail address
svn path=/trunk/; revision=35868
2011-02-07 23:14:54 +00:00
Jaap Keuter d265580072 From Masashi Honma:
Currently the Wireshark does not support Primary Device Type dissection. 
I made a patch for the dissection based on "Wi-Fi Simple Configuration 
Specification DRAFT Version 2.0.0.51".

svn path=/trunk/; revision=35867
2011-02-07 22:47:43 +00:00
Anders Broman 42145f2e7c from Holger Freyther:
gsmtap: Update header file, add tetra support

0001 Minor cleanup - made it look crocked in visual studio, changed bu hand.
0002 Update the definitions from the 'upstream' source 
0003 First bits of tetra decoding included in GSMTAP 
0004 Pass the tetra PDUs to the TETRA decoder 

Changed def. of gsmtap_to_tetra to make it compile.
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5659

svn path=/trunk/; revision=35864
2011-02-07 21:38:55 +00:00
Anders Broman 1d7c05c898 From Alexis La Goutte:
Cleanup 802.11 Dissector : Enhance add_tagged_field (and sub tagged field dissector)

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5660

svn path=/trunk/; revision=35863
2011-02-07 20:50:13 +00:00
Bill Meier 121c65c613 Remove unneeded #includes (stdio.h,stdlib.h);
Whitespace cleanup: trailing, indentation, "4-space tabs"

svn path=/trunk/; revision=35850
2011-02-07 18:49:29 +00:00
Guy Harris bd06390b7f Update URL (the document now includes all updates through Technical
Corrigendum 1; presumably that's the "c1").

svn path=/trunk/; revision=35846
2011-02-07 18:35:22 +00:00
Gerald Combs 8ae09e055c Mark a parameter unused.
svn path=/trunk/; revision=35845
2011-02-07 18:05:26 +00:00
Anders Broman 47cc39a0bb Use value_string_ext and ENC_BIG_ENDIAN.
svn path=/trunk/; revision=35844
2011-02-07 17:45:49 +00:00
Anders Broman 553cf70a68 Dissect V1 version , found in trace from:
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5637

svn path=/trunk/; revision=35843
2011-02-07 17:44:34 +00:00