Commit graph

2425 commits

Author SHA1 Message Date
Jaap Keuter
e6ca05b8d8 From Laurant Rabret:
Please find enclosed 2 patches.
- Voip_calls_dlg.c.patch fixes a problem that appears with a release
compiled with GTK 2.8 + Visual Studio 2003. It seems g_snprintf can
corrupt memory when a length bigger than the array size is provided in
the second parameter (even if the generated string is smaller than the
array actual size!!)
- graph_analysis.c.patch fixes a memory corruption problem easy to
reproduce. Just open the pcap file enclosed, select "Statistics"->"Flow
Graph" and activate the "Network source/destination addresses" radio
button before pressing OK. You'll see a crash dump.
Thanks to check in
Best Regards
Laurent

svn path=/trunk/; revision=17543
2006-03-09 07:07:35 +00:00
Gerald Combs
9406c5db24 Use Unicode for all native Win32 calls. Unicode Windows applications
use UTF-16 internally and GTK+ 2.x uses UTF-8, which means we have to
do a lots of conversions.

Add utf_8to16() and utf_16to8 convenience functions to strutil.c.

svn path=/trunk/; revision=17534
2006-03-08 20:55:32 +00:00
Lars Roland
12224e5f22 Make calculation of TCP Graph bounds more robust. The calculation might have failed in unusual conditions.
This bug was discovered while looking at defects #130 and #131 discovered by  coverity. 
This patch also fixes these non-severe defects.

svn path=/trunk/; revision=17531
2006-03-08 18:42:16 +00:00
Jaap Keuter
1f5ada6df0 Fix left open file (coverity CID 108) and g_string leak. Clean up double width line drawing.
svn path=/trunk/; revision=17515
2006-03-08 07:06:42 +00:00
Gerald Combs
a103501de2 Fix what Coverity CID 61 was actually complaining about: Don't pass a NULL
value to get_interface_descriptive_name().

svn path=/trunk/; revision=17513
2006-03-07 22:14:12 +00:00
Gerald Combs
432e1233bb Fix Coverity run 12 CID 61: In main_cf_cb_live_capture_update_started(),
make sure capture_opts isn't NULL before we try to use it.

svn path=/trunk/; revision=17504
2006-03-07 19:11:35 +00:00
Jaap Keuter
d986b91df6 Solving various uninitialized variable warnings.
coverity reports 132, 133 and 134

svn path=/trunk/; revision=17501
2006-03-07 16:39:54 +00:00
Lars Roland
b51d8f3f89 Use g_assert to save us from dereferencing a NULL pointer. g_warning is not strong enough. This should fix a defect discovered by coverity.
svn path=/trunk/; revision=17493
2006-03-07 13:11:08 +00:00
Luis Ontanon
fd39d0ebed wrong name.
svn path=/trunk/; revision=17464
2006-03-05 02:47:00 +00:00
Luis Ontanon
568ad6c34e + retap_packets()
+ complete gtk TextWindow
+ fix elua_dumper
+ fix elua_proto


svn path=/trunk/; revision=17462
2006-03-05 02:01:16 +00:00
Anders Broman
d552e217a4 From Florent Drouin:
Just a little correction.
In the last patch for gtk/gsm_map_stat.c applied, the variable "j" was changed to "i" .

svn path=/trunk/; revision=17459
2006-03-04 10:09:47 +00:00
Anders Broman
ac21800c67 From Greg Morris:
- Change to display NCP connection for each conversation
- New NCP Endpoints. Please apply
expert_comp_table
- Use local variable space instead of pointer. The previous implementation utilized pointers and the values would change the table data.

svn path=/trunk/; revision=17446
2006-03-02 20:50:33 +00:00
Jaap Keuter
fc662e5261 In order to reduce the height of the Preference dialog moving several items from the User Interface page to the Layout page.
svn path=/trunk/; revision=17444
2006-03-02 14:44:50 +00:00
Guy Harris
c7a5c2bcca The sequence and ack numbers in a TCP are guint32's, which means they
should be printed with "%u", not "%lu" (especially on LP64 platforms).

Fix up indentation.

svn path=/trunk/; revision=17432
2006-03-01 00:13:19 +00:00
Anders Broman
983d800af7 From: Florent Drouin:
Add a test to avoid divide by zero during stat. display. Use new variable j, instead of i, already used in the loop.

svn path=/trunk/; revision=17416
2006-02-27 08:33:29 +00:00
Anders Broman
614dcef084 From Martin Mathieson
- add SIP response code 412 ("Conditional Request Failed") to stats taps.

svn path=/trunk/; revision=17409
2006-02-25 09:28:52 +00:00
Ulf Lamping
c1b208bd74 add the dumpcap manpage to the menu
svn path=/trunk/; revision=17402
2006-02-24 23:59:22 +00:00
Jaap Keuter
b78143e9b1 Fix bug 769. Print seq# and ack# as _unsigned_ int in the comment.
svn path=/trunk/; revision=17400
2006-02-24 20:46:39 +00:00
Ronnie Sahlberg
e8c497c955 when including menu.h we also need to include stdio.h to get FILE
svn path=/trunk/; revision=17391
2006-02-23 21:33:59 +00:00
Jaap Keuter
1badd16e6b Fix bug 741. Menu/Toolbar follow auto scroll checkbox in capture options.
svn path=/trunk/; revision=17389
2006-02-23 20:53:20 +00:00
Anders Broman
1fd7fbdb1d From Alejandro Vaquero:
a patch for the VoipCalls to fix a couple of issues:
- a problem with the RTP Events (RFC2833) not been handle correctly
- Display the RTP stream in time order when the setup frame is after the 
RTP stream.
- fix a init issue that caused the H245 packet to not been displayed 
correctly.

svn path=/trunk/; revision=17383
2006-02-23 20:02:23 +00:00
Michael Tüxen
0431fa4355 From Irene Ruengler:
Fix bug regarding the lower left edge and the handling of points outside the displayed region.

svn path=/trunk/; revision=17373
2006-02-22 17:27:23 +00:00
Jaap Keuter
0fe7718f9e Remove svn:executable property from source files
svn path=/trunk/; revision=17370
2006-02-22 12:04:03 +00:00
Luis Ontanon
bd63d8d003 I commented out this a while ago as they caused a crash in GTK2.8/cairo on my box. I checked it in by mistake with a lot of more files, even worst I did not pay attention to an e-mail on the list regarding the damage caused. Luckily Alejandro Vaquero contacted me directly.
svn path=/trunk/; revision=17363
2006-02-21 23:35:13 +00:00
Guy Harris
83d6dc10e1 For the "there's already a file with that name" dialog, use a wording
more like the one used by gedit.  (Note that the file in question might
not be a capture file, although it probably is.)

svn path=/trunk/; revision=17355
2006-02-19 23:51:39 +00:00
Ulf Lamping
18b62be9fb squelch some compiler warnings
svn path=/trunk/; revision=17343
2006-02-18 01:07:23 +00:00
Gerald Combs
e9226d04e5 More duplicate code removal.
svn path=/trunk/; revision=17339
2006-02-17 19:10:12 +00:00
Gerald Combs
4ee4fd52e0 Include some header files so that we can get rid of duplicate code and
call various GTK+ routines.

svn path=/trunk/; revision=17338
2006-02-17 19:07:54 +00:00
Jörg Mayer
377e6e2e27 Paolo Abeni:
pinfo->net_src and pinfo->net_dst where used to set up conversation, but
this fields are null on eap stream. use pinfo->src and pinfo->dst
instead.
The patch also enable strict checking in the 'follow ssl stream' dialog.


svn path=/trunk/; revision=17333
2006-02-17 11:56:52 +00:00
Ulf Lamping
79053183c5 remove dependencies to pcap.h, so getting an idea what needs to be done by dumpcap in addition to the things already done now
various dumpcap related code cleanup: mainly #include's and capture engine related stuff

svn path=/trunk/; revision=17327
2006-02-17 02:18:48 +00:00
Gerald Combs
e8860e5a95 Freeze and thaw the packet list after a merge so that the packet list shows
the correct information.

svn path=/trunk/; revision=17320
2006-02-16 15:53:48 +00:00
Gerald Combs
e01dfff7ce Move common control initialization to gtk/main.c where it belongs.
Remove a MessageBox() call used for debugging.

Fixup whitespace.

svn path=/trunk/; revision=17319
2006-02-16 15:27:03 +00:00
Guy Harris
e6c66fec56 Update a comment.
svn path=/trunk/; revision=17313
2006-02-15 22:29:15 +00:00
Guy Harris
a189adb2fb Have those functions that end up just calling a win32_ routine if we're
using GTK+ 2.x on Windows just have the call, nothing else (no extra
variables).

svn path=/trunk/; revision=17308
2006-02-15 11:01:57 +00:00
Jörg Mayer
461b6d35ee Paolo Abeni:
- enable the 'follow SSL stream' menu item only when a ssl packet is selected.
- when 'following' an ssl stream, show ssl decrypted data only for current conversation.
- fix a typo in ssl preference description.


svn path=/trunk/; revision=17301
2006-02-14 14:53:03 +00:00
Ulf Lamping
d350736e0b add missing #include "tempfile.h"
svn path=/trunk/; revision=17294
2006-02-13 23:52:11 +00:00
Luis Ontanon
8e121c003c Don't se_leak expert_info records.
se_alloc them where and if  needed, not every time expert_set_info_vformat is called.


svn path=/trunk/; revision=17293
2006-02-13 23:20:38 +00:00
Ulf Lamping
82f80a6daa add missing #include "tempfile.h"
svn path=/trunk/; revision=17289
2006-02-13 22:10:42 +00:00
Gerald Combs
0e32e17152 Add a placeholder for integrating with the display filter dialog.
svn path=/trunk/; revision=17286
2006-02-13 21:54:05 +00:00
Gerald Combs
80e5e0fb15 Copy over the file open/save code from the Win32 native branch.
The Windows-native routines were integrated by inserting

#if GTK_MAJOR_VERSION >= 2 && _WIN32
  win32_native_routine(GDK_WINDOW_HWND(top_level->window));
  return;
#endif

at the beginning of each GTK+ file routine.  There's probably a prettier
way to do this.

Some of the sizes need to be tweaked in win32-file-dlg.rc, but everything
seems to work.

Fix up whitespace.

svn path=/trunk/; revision=17285
2006-02-13 21:25:43 +00:00
Guy Harris
c32311dcd5 Add tempfile.h to the list of headeer files. That was the problem, not
the pathname in the #include.

svn path=/trunk/; revision=17280
2006-02-13 01:30:03 +00:00
Guy Harris
3674669ad6 Look for "tempfile.h" in the top-level directory.
svn path=/trunk/; revision=17279
2006-02-12 23:48:34 +00:00
Guy Harris
4d8d477018 Move create_tempfile() to tempfile.c out of util.c. This means dumpcap
no longer needs util.c, so it no longer includes routines that use
host_ip_af(), so it no longer needs to define its own host_ip_af().

That also means dumpcap.c no longer needs to include <sys/socket.h>.

svn path=/trunk/; revision=17278
2006-02-12 21:52:18 +00:00
Guy Harris
501dced966 Send LOG_DOMAIN_CAPTURE_CHILD messages to our log handler, so they don't
go to the standard output (as is the case for some such messages,
including the "child is sending an error message to the parent" message,
which shows up if we fail to exec dumpcap).  *Anything* other than an
official capture-child message written to the standard output by the
capture child confuses the heck out of the parent, and can cause it to
think the child closed the pipe (resulting, in the case described in the
previous parenthetical note, in no dialog box being displayed for
dumpcap not being executed).

svn path=/trunk/; revision=17274
2006-02-12 20:17:55 +00:00
Jörg Mayer
e7fc7a29ac Well, it doesn't help to apply patches and then forget to actually
commit them.
Patch by Paolo Abeni: remove some commented out code.

svn path=/trunk/; revision=17271
2006-02-12 12:48:01 +00:00
Guy Harris
b8136fbfa9 Add a routine to attempt to get the absolute pathname of the executable
file, strip off the last component to get the pathname of the directory
containing the executable file, and save it for future use.  On Windows,
you can get that from the OS, but, on UN*X, you have to look at argv[0]
and derive the absolute path from that (argv[0] is not guaranteed to be
an absolute path, or even a path at all).  (In addition, if you're
running from the build directory, you might have to strip off a ".libs/"
added to argv[0] as an artifact of the libtoolizing script.)

Use that in the About dialog, and use it to construct the path of
dumpcap.

Don't put quotes into the path of dumpcap; you don't have to quote
strings with spaces in them when handing them to execvp and, in fact,
you *mustn't* quote them, as the quotes will be treated as part of the
pathname.

svn path=/trunk/; revision=17267
2006-02-12 03:15:29 +00:00
Guy Harris
ea82d47d0c Add userdata arguments to a bunch of stat initialization routines to
squelch compiler warnings.  Tag one existing such argument as unused to
squelch another warning.

Fix up some indentation.

svn path=/trunk/; revision=17261
2006-02-12 00:54:56 +00:00
Ulf Lamping
ca152df284 various capture child related minor cleanups
svn path=/trunk/; revision=17258
2006-02-11 23:47:03 +00:00
Ulf Lamping
6bb67a3510 font_init don't need to know if running as a capture_child, this will simply no longer happen.
svn path=/trunk/; revision=17257
2006-02-11 23:35:31 +00:00
Ulf Lamping
cf94760fa4 the point of no return ...
using dumpcap as the capture child for Ethereal.

dumpcap is a plain console application now, even for Win32 (so no WinMain, create_console and special piping stuff reguired). The undocumented command line option -Z will switch dumpcap into "child mode", using binary instead of plain text output messages to communicate with a parent Ethereal.

Ethereal's main.c no longer needs to distinguish between child mode or not, so some simplifying here.

capture_sync.c has to call dumpcap in a "hidden window" mode using CreateProcess instead of spawnvp, otherwise an uggly console window would appear. The handles created by _pipe doesn't seem to be inheritable for this function, using CreatePipe instead.

The file capture_loop.c is only needed by dumpcap, removed from Ethereal link objects.

Some debugging aid added and other minor cleanup done.

svn path=/trunk/; revision=17256
2006-02-11 23:25:11 +00:00