Commit Graph

41496 Commits

Author SHA1 Message Date
Jeff Morriss 7a900c81b3 From Pontus Fuchs on -dev:
Fix collision between net/if.h and linux/if.h (which is included by libnl3).

svn path=/trunk/; revision=43557
2012-07-03 17:48:21 +00:00
Alexis La Goutte a16c3e2692 From report of Dennis Mendoza via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7429
Wireshark > 1.4 does not correctly read Association ID for PS Poll packets

Wireless Frame with subtype 0x1a don't interpret the Association ID (always 0).

Fix : 
proto_tree_add_uint() wasn't changed to proto_tree_add_item()

#BACKPORT

svn path=/trunk/; revision=43556
2012-07-03 12:28:06 +00:00
Jeff Morriss 6dd3a8b1fd From Todd Eigenschink via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7411 :
Have runlex.sh exit with the exit status of lex (if it failed).

svn path=/trunk/; revision=43555
2012-07-02 21:15:51 +00:00
Gerald Combs fcf2da1b99 [Automatic manuf, services and enterprise-numbers update for 2012-07-01]
svn path=/trunk/; revision=43551
2012-07-01 14:03:32 +00:00
Jakub Zawadzki 8c1d02377e Fix bug #7425: Per-packet right-click network or MAC name resolution not working
proto_tree_draw() from r43189 is lazy, and it don't fills tree with all item labels.
To fix it, move 'gbl_resolv_flags' hack to proto_tree_model_get_value().

XXX could we pass resolving flags to proto_item_fill_label()?


svn path=/trunk/; revision=43550
2012-06-30 10:43:50 +00:00
Guy Harris 3a4678b00f Separate the code for each column in the interface list with blank
lines.

svn path=/trunk/; revision=43549
2012-06-30 00:32:03 +00:00
Guy Harris 7546a033c7 Clarify *which* capture dialogs are handled by capture_dlg.c.
svn path=/trunk/; revision=43548
2012-06-29 22:52:13 +00:00
Jeff Morriss f01a28135f Clean up capture option tooltip spacing and remove an extraneous word (at the end of the monitor mode description). Also use sizeof for a buffer size.
svn path=/trunk/; revision=43547
2012-06-29 21:18:35 +00:00
Pascal Quantin d25ae90a67 From Martin Kaiser via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7420 :
CI/CI+: dissect CICAM NIT

svn path=/trunk/; revision=43546
2012-06-29 20:10:25 +00:00
Guy Harris 0d56350b19 Add support for listening for interface arrival/departure events on
PF_SYSTEM sockets on OS X.

Pull iface_mon_nl_init() into iface_mon_start(), to make it a little
easier to figure out what interface monitoring code on other platforms
should do.

Add a bunch of XXX comments about additional things we should perhaps
do.

svn path=/trunk/; revision=43545
2012-06-29 18:04:11 +00:00
Guy Harris 021b749051 ui/gtk/iface_lists.c no longer needs <wsutil/file_util.h>, as the
"determine the interface type" code moved to capture_ifinfo.c.

svn path=/trunk/; revision=43544
2012-06-29 18:03:17 +00:00
Jakub Zawadzki e083f0f71e Try to fix win64 buildbot.
packet-dbus.c(354) : error C2220: warning treated as error - no 'object' file generated
packet-dbus.c(354) : warning C4267: '=' : conversion from 'size_t' to 'int', possible loss of data

svn path=/trunk/; revision=43543
2012-06-29 17:44:48 +00:00
Jakub Zawadzki 33bfa85452 Initial support for D-Bus dissection (bug #5502)
svn path=/trunk/; revision=43542
2012-06-29 15:23:21 +00:00
Jakub Zawadzki 40776e2fed Add len() function to dfilter. For now only support FT_STRING*
Note: it returns bytes-length, not number of UTF-8 characters.

svn path=/trunk/; revision=43541
2012-06-29 11:11:24 +00:00
Jakub Zawadzki a8eea83c37 Also support FT_STRINGZ and FT_UINT_STRING in lower()/ upper() functions.
svn path=/trunk/; revision=43540
2012-06-29 11:07:08 +00:00
Bill Meier 163ca72bab From Роман Донченко: "Adaptation" misspelled as "adaption"
In MPEG-related dissectors, "adaption" is used instead of "adaptation" several
times. See patch (it also fixes an unrelated typo that happens to be on the
same line).

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

svn path=/trunk/; revision=43539
2012-06-29 01:55:05 +00:00
Jakub Zawadzki b18e880040 Update FSF address - part II.
svn path=/trunk/; revision=43538
2012-06-28 23:18:38 +00:00
Jakub Zawadzki f19346af34 Update GPL-2 license in COPYING
svn path=/trunk/; revision=43537
2012-06-28 23:02:28 +00:00
Jakub Zawadzki bf81b42e1e Update Free Software Foundation address.
(COPYING will be updated in next commit)

svn path=/trunk/; revision=43536
2012-06-28 22:56:06 +00:00
Jeff Morriss 35f83ce720 wsutil/file_util.h is needed here.
svn path=/trunk/; revision=43535
2012-06-28 21:11:41 +00:00
Guy Harris 9d90dc5e8f Move if_list_comparator_alph() to iface_lists.c; it's used in several
places.

svn path=/trunk/; revision=43534
2012-06-28 20:52:26 +00:00
Guy Harris cccc9f0a2d If we don't have AirPcap, don't bother with the IF_AIRPCAP case; if we
ever add support for it on additional platforms, HAVE_AIRPCAP will be
defined.

svn path=/trunk/; revision=43533
2012-06-28 20:40:44 +00:00
Guy Harris c51a19cc43 get_interface_type() contains no GUI code, so just move it up to
capture_ifinfo.c.

svn path=/trunk/; revision=43532
2012-06-28 20:16:39 +00:00
Guy Harris 8381581aa1 capture_get_if_icon() is no longer platform-dependent; the
platform-dependent work is now done in get_interface_type().

That means we also don't need to protect the handling of IF_DIALUP or
even IF_AIRPCAP in #ifdefs, just in case we add support for those types
in other OSes.

Nothing's uisng the capture_ethernet_16.xpm image here, so don't bother
including it.  (Does *anybody* use it?  I couldn't find any uses, but
maybe we should use that.)

svn path=/trunk/; revision=43531
2012-06-28 20:06:37 +00:00
Guy Harris 1ae8203b46 No pcap, no interfaces to monitor.
svn path=/trunk/; revision=43530
2012-06-28 19:10:40 +00:00
Guy Harris 5e077c6d6c <wsutil/file_util.h> is needed on Windows.
svn path=/trunk/; revision=43529
2012-06-28 19:09:22 +00:00
Guy Harris 05d6212a62 Make more routines static.
svn path=/trunk/; revision=43528
2012-06-28 19:08:11 +00:00
Guy Harris 6d5271b856 Make some routines static to ui/gtk/capture_dlg.c; they're not used
outside it.

svn path=/trunk/; revision=43527
2012-06-28 18:57:23 +00:00
Guy Harris fbc8de6048 Constify the "string to return if not found" argument to
geoip_db_lookup_ipv4() and geoip_db_lookup_ipv6().

In both of those routines, "ret" is always set to a non-null value -
it's initially set to the aforementioned string - so always return it.

svn path=/trunk/; revision=43526
2012-06-28 18:43:16 +00:00
Guy Harris 79e11663b1 <wsutil/file_util.h> is needed by ui/gtk/iface_lists.c on Linux as it
does a ws_stat64() to check for the existence of files in /sys.

It's *not* needed in ui/gtk/main.c any more, as that code was moved out
of ui/gtk/main.c.

svn path=/trunk/; revision=43525
2012-06-28 18:33:53 +00:00
Guy Harris b191653a04 Get rid of a couple of tabs.
svn path=/trunk/; revision=43524
2012-06-28 18:22:02 +00:00
Guy Harris 879189564a Move the stuff to manage the global interface list and to update
displays of that list into a separate iface_lists.c file.

svn path=/trunk/; revision=43523
2012-06-28 18:16:18 +00:00
Guy Harris fde7f31b4f No pcap, no interfaces to monitor.
svn path=/trunk/; revision=43522
2012-06-28 17:01:57 +00:00
Guy Harris 1d1391ed47 From Pontus Fuchs:
Add an interface monitor that, on Linux distributions with libnl,
watches for interfaces to appear or disappear and, on such an event,
causes windows showing interface lists to update.

svn path=/trunk/; revision=43521
2012-06-28 16:21:51 +00:00
Guy Harris 28f866815a Update some refresh_interfaces_cb() calls appropriately.
svn path=/trunk/; revision=43520
2012-06-28 15:13:53 +00:00
Guy Harris b52000fc78 Comment/#ifdef out a currently-unused variable.
svn path=/trunk/; revision=43519
2012-06-28 15:11:01 +00:00
Guy Harris 4e893a71fe Make scan_local_interfaces() local to ui/gtk/main.c; widgets/windows
that want a list of interfaces should either call
fill_in_local_interfaces() to make sure the list has been populated at
least once or refresh_local_interface_lists() if they want the list to
be rescanned.

Also make get_interface_type() local to ui/gtk/main.c, as it's not
called from outside ui/gtk/main.c.

Don't declare fill_in_local_interfaces() or hide_interface() unless we
have pcap - we don't define them unless we have pcap.

svn path=/trunk/; revision=43518
2012-06-28 08:25:17 +00:00
Guy Harris 5e7ca579ce Detangle the code that manages the interface list on the welcome screen:
fill_capture_box():

	if there are interfaces on which to capture, constructs the
	interface list, otherwise destroys the interface list and puts
	up a message.

    update_capture_box():

	updates the interface list to reflect current reality.

    welcome_if_panel_reload():

	if there is an interface list, and if there are interfaces on
	which to capture (so that we still want that list), updates the
	list by calling update_capture_box(), otherwise creates or
	destroys it by calling fill_capture_box() (as either it doesn't
	exist but now needs to or does exist but needs to go away).

Have refresh_local_interface_lists(), which re-fetches the list of local
interfaces and updates every interface list that includes local
interfaces, and refresh_non_local_interface_lists(), which only updates
interface lists that (also) include interfaces other than local
interfaces (such as pipes and remote interfaces).  Call them in the
apprpriate places (if we know the list of local interfaces has been
updated, call refresh_local_interface_lists(), otherwise, if we know
interfaces other than local interfaces have been added or removed, call
refresh_non_local_interface_lists()).

Don't have any routine that updates the interface list for one widget
update the interface list for any other widget; leave the global
updating of interface lists up to refresh_local_interface_lists() and
refresh_non_local_interface_lists() - only call one of them if any
interface lists are to be updated.

svn path=/trunk/; revision=43517
2012-06-28 08:13:21 +00:00
Guy Harris 234628c616 No pcap, no interfaces, no interface lists to refresh.
svn path=/trunk/; revision=43516
2012-06-28 02:19:12 +00:00
Guy Harris 9650d477b3 From Pontus Fuchs:
add a capture_dlg_refresh_if() routine to redraw the list of
	interfaces in the Capture -> Interfaces dialog if the lsit of
	known interfaces is updated, and have it do that not by
	destroying and reconstructing the entire dialog box, but just by
	destroying and reconstructing the table containing the
	interfaces and their statistics.

From me:

	have a refresh_interfaces_cb() routine in ui/gtk/main.c that
	scans the local interfaces and refreshes *all* the widgets that
	have interface lists;

	add a "Refresh Interfaces" item to the Capture menu that calls
	that;

	have the "Refresh" button in the "Manage Interfaces" window also
	call that;

	rename the Capture Options window routine dlg_window_present()
	to capture_dlg_window_present() to make it clearer *which*
	dialog it checks for;

	fix Pontus' patch to call capture_stat_stop() *before* nulling
	out the global pointer for the statistics cache - if it's called
	*after* nulling it out, the argument passed to
	capture_stat_stop() is null, and it doesn't kill off the dumpcap
	gathering the statistics so they just pile up (and, at least on
	OS X, chewing up BPF devices until you run out of BPF devices
	that have the right ownership and permissions for dumpcap to use
	as a normal user);

	if refreshing the interfaces fails to get an interface list,
	close the Capture Interfaces dialog.

svn path=/trunk/; revision=43515
2012-06-28 01:54:42 +00:00
Guy Harris f321db7c99 Rename the GArray of interfaces "if_array", to indicate what it really
is, and rename the routine that creates it to "make_if_array()".

svn path=/trunk/; revision=43514
2012-06-27 23:15:28 +00:00
Bill Meier 9489edfbde Commit file which should have been part of SVN #43506
From Jakub Zawadzki: Fix "typeahead search broken in Display Filter Expression Window"
 
 Revert SVN #42291.
 
 Fixes Bug #7412: https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7412


svn path=/trunk/; revision=43511
2012-06-27 14:58:32 +00:00
Pascal Quantin 698337ee9a Prettify display of O_RDONLY and O_ACCMODE flags
svn path=/trunk/; revision=43510
2012-06-27 14:57:58 +00:00
Bill Meier 9c9d57321f Fix compiler warning: "format not a string literal and no format arguments"
svn path=/trunk/; revision=43509
2012-06-27 14:44:00 +00:00
Bill Meier e42127ce00 Don't show (essentially meaningless) numeric values of the expert codes.
svn path=/trunk/; revision=43508
2012-06-27 14:15:46 +00:00
Bill Meier bd91ce6af3 Fix for "predefined values sometimes missing in Display Filter Expression window.
See https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7413

Essentially: BASE_CUSTOM was being used as a mask rather than a field value.


svn path=/trunk/; revision=43507
2012-06-27 13:57:39 +00:00
Bill Meier 45ca434f32 From Jakub Zawadzki: Fix "typeahead search broken in Display Filter Expression Window"
Revert SVN #42291.

Fixes Bug #7412: https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7412


svn path=/trunk/; revision=43506
2012-06-27 13:37:13 +00:00
Alexis La Goutte fca94d1d2d From Martin Raison via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7414
PMIPV6 support over IPV4 network

PMIPv6 is an extension of MIPv6, adding a certain number of options to the
MIPv6 protocol. These options are already implemented in the wireshark
dissector, and the MIPv6 headers are recognized, but only inside IPv6 packets.

However, RFC5844 extends the PMIPv6 protocol to make it work over IPv4 networks
: as explained in section 4 of this RFC, the MIPv6 message is carried inside an
IPv4 packet with a UDP header. The port number in the UDP header is 5436


svn path=/trunk/; revision=43505
2012-06-27 13:27:28 +00:00
Guy Harris 2851255f53 Don't supply a fallback error message for pcap_open() unless it actually
fails.

This may clear up the problem most recently reported in bug 7021 after
the crash was fixed, where the capture starts successfully but an error
dialog pops up.

svn path=/trunk/; revision=43501
2012-06-27 05:13:06 +00:00
Bill Meier e3b8929a46 General cleanup:
- Remove _U_ when function arg is actually used;
- Use consistent formatting and whitespace style.

svn path=/trunk/; revision=43500
2012-06-26 21:45:06 +00:00