aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-imf.c
AgeCommit message (Collapse)AuthorFilesLines
2012-12-26Fix a bunch of warnings.Guy Harris1-1/+1
Cast away some implicit 64-bit-to-32-bit conversion errors due to use of sizeof. Cast away some implicit 64-bit-to-32-bit conversion errors due to use of strtol() and strtoul(). Change some data types to avoid those implicit conversion warnings. When assigning a constant to a float, make sure the constant isn't a double, by appending "f" to the constant. Constify a bunch of variables, parameters, and return values to eliminate warnings due to strings being given const qualifiers. Cast away those warnings in some cases where an API we don't control forces us to do so. Enable a bunch of additional warnings by default. Note why at least some of the other warnings aren't enabled. randpkt.c and text2pcap.c are used to build programs, so they don't need to be in EXTRA_DIST. If the user specifies --enable-warnings-as-errors, add -Werror *even if the user specified --enable-extra-gcc-flags; assume they know what they're doing and are willing to have the compile fail due to the extra GCC warnings being treated as errors. svn path=/trunk/; revision=46748
2012-09-20We always HAVE_CONFIG_H so don't bother checking whether we have it or not.Jeff Morriss1-2/+0
svn path=/trunk/; revision=45017
2012-08-15convert GStrings to more "ephemeral friendly" use.Michael Mann1-4/+2
svn path=/trunk/; revision=44515
2012-07-08UATs could be put into "categories". The categories were defined onlyGuy Harris1-1/+3
implicitly by the #define name and string they were defined to; not all UATs neatly fit into any of the categories, so some of them were put into categories that weren't obviously correct for them, and one - the display filter macro UAT - wasn't put into any category at all (which caused crashes when editing them, as the GUI code that handled UAT changes from a dialog assumed the category field was non-null). The category was, in practice, used only to decide, in the aforementioned GUI code, whether the packet summary pane needed to be updated or not. It also offered no option of "don't update the packet summary pane *and* don't redissect anything", which is what would be appropriate for the display filter macro UAT. Replace the category with a set of fields indicating what the UAT affects; we currently offer "dissection", which applies to most UATs (any UAT in libwireshark presumably affects dissection at a minimum) and "the set of named fields that exist". Changing any UAT that affects dissection requires a redissection; changing any UAT that affects the set of named fields that exist requires a redissection *and* rebuilding the packet summary pane. Perhaps we also need "filtering", so that if you change a display filter macro, we re-filter, in case the display is currently filtered with a display filter that uses a macro that changed. svn path=/trunk/; revision=43603
2012-06-28Update Free Software Foundation address.Jakub Zawadzki1-1/+1
(COPYING will be updated in next commit) svn path=/trunk/; revision=43536
2012-03-30Recreate the packet list when changing UAT for header fields.Stig Bjørlykke1-1/+1
This fixes a crash when changing settings for fields used as a custom column. svn path=/trunk/; revision=41840
2012-03-27Check the user-provided custom header string for invalid characters beforeStig Bjørlykke1-7/+19
trying to register it in an hf; registering invalid characters in an hf will lead to an assertion. This was fixed for the http dissector in revision 41787. svn path=/trunk/; revision=41791
2012-03-12Improved a if-check to avoid a analyzis warning.Stig Bjørlykke1-1/+1
svn path=/trunk/; revision=41508
2011-11-09Fix a number of proto_tree_add_item() encoding args.Bill Meier1-1/+1
svn path=/trunk/; revision=39774
2011-10-21For proto_tree_add_item(..., proto_xxx, ...)use ENC_NA as the encoding arg.Bill Meier1-1/+1
Also: remove trailing whitespace for a number of files. svn path=/trunk/; revision=39503
2011-10-18Added support for User-Agent.Stig Bjørlykke1-1/+6
Fixed finding line end for content type parameters. svn path=/trunk/; revision=39459
2011-10-15Convert proto_tree_add_item() 'encoding' arg for field types FT_STRING, ↵Bill Meier1-17/+17
FT_STRINGZ, FT_UINT_STRING as follows: 1. If there's no character encoding (ENC_ASCII, ...) specified then use ENC_ASCII. 2. For all but FT_UINT_STRING, always use ENC_NA (replacing any existing True/1/FALSE/0 /ENC_BIG_ENDIAN/ENC_LITTLE_ENDIAN). svn path=/trunk/; revision=39426
2011-10-14Added support for SIO-Label from draft-zeilenga-email-seclabel-04.Stig Bjørlykke1-23/+150
svn path=/trunk/; revision=39415
2011-10-05Cleanup the unregister loop to avoid freeing wrong data.Stig Bjørlykke1-7/+12
svn path=/trunk/; revision=39269
2011-10-04Use ENC_NA as encoding for proto_tree_add_item() calls which directly ↵Bill Meier1-1/+1
reference an hf item (in hf[] with types: FT_NONE FT_BYTES FT_IPV6 FT_IPXNET FT_OID Note: Encoding field set to ENC_NA only if the field was previously TRUE|FALSE|ENC_LITTLE_ENDIAN|ENC_BIG_ENDIAN svn path=/trunk/; revision=39260
2011-10-04Free duplicated strings in hf entries.Stig Bjørlykke1-7/+11
svn path=/trunk/; revision=39259
2011-10-04Make custom IMF headers a part of profiles.Stig Bjørlykke1-1/+1
svn path=/trunk/; revision=39253
2011-10-04Delete allocated header fields when updating the UAT.Stig Bjørlykke1-5/+6
Don't call header_fields_initialize_cb for prefs, as it will be called when done in the UAT. svn path=/trunk/; revision=39252
2011-10-04Make value_strings const to fix checkapi warning. Do some minor reformatting.Jeff Morriss1-14/+25
svn path=/trunk/; revision=39250
2011-10-04Added support for configuring custom IMF headers.Stig Bjørlykke1-8/+188
svn path=/trunk/; revision=39249
2011-08-16Don't prefix description with imf.Stig Bjørlykke1-2/+2
svn path=/trunk/; revision=38553
2011-06-19Fix gcc 4.6 "set but not used [-Wunused-but-set-variable]" warnings.Bill Meier1-2/+1
svn path=/trunk/; revision=37716
2011-05-20Don't assign to a proto_item* if the value won't be used:Bill Meier1-3/+3
Fixes Coverity 903,935,968,985,997,999,1024,1025,1134; Remove unneeded #includes; Do whitespace cleanup. svn path=/trunk/; revision=37331
2011-04-16Remove another unneeded NULL check. Fixes Coverity CID 605.Gerald Combs1-2/+2
svn path=/trunk/; revision=36673
2011-04-01Remove const type qualifier from cast. Resolves CID's 582-585.Chris Maynard1-1/+1
svn path=/trunk/; revision=36430
2011-01-07Append text to INFO column. Closes out bug 4472.Chris Maynard1-0/+2
svn path=/trunk/; revision=35423
2010-11-24Whitespace cleanup;Bill Meier1-239/+242
Add some braces; svn path=/trunk/; revision=35018
2010-11-24Tighten up code dissecting message header.Bill Meier1-15/+18
This corrects the specific issue reported in Bug #3317 wherein the dissector decided there was a valid but unknown header when dissecting a binary (non text) message with a ":" as the last byte. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=3317 Note that a larger issue remains: the IMF dissector presumably shouldn't really even try to dissect a binary payload (which is proably encrypted text). svn path=/trunk/; revision=35017
2010-10-10Define some fcns & vars as static; Some #includes not req'd; packet-mikey.h ↵Bill Meier1-3/+1
not req'd. svn path=/trunk/; revision=34464
2010-04-19Improved dumping when incorrect line ending.Stig Bjørlykke1-2/+6
svn path=/trunk/; revision=32512
2010-04-06#include <string.h> not needed.Bill Meier1-1/+0
svn path=/trunk/; revision=32410
2010-04-03Remove unneeded #include <stdio.h>Bill Meier1-1/+0
svn path=/trunk/; revision=32367
2010-01-13From Didier Gautheron:Anders Broman1-2/+1
check_col.diff Remove redundant calls to check_col() if it guards only one columns function with one parameter after the column type. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=4394 svn path=/trunk/; revision=31519
2009-08-16Switch a bunch of dissectors over to using tvb_new_subset_remaining()Kovarththanan Rajaratnam1-1/+1
svn path=/trunk/; revision=29446
2009-08-09Don't guard col_clear with col_checkKovarththanan Rajaratnam1-2/+1
svn path=/trunk/; revision=29344
2009-06-18From Kovarththanan Rajaratnam via bug 3548:Stig Bjørlykke1-73/+73
(1) Trailing/leading spaces are removed from 'name's/'blurb's (2) Duplicate 'blurb's are replaced with NULL (3) Empty ("") 'blurb's are replaced with NULL (4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME, FT_PROTOCOL, FT_STRING and FT_STRINGZ field types (5) Only allow non-zero value for 'display' if 'bitmask' is non-zero svn path=/trunk/; revision=28770
2009-06-12Decode id-data, usually found within S/MIME (CMS), as IMF/MIME.Graeme Lunt1-0/+4
svn path=/trunk/; revision=28711
2009-05-19From Artem Tamazov (bug 3472):Stig Bjørlykke1-1/+3
Save/Restore pinfo->private_data when used. svn path=/trunk/; revision=28412
2009-02-06#include <conversation.h> not req'd ....Bill Meier1-1/+0
svn path=/trunk/; revision=27389
2008-09-30Minor proto_reg_handoff cleanup: use find_dissector when appropriate.Bill Meier1-1/+1
svn path=/trunk/; revision=26308
2008-08-26#include <emem.h> not req'dBill Meier1-1/+0
svn path=/trunk/; revision=26091
2008-08-25#include <prefs.h> not req'dBill Meier1-1/+0
svn path=/trunk/; revision=26089
2008-06-25Constify a bunch of stuff, to squelch -Wwrite-strings warnings. Guy Harris1-1/+1
epan/dissectors/packet-ncp2222.inc is a bit hard to fix, so we're not ready to enable that warning by default yet. Throw in some casts to handle GLib routines that take arbitrary non-const pointers (they can later return the pointers, and some callers might want to modify or free up those pointers in cases where they're known to be writable or allocated). Use ep_tvb_memdup() rather than a combination of ep_alloc() and tvb_memcpy(). Clean up some indentation. svn path=/trunk/; revision=25601
2008-04-13Support for some additionl heading fields and the display of the (non-MIME) ↵Graeme Lunt1-3/+55
message text. svn path=/trunk/; revision=24991
2008-02-07Removed even more "statement not reached" warnings.Stig Bjørlykke1-2/+0
svn path=/trunk/; revision=24286
2007-10-23Apply the small performance enhancment patches for:Anders Broman1-1/+1
- if offset is 0, tvb_length is the same as tvb_length_remaining, just faster. Replace - col_append_fstr() with faster col_append_str() - col_add_str() with col_set_str() when it's safe svn path=/trunk/; revision=23252
2007-08-15- s/ntohs/g_ntohsJeff Morriss1-11/+4
- s/ntohl/g_ntohl - s/free/g_free - Change some tvb_get_string()+g_free()'s into tvb_get_ephemeral_string() - Change some tvb_fake_unicode()+g_free()'s into tvb_get_ephemeral_faked_unicode() - Change some tvb_get_string() calls that were clearly memory leaks (like atoi(tvb_get_string(...))) into tvb_get_ephemeral_string() svn path=/trunk/; revision=22515
2007-08-13http://bugs.wireshark.org/bugzilla/show_bug.cgi?id=1739Anders Broman1-1/+1
Fro Stig Bjørlykke: 1. BER: Added support for empty indef SET 2. RTSE: Added fragment length in COL_INFO 3. IMF: Use correct hf_id for extension value 4. DOP: Fix typo in COL_INFO oid name svn path=/trunk/; revision=22492
2007-08-09Packet-imf.c - Offset must be advanced to AFTER CRLF(CRLF).Anders Broman1-25/+24
packet-multipart.c - imf_find_field_end()'s maxlength is last offset in tvb. svn path=/trunk/; revision=22476
2007-07-17"key" is a guint8 *; make the pointer into the string to which it refersGuy Harris1-1/+1
a guint8 * as well - that keeps us from sign-extending the characters before passing them to the ctype.h macros. svn path=/trunk/; revision=22337