Wireshark-bugs: [Wireshark-bugs] [Bug 8034] New: Friendly Names support causing unnecessary dela

Date: Sun, 02 Dec 2012 13:55:54 +0000
Bug ID 8034
Summary Friendly Names support causing unnecessary delay when Wireshark starts
Classification Unclassified
Product Wireshark
Version SVN
Hardware All
OS All
Status CONFIRMED
Severity Normal
Priority Low
Component Wireshark
Assignee [email protected]
Reporter [email protected]

Created attachment 9604 [details]
Proposed solution to avoid unnecessary delay

Build Information:
wireshark 1.9.0 (SVN Rev 46326 from /trunk)

Copyright 1998-2012 Gerald Combs <[email protected]> and contributors.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Compiled (64-bit) with GTK+ 2.24.13, with Cairo 1.12.8, with Pango 1.32.3, with
GLib 2.34.3, with libpcap, with libz 1.2.7, with POSIX capabilities (Linux),
with libnl 3, without SMI, without c-ares, without ADNS, with Lua 5.1, without
Python, without GnuTLS, with Gcrypt 1.5.0, with MIT Kerberos, without GeoIP,
with PortAudio V19-devel (built Feb 24 2012 12:00:16), without AirPcap.

Running on Linux 3.6.8-1-ARCH, with locale en_US.UTF-8, with libpcap version
1.3.0, with libz 1.2.7, Gcrypt 1.5.0.

Built using gcc 4.7.2.
--
Since the support for "Friendly Names for interfaces on Windows" [1] were
included in revision 46083, a long delay have been noticed when starting
Wireshark.

The splash says "100% - Loading configuration files" for about 15 seconds,
before continuing and the main window is shown.

I have tracked down the reason why this is and it is related to how many
interfaces the host has.

When Wireshark starts it will get the interface capabilities for every
interface from dumpcap, executing: dumpcap -i ifdev -L -Z none

With the support for "Friendly Names", dumpcap must retrieve the interface
list, iterate it and look for matches. This even if '-i' was already supplied
with the correct device name by Wireshark.

As libpcap's 'pcap_findalldevs' function takes almost one second to execute on
my host with 15 interfaces, it adds up to a 15 seconds delay when starting
Wireshark.

The implementation is not wrong, but could improve to avoid unnecessary delays.
I got an idea how this could be improved without making a too big of a change.
However, it might not be the prettiest solution...

As Wireshark will use the correct interface device name when calling dumpcap,
there is no need for trying to match it for friendly names.
We can use the fact that dumpcap knows that it is being called as a "capture
child" by Wireshark (via the -Z flag).

[1] https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6645


You are receiving this mail because:
  • You are watching all bug changes.