Commit Graph

55333 Commits

Author SHA1 Message Date
Michael Mann 8842e2e893 Eliminate proto_tree_add_text from packet-tds.c
Change-Id: Ib3dc7f8a87e55ef34d4847f4837d645e418607a3
Reviewed-on: https://code.wireshark.org/review/4826
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-19 12:00:52 +00:00
Alexis La Goutte ec5159bf63 PCAPNG (wiretap): Fix Dead Store (Dead assignement/Dead increment) warning found by Clang
Change-Id: I6337fe88bbfd76161abc3b51c70402e7e63a435e
Reviewed-on: https://code.wireshark.org/review/4813
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-10-19 09:26:43 +00:00
Michael Mann 54dfe3b9b6 Eliminate proto_tree_add_text from packet-smpp.c
Change-Id: I6e1e62ff7910be535229d7e1a15557879a5cee1f
Reviewed-on: https://code.wireshark.org/review/4832
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-19 03:18:58 +00:00
Michael Mann 7f5398687a Eliminate proto_tree_add_text from packet-nhrp.c
Change-Id: I51702e9372551a28ea604d21d4bbf0eb4d9588ae
Reviewed-on: https://code.wireshark.org/review/4831
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-19 03:18:35 +00:00
Michael Mann 6720c80bab Eliminate proto_tree_add_text from packet-ismp.c
Change-Id: Ie2a395b808a8879625185a6de458f61d386cff55
Reviewed-on: https://code.wireshark.org/review/4830
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-19 03:13:21 +00:00
Michael Mann e0e03ee7e7 Eliminate proto_tree_add_text from packet-arp.c
Change-Id: Ie9596df97a135b411693eefc39fdbd03316166a0
Reviewed-on: https://code.wireshark.org/review/4828
Petri-Dish: Michael Mann <mmann78@netscape.net>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-19 03:08:04 +00:00
Michael Mann c347eb965b Eliminate proto_tree_add_text from packet-ipx.c
Change-Id: Ie084a33be94d91eec7f5f70ef31fcb0835ad266c
Reviewed-on: https://code.wireshark.org/review/4829
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-19 03:01:54 +00:00
Michael Mann 283f478964 Eliminate proto_tree_add_text from packet-igrp.c
Change-Id: If73e3bb924036b7746d15058e9fca6f551f9538c
Reviewed-on: https://code.wireshark.org/review/4827
Petri-Dish: Michael Mann <mmann78@netscape.net>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-19 01:43:20 +00:00
Stig Bjørlykke 147e7fe510 Lua: Added ProtoField.none
This field can be used for adding filterable subtree entries.

Change-Id: Id395c9a8194dc00e6544170631b48d71ae9dd33e
Reviewed-on: https://code.wireshark.org/review/4573
Reviewed-by: Evan Huus <eapache@gmail.com>
Reviewed-by: Hadriel Kaplan <hadrielk@yahoo.com>
2014-10-18 18:25:40 +00:00
Alexis La Goutte e7b07ae73e IPv6: QuickStart option Nonce is read incorrectly
In Wireshark, the option's TTL field looks ok, but the [TTL diff] field points to the byte after the TTL field, which is part of the nonce field.
The nonce field is being read one byte after where it should be read and so the value being read is incorrect.
Moreover, the option data length says 6 but because of the extra byte being read 7 bytes are being read for this option data and the next option is read one byte later incorrectly so the options after the QuickStart option are being read incorrectly.

Found by boaz
Bug:10575

Change-Id: Icd836b2a5c2f92cef7b6fea61957a85fca5e3352
Reviewed-on: https://code.wireshark.org/review/4815
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-18 17:40:36 +00:00
Alexis La Goutte 51f4962203 MIPv6: Mobility Option Mobile Node Link Layer Identifier Link-layer Identifier field is read beyond the option data
there's a single IPv6 packet with Mobile Node Link Layer Identifier mobility option.
The option's data length is 9 but and since the Reserved field takes 2 bytes, the Link Layer Identifier field should take 7 bytes.
However, the Link Layer Identifier field is read until the end of the packet, which is 519 bytes.

Bug:10578
Change-Id: I518de7f6b75e5b749cb029845fd4846954ca6d0e
Reviewed-on: https://code.wireshark.org/review/4818
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-18 17:16:31 +00:00
Alexis La Goutte 8a10f77ab4 MIPv6: Mobility Option Binding Authorization Data for FMIPv6 Authenticator field is read beyond the option data
There's a single IPv6 packet with Binding Authorization Data for FMIPv6 mobility option.
The option's data length is 14 but and since the SPI takes 4 bytes, the Authenticator field should take 10 bytes.
However, the Authenticator field is read until the end of the packet, which is 178 bytes.

Found by boaz
Bug: 10577
Change-Id: Ia79c5131d8477c1a7c111c47c2a94e990bbeae4d
Reviewed-on: https://code.wireshark.org/review/4817
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-18 17:12:18 +00:00
Alexis La Goutte 31c119fa78 MIPv6: Mobility Option IPv6 Address/Prefix marks too many bytes for the address/prefix field
One of the mobility options is the IPv6 Address/Prefix.
The prefix length of this option is 52.
Note that according to RFC 5568, the prefix length is in bits and not in bytes.
The IPv6 Address/Prefix field of this option marks 52 bytes.

In addition, I'm not sure that the IPv6 Address/Prefix field is a variable size field.
RFC 5568 section 6.4.2 has a diagram of this options that shows this field as if it always takes 128 bits, and the prefix length field just says the length of the prefix (not the length of the field).

Found by boaz

Bug:10576
Change-Id: I2a9a35cb7c537ec3b91c9a089f14fa31f41d8c80
Reviewed-on: https://code.wireshark.org/review/4816
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-18 17:07:52 +00:00
Alexis La Goutte 8d6fd8dd23 GSM(_a_rr): Fix Dead Store (Dead assignement/Dead increment) warning found by Clang
Change-Id: I07fe19af11bff3d001193e4af472c05090728392
Reviewed-on: https://code.wireshark.org/review/4814
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-10-18 16:15:34 +00:00
Mikael Kanstrup 27e4ac85e8 Add support for split wiphy dump to Wireless Toolbar
To populate the Wireless Toolbar menu the NL80211_CMD_GET_WIPHY
command is used. Some network interfaces must use split wiphy dump
feature for this command to function properly. One such example is the
D-Link DWA-160 USB adapter that does not show up when used without.

Make use of split wiphy dump feature whenever kernel supports it
to populate the list of monitor interfaces for the Wireless Toolbar.

Bug: 10564
Change-Id: Idc28e92f91a2488fa48eeb282a0ef1e2bd40a5f0
Reviewed-on: https://code.wireshark.org/review/4611
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>
2014-10-18 14:26:00 +00:00
Hannes Mezger 85e7c15605 Use proto_tree_add_expert_format instead of proto_tree_add_text
Change-Id: Ia017fa9535cbc7570ce6bd442972eedd2143825a
Reviewed-on: https://code.wireshark.org/review/4729
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-18 12:29:50 +00:00
David Ameiss 975b02f879 Converted numerous proto_tree_add_none_format() calls for bitmask/flag items to proto_tree_add_bitmask().
Correctly set the length of LBT-RM and LBT-RU header blocks.
Various other cosmetic cleanups.

Change-Id: If19bbdeb10176b8059fd4cf657719b3b9817bc6a
Reviewed-on: https://code.wireshark.org/review/4776
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-18 12:29:19 +00:00
Joerg Mayer 01cf7feb3e Add URL to a description of the attributes
Add comments about additional attributes

Change-Id: Ic73039ee6fde954e147a44e0f98def76a7e88fb3
Reviewed-on: https://code.wireshark.org/review/4812
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
2014-10-18 06:47:12 +00:00
Joerg Mayer ed676ca3b9 Commit 54b733ce9a broke compilation of
echld by removing TS_PREC_AUTO_USEC. Replace its use by TS_PREC_AUTO.
No idea whether that's correct but it compiles again.
Trying to commit this brought complaints by checkapi, so fixed them as
well.

Maybe the echld code should be removed, it seems to be unmaintained.

Change-Id: Id9a0a6fc129abd1b8c93629c31a89c2d9ea2243f
Reviewed-on: https://code.wireshark.org/review/4811
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
2014-10-18 06:43:58 +00:00
Guy Harris 77acaa1f48 Get rid of unnecessary includes of ctype.h.
Change-Id: I9e2cd7a9fed33fc2f4b0c0da3603690450f6952d
Reviewed-on: https://code.wireshark.org/review/4809
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-18 01:22:31 +00:00
Guy Harris 1de3a5bc49 Check for printable ASCII in an ENBName.
I'm not sure why the check is only for alphabetical characters; if
that's correct, change this to use g_ascii_isalpha, and change
is_printable_ascii to is_ascii_alpha or something such as that.

Don't use ctype.h routines, as they are locale-dependent.

Change-Id: I61d0672350d35ad918e95d7e96ed5dd263102da9
Reviewed-on: https://code.wireshark.org/review/4805
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-18 00:22:55 +00:00
Guy Harris 9f2a87803b Get rid of unnecessary includes of ctype.h.
Change-Id: Ibf9385715b85186f5c7289165acea7233b3fabde
Reviewed-on: https://code.wireshark.org/review/4804
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-18 00:06:19 +00:00
Guy Harris e3477bd136 Get rid of some no-longer-necessary casts.
g_ascii_isXXX() can be handed a char value safely; they won't try to use
it as an index into a table before checking it.

Change-Id: Icf80163fb5f9dccd0b97917e318b1db0bf3e0cf8
Reviewed-on: https://code.wireshark.org/review/4801
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 23:58:23 +00:00
Guy Harris a91799ebfa Don't use ctype.h routines.
That avoids locale dependency and handles possibly-signed chars(which
we weren't always doing before).

Change-Id: I89e50678abb8c3e535081c92ca25bc1bab672c68
Reviewed-on: https://code.wireshark.org/review/4798
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 23:43:09 +00:00
Guy Harris 19b7819694 Get rid of unnecessary includes of ctype.h.
Change-Id: Ibb194cd839d174af9c96f7bb1e2941b3dd6c1ce1
Reviewed-on: https://code.wireshark.org/review/4797
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 23:31:20 +00:00
Guy Harris 033f096ee9 Don't use ctype.h routines.
That avoids locale dependency and handles possibly-signed chars (which
we weren't always doing before).

Change-Id: Ieceb93029252f646397b6488f2df8a57c6d2a23d
Reviewed-on: https://code.wireshark.org/review/4794
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 23:11:18 +00:00
Guy Harris 344c2bbb5e strptime.c needs ctype.h.
Change-Id: Icf4020426d3a5e0a6bd2012a266cf07be9928abf
Reviewed-on: https://code.wireshark.org/review/4793
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 21:59:45 +00:00
Guy Harris 214a78c8e1 Get rid of unnecessary include of ctype.h.
Change-Id: Ib83e707ebbbb420ce269a652ede6b7366d24240e
Reviewed-on: https://code.wireshark.org/review/4792
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 21:28:21 +00:00
Guy Harris e304f6d9f8 Get rid of unnecessary includes of ctype.h.
Change-Id: Ic23203f13fd6627b664e8ed1438d328c46328b9f
Reviewed-on: https://code.wireshark.org/review/4790
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 21:22:58 +00:00
Guy Harris 5fc398c328 Don't use ctype.h routines.
That avoids locale dependency and handles possibly-signed chars (which
we weren't doing before).

Change-Id: I189222eff624ad2d2e960bc0b69f3f22d35f351f
Reviewed-on: https://code.wireshark.org/review/4787
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 21:11:44 +00:00
Guy Harris 36e4e6fa0a Get rid of unused includes of <ctype.h>.
Change-Id: Iab9eaeb0f5765748b2582177396264e4e69bc6d1
Reviewed-on: https://code.wireshark.org/review/4786
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 21:04:59 +00:00
Guy Harris 5bfde7c638 Don't use ctype.h routines.
That avoids locale dependency and handles possibly-signed chars (which
we weren't doing before).

Change-Id: I70f3d993c9a8fbf870901f12b430d733968c3fa8
Reviewed-on: https://code.wireshark.org/review/4781
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 20:37:42 +00:00
Hannes Mezger 35a9b98138 Use proto_tree_add_bitmask for ExpandedNodeId EncodingMask
Instead of adding the items using proto_tree_add_item, use proto_tree_add_bitmask in parseExpandedNodeId(). Also, the redundant 'NodeId ' text is removed from hf_opcua_nodeid_... items for better readability.

Change-Id: Ie68f1d280dd733fd2eede0b2b73ad8d7f28396b3
Reviewed-on: https://code.wireshark.org/review/4730
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-17 16:04:09 +00:00
AndersBroman 17a1a0d5e7 SGsAP Update to V12.6.0 except for IE TMSI based NRI container.
Change-Id: Iafb62a27589de1810d4d3bd1e32f1c89898e9171
Reviewed-on: https://code.wireshark.org/review/4777
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-10-17 14:52:12 +00:00
Hannes Mezger e5bbfa0f15 Add argument 'packet_info *pinfo' to all dissecting functions
Change-Id: Ie02326e365ee3f620fcbe3f2e8e45dc5300d3418
Reviewed-on: https://code.wireshark.org/review/4728
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-10-17 14:51:40 +00:00
AndersBroman 0ceeddee17 Dissect CDMA2000 PDU if GCSNA dissector exists.
Change-Id: I866fb9bbc3e94df63231959d6745f3d45ca84020
Reviewed-on: https://code.wireshark.org/review/4772
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-10-17 12:01:27 +00:00
AndersBroman 9d1afef1df isdigit -> g_ascii_isdigit to make the build work.
Change-Id: I670b7b83976a9db9491e017015d570a4dc8f433d
Reviewed-on: https://code.wireshark.org/review/4771
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-10-17 08:52:10 +00:00
Guy Harris 441698863d Eliminate include of <ctype.h>.
This is not built if we have glibc (as we already have getopt() from
it), and it's not part of glibc, so....

Change-Id: Iae4ff944c78fc55a8cd2eaf523a3696c47b741d7
Reviewed-on: https://code.wireshark.org/review/4769
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 07:02:37 +00:00
Guy Harris 87545f39da Remove unnecessary includes of <ctype.h>.
Change-Id: I8eacec5fa8d57b10d40a3627197461dae89c6cb2
Reviewed-on: https://code.wireshark.org/review/4768
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 06:57:41 +00:00
Guy Harris f90d8dcbbb Use g_ascii_isspace() instead of isascii() && isspace().
This eliminates one more use of <ctype.h> macros; we're using
g_ascii_isXXX() instead of isXXX() elsewhere.

Change-Id: I184caeefab95dda2cf207acf9539eabbd7c32a51
Reviewed-on: https://code.wireshark.org/review/4767
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 06:54:54 +00:00
Guy Harris 63ab36be92 Don't use <ctype.h> macros, and eliminate an include of <ctype.h>.
This avoids locale-dependent tests, and fixes cases where we passed
signed char values to those macros (which is not safe with char being
signed, as it is on most, but not all, platforms).

Change-Id: Iea962cd7e4dfaf33c3c873ba43814cc6ed298d94
Reviewed-on: https://code.wireshark.org/review/4764
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 06:41:58 +00:00
Guy Harris 23b233d741 Remove unnecessary include of <ctype.h>.
Change-Id: I596b252d5fb41e654961483cb530754442f25bc7
Reviewed-on: https://code.wireshark.org/review/4763
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 06:29:36 +00:00
Guy Harris 44d4339eb3 Don't use <ctype.h> macros, and eliminate an include of <ctype.h>.
This avoids locale-dependent tests, and fixes cases where we passed
signed char values to those macros (which is not safe with char being
signed, as it is on most, but not all, platforms).

Change-Id: I51d9716fe3eb02a6e98208334285c07597a6be79
Reviewed-on: https://code.wireshark.org/review/4761
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 06:22:20 +00:00
Guy Harris 25d9a7b5f1 Don't use <ctype.h> macros, and eliminate an include of <ctype.h>.
This avoids locale-dependent tests.

Change-Id: I709ff6b1a837fb0390b29f911d3b9ef1015a2d1e
Reviewed-on: https://code.wireshark.org/review/4758
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 06:09:11 +00:00
Guy Harris 762b8d78ec Don't use ctype.h routines.
That avoids locale dependency and handles possibly-signed chars (which
we weren't doing before).

Change-Id: I2afab254044e0d39dfa67acd840b9fe4ff1e6d08
Reviewed-on: https://code.wireshark.org/review/4756
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 06:01:58 +00:00
Guy Harris 0d9b449ae9 Don't use <ctype.h> macros.
They're locale-dependent (although those *particular* ones might not
be).

Remove no-longer necessary (or not-even-necessary-before-this-change)
includes of <ctype.h>

Change-Id: I1384e3ae4ccba6af9220a08773abcde7ea320573
Reviewed-on: https://code.wireshark.org/review/4755
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 01:26:27 +00:00
Guy Harris 359a32f735 No need for our own wrappers around tolower() and toupper().
We can just use g_ascii_tolower() and g_ascii_toupper();

Change-Id: I8a88a096d16ce8c60dd9151e5bdddf6747702145
Reviewed-on: https://code.wireshark.org/review/4754
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-17 01:21:48 +00:00
Guy Harris e6fcff1eb6 Use g_ascii_isalnum() rather than isalnum().
That way, we don't have to worry about casting the argument (which, in
one place, was done wrong - casting to int preserves the sign-extension
done with signed chars), and don't have to worry about a locale in which
particular 8-bit byte values are considered alphanumeric characters.

Change-Id: I129b4bfdad70ade4ab6e0a1d2c13d59ae9e6f524
Reviewed-on: https://code.wireshark.org/review/4751
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-16 23:46:58 +00:00
Guy Harris f249589938 Just have get_mac_lte_rapid_description() return the description string.
If get_mac_lte_rapid_description() returned FALSE, we always used "" as
the description string; just have it return the string, or return "" if
rapid ranges haven't been configured, and just use the string.

(If the code ever needs to determine in other places whether rapid ranges
have been configured, it can check s_rapid_ranges_configured, or
get_mac_lte_rapid_description() could return NULL in that case and the
code using the string can check for a null value.)

This should squelch some incorrect used-but-not-set warnings from at
least one compiler.

Change-Id: I3ed495a4beb4a553e453e7bca764d1d8a07c5e53
Reviewed-on: https://code.wireshark.org/review/4750
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-16 23:04:26 +00:00
Guy Harris a517d500b4 Make sort_alphabet() not fail too badly with characters in [128,255].
Treat all values in the alphabet as unsigned.

Change-Id: I4476c75352f32673a9cd131ea233465f3376fa25
Reviewed-on: https://code.wireshark.org/review/4747
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-10-16 21:56:03 +00:00