Commit Graph

88 Commits

Author SHA1 Message Date
Guy Harris 5742ede54c Add an additional "title" attribute for UAT fields; that's what's
displayed to the user.

svn path=/trunk/; revision=27462
2009-02-16 04:10:06 +00:00
Stig Bjørlykke 49ec933f2b The uat files can be saved before any other preferences, so try creating
the personal configuration directory if saving the uat file fails.

svn path=/trunk/; revision=27424
2009-02-11 11:04:30 +00:00
Martin Mathieson 6508f8ca1f Add some comments to uat_new().
svn path=/trunk/; revision=27134
2008-12-30 17:21:19 +00:00
Guy Harris 9d1b5335ac g_ascii_strdown() and g_ascii_strup(), unlike g_strdown() and g_strup(),
do *not* modify the string handed to them - they g_mallocate a new
string and return it.

Create routines that *do* ASCII-only case mapping in place, and use them
instead.

Clean up indentation.

svn path=/trunk/; revision=26131
2008-09-03 19:14:52 +00:00
Luis Ontanon 28e4827320 remove a degug printf
svn path=/trunk/; revision=25950
2008-08-07 16:40:56 +00:00
Luis Ontanon 42c3239a1a luis.ontanon@gmail.com => luis@ontanon.org
svn path=/trunk/; revision=25937
2008-08-05 21:03:46 +00:00
Anders Broman 7a57ee1f01 Fix some of the Errors/warnings detected by checkapi.
svn path=/trunk/; revision=25369
2008-05-23 06:06:33 +00:00
Jeff Morriss a5cee04fad Move the file utility functions from wiretap to libwsutil so that
libwireshark (and the plugins using those functions) do not depend on
wiretap on Windows.

While doing that, rename the eth_* functions to ws_*.

svn path=/trunk/; revision=25354
2008-05-22 15:46:27 +00:00
Stig Bjørlykke fdc980e79d Added an option to uat_new() to set if configuration shall be saved in the
selected profile.

Don't save SMI Paths and SMI Modules in the profiles because reloading
currently doesn't work (bug 2309).

svn path=/trunk/; revision=24580
2008-03-06 22:13:24 +00:00
Jeff Morriss 1c319c4e2c get_datafile_path() and get_persconffile_path() return malloc'd memory,
free it when we're done with the file name.

svn path=/trunk/; revision=24477
2008-02-26 19:03:01 +00:00
Gerald Combs 6537c76fb6 Extend the UAT and preferences code so that you can use the "-o" flag
to override UAT entries from the command line, e.g.

  -o "uat:user_dlts:\"User 0 (DLT=147)\",\"http\",\"0\",\"\",\"0\",\"\""
  
Fix up white space.

svn path=/trunk/; revision=24338
2008-02-15 22:36:24 +00:00
Stig Bjørlykke 1efb7e3627 Add Luis' uat_get_table_by_name() to fetch SMI uat tables.
svn path=/trunk/; revision=24229
2008-01-30 22:50:55 +00:00
Stig Bjørlykke 1621224a86 Free allocated data in prefs_reset, removed need for uat_reload_all and
made some cleanups in profile_dlg.

svn path=/trunk/; revision=24136
2008-01-19 01:18:35 +00:00
Stig Bjørlykke a2d1e9005d This patch adds support for configuration profiles, which can be used to
configure and use more than one set of preferences and configuration files.

This can be found in the "Configuration Profiles..." menu item from the Edit
menu, or by pressing Shift-Ctrl-A.  It's also possible to start wireshark
and tshark with a named profile by using the "-C ProfileName" option.
A new status pane in the main window will show the current profile.

The configuration files currently stored in the Profiles are:
- Preferences
- Capture Filters
- Display Filters
- Coloring Rules
- Disabled Protocols
- User Accessible Tables

The recent data are by design not added to the profile.

Planned future enhancements:
- make a more convenient function to switch between profiles
- add a "clone profile" button to copy an existing profile
- make the profiles list active and accept return as OK
- save users "Decode as" in the profile
- make new, clone and deletion of profiles more secure
- make some of the recent values available in the profile

This patch also fixes:
- setting default status pane sizes
- a bug setting status pane for packets when not having main lower pane.

svn path=/trunk/; revision=24089
2008-01-14 16:40:23 +00:00
Jaap Keuter e2ca71beae Allocate enough space to make proper NULL terminated string in uat_unesc (bug 2169) and uat_unbinstring,
svn path=/trunk/; revision=24017
2008-01-06 13:09:33 +00:00
Stig Bjørlykke 0238daecf6 From Jim Young:
Fixed reading uat personal files before global files.

This fixes bug 2070.

svn path=/trunk/; revision=23883
2007-12-16 13:17:37 +00:00
Jeff Morriss 853e791444 Change more fopen() to eth_fopen() to finish fixing bug 1827:
http://bugs.wireshark.org/bugzilla/show_bug.cgi?id=1827

Update README.developer to tell developers not to use fopen() and friends
directly.

svn path=/trunk/; revision=23206
2007-10-16 15:43:18 +00:00
Luis Ontanon 0c154e528a Commit canges to uat_load.l, and initialize uat_t->loaded (not every system zeroes-out on malloc).
svn path=/trunk/; revision=22705
2007-08-28 15:38:05 +00:00
Luis Ontanon dfbac00752 SNMP:
- As noted by Thomas Anders values are not added to the tree anymore. Move the calling of subdissectors to the end of the function, so that the value is added to the tree.
 - add port 8161 to be decoded as SNMP (hey, it's on IANA's services file!)
UAT:
 - do not have the uat reloaded.
OIDS:
 - do not complain if renaming an OID to an identical name



svn path=/trunk/; revision=22704
2007-08-28 15:18:32 +00:00
Guy Harris fad7133f81 Fix yet more casts of ctype.h macro arguments - and fix some cases where
we were passing an uncasted "char" to those macros.

svn path=/trunk/; revision=22306
2007-07-14 00:37:01 +00:00
Guy Harris 1bc049906a Add some GCC warnings to the standard set, and add some others to the
--enable-extra-gcc-checks set.

If we turn on -pedantic, try turning on -Wno-long-long as well, so that
it's not *so* pedantic that it rejects the 64-bit integral data types
that we explicitly require.

Constify a bunch of stuff, and make some other changes, to get rid of
warnings.

Clean up some indentation.

svn path=/trunk/; revision=21526
2007-04-23 10:59:26 +00:00
Stephen Fisher fa57c8fc44 Fix some Solaris buildbot warnings
svn path=/trunk/; revision=21423
2007-04-13 23:32:21 +00:00
Richard van der Hoff af6809a33d fix an 'unused parameter' warning
svn path=/trunk/; revision=21325
2007-04-03 19:53:05 +00:00
Luis Ontanon 9709011a9b Implement a proposal from Elefterios Gabriel for SCCP:
Add a table of DPCs and SSNs that allow to override the protocol that would be choosen
so that the same SSN can use two different protocols in two different DPCs.

I did not believe it someone could have done it, then I saw the captures...


svn path=/trunk/; revision=21321
2007-04-03 19:08:00 +00:00
Luis Ontanon b2e5988e63 Fix management of lstrings in uat code so that arbitrary chars (even '\0's) can be used inside.
Fixes bug 1502


svn path=/trunk/; revision=21294
2007-04-01 14:55:25 +00:00
Luis Ontanon 5db2005993 Have Aply, Cancel and OK buttons instead of the save and ok button.
Have these buttons reloading the capture file if needed.
Some rearrangement of the window (the editor is still missing "ornaments" and tooltips)


svn path=/trunk/; revision=20788
2007-02-11 16:09:21 +00:00
Luis Ontanon 4e55e354bb Have the windows buildot compiling again.
svn path=/trunk/; revision=20742
2007-02-08 10:15:04 +00:00
Luis Ontanon 9422dfd084 UAT: filed definitions for proto (a dissector hanlde obtained by name)
UATify user-DLTs


svn path=/trunk/; revision=20740
2007-02-07 20:45:14 +00:00
Luis Ontanon 2006fac500 * Add a category param to the uat.
* UATify SNMP Users


svn path=/trunk/; revision=20736
2007-02-07 14:54:35 +00:00
Luis Ontanon bc2ca61083 Add ENUM and HEXBYTES modes
svn path=/trunk/; revision=20733
2007-02-07 03:39:40 +00:00
Luis Ontanon 2b22bcb1a3 * Add a help facility for UATs
* export help_topic_html()


svn path=/trunk/; revision=20717
2007-02-05 05:06:21 +00:00
Luis Ontanon fbc8912b87 Move (Up/Down) & Save buttons
svn path=/trunk/; revision=20708
2007-02-04 05:19:02 +00:00
Luis Ontanon 8bfa2bace4 the quoted_string regexp in uat_load() fails badly on "...\\", workarround in uat_save() using \x5c and \x22 (hex for \ and ")
svn path=/trunk/; revision=20706
2007-02-04 02:29:06 +00:00
Luis Ontanon d70a58f881 second iteration:
* fields of an uat table now are passed using an array of uat_filed_t
* field callbacks take two more userdata arguments
* add some macros to define uat field callbacks.
* uats can be registered as preferences for a specific protocol
   - the preference widget is a button that opens the uat's window
* dfilter-macro => reflect changes to API


svn path=/trunk/; revision=20695
2007-02-03 14:25:02 +00:00
Luis Ontanon 7d352fa51b some cleanup and pset of svn:ignore
svn path=/trunk/; revision=20603
2007-01-29 14:11:44 +00:00
Luis Ontanon 6a4a51ffec The UAT gui starts to work
set the macros_dlg to use it

add a dummy dfilter_macros file to supress a warning at startup


svn path=/trunk/; revision=20598
2007-01-29 10:23:38 +00:00
Luis Ontanon 5af746016a now it is operational.
svn path=/trunk/; revision=20595
2007-01-29 04:47:58 +00:00
Luis Ontanon 88e699977c Although yet untested (but it compiles and is still unused) add UAT to the repo.
UAT is an API to handle User Accessible Tables,
an UAT is basically an array of arbitrary structs that has a file representation
as a mean for mantaining things like:
- the snmp_users_table
- dfilter macros
- ipsec/ssl key bindings
- k12 configuration,
- and many other table-like user modifiable preferences

comming soon gtk's uat_window() and prefs_add_uat()

uat.h is fairly doc[uo]m[m]?ented, a README with a simple example of how is to be used will be available as I write them


svn path=/trunk/; revision=20586
2007-01-28 10:31:32 +00:00