aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-tnef.c
AgeCommit message (Collapse)AuthorFilesLines
2015-03-02tnef: fix overflow leading to infinite loopEvan Huus1-1/+4
Thanks to Vlad Tsyrklevich for the report, and Fabian Yamaguchi for the "joern" tool which found the bug. Bug: 11023 Change-Id: I53bc998c9934736698e7db5eba09a14e79a7c633 Reviewed-on: https://code.wireshark.org/review/7461 Petri-Dish: Evan Huus <eapache@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Evan Huus <eapache@gmail.com>
2014-12-25Deleting unnecessary #includes from dissectors.Martin Mathieson1-1/+0
Fifth batch (packet-rtp.c -> end). Will look at cleaning up and committing script afterwards. Change-Id: I8ed61dc941d98d3f7259a9d1f74e214eb7b4bfa2 Reviewed-on: https://code.wireshark.org/review/6052 Reviewed-by: Martin Mathieson <martin.r.mathieson@googlemail.com>
2014-12-21Cleanup use of #includes in non-generated epan/dissector/*.cBill Meier1-2/+0
Specifically: - Set packet.h to be the first wireshark #include after config.h and "system" #includes. packet.h added as an #include in some cases when missing. - Remove some #includes included (directly/indirectly) in packet.h. E.g., glib.h. (Done only for those files including packet.h). - As needed, move "system" #includes to be after config.h and before wireshark #includes. - Rework various #include file specifications for consistency. - Misc. Change-Id: Ifaa1a14b50b69fbad38ea4838a49dfe595c54c95 Reviewed-on: https://code.wireshark.org/review/5923 Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-10-06Adjust some whitespace to match editor modelines.Bill Meier1-52/+52
Change-Id: Ia22cac3ebd7a454c156f98d967e6fd61f708a2b3 Reviewed-on: https://code.wireshark.org/review/4489 Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-10-04Add editor modelines; Reformat as appropriate.Bill Meier1-277/+290
Change-Id: I8e9c58b75eea85877d22024201e5d8d0e9a3dbfd Reviewed-on: https://code.wireshark.org/review/4459 Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-06-18Fixup: tvb_get_string(z) -> tvb_get_string(z)_encDario Lombardo1-1/+1
Change-Id: I63a3704effe3fcab01a193dc39b6a22e9f1cf3fe Reviewed-on: https://code.wireshark.org/review/2376 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-06-07tvb_new_subset -> tvb_new_subset_length when length parameters are equal.Michael Mann1-2/+2
tvb_new_subset -> tvb_new_subset_remaining it appears that's what the intention is. Change-Id: I2334bbf3f10475b3c22391392fc8b6864454de2d Reviewed-on: https://code.wireshark.org/review/1999 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-03-04Remove all $Id$ from top of fileAlexis La Goutte1-2/+0
(Using sed : sed -i '/^ \* \$Id\$/,+1 d') Fix manually some typo (in export_object_dicom.c and crc16-plain.c) Change-Id: I4c1ae68d1c4afeace8cb195b53c715cf9e1227a8 Reviewed-on: https://code.wireshark.org/review/497 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2013-12-16Use proto_tree_add_item() in preference to fetching the string andGuy Harris1-14/+6
adding it with proto_tree_add_string(). Use tvb_get_string_enc() rather than tvb_get_unicode_string() to fetch strings. We assume a UTF-16 encoding for all "Unicode" strings. Use tvb_strsize() and tvb_unicode_strsize() to get the lengths of null-terminated strings. Get rid of unused ett_nt_unicode_string variable. svn path=/trunk/; revision=54158
2013-12-10- Forward declaration of register functions.Anders Broman1-0/+3
svn path=/trunk/; revision=53918
2013-11-24Move dceprc_procedure_name from packet_info to dcerpc_info. Doesn't appear ↵Michael Mann1-0/+1
to be "used" by dissectors, just stored (for help in debugging?). svn path=/trunk/; revision=53552
2013-11-09Don't include <epan/strutil.h> when not needed.Jakub Zawadzki1-1/+0
svn path=/trunk/; revision=53194
2013-11-06Remove pinfo->private_data from DCERPC dissectors and instead have ↵Michael Mann1-22/+15
dcerpc_info* infomation be passed in as a function parameter. Bug 9387 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9387) All "generated" source was manually modified (with the power of search/replace), but I believe the "source input" files have been adjusted (checked into revs 53098 and 53099) to reflect the necessary changes (with possible whitespace formatting differences). The Microsoft compiler doesn't flag "unused function parameters", so I apologize in advance if I may have missed a few. The "dcerpc_info* di" parameter is used in almost every function. svn path=/trunk/; revision=53100
2013-10-13whitespace fixes; mostly: remove trailing blanksBill Meier1-1/+1
svn path=/trunk/; revision=52591
2013-09-30Convert some proto_tree_add_string_format calls to something more appropriate.Michael Mann1-2/+2
There seem to be several cases of proto_tree_add_string_format where a "string" value/filter doesn't really make sense because it's always empty, and is just being used as a "filterable subtree header (placeholder)". They appear to be more for "presense" than "value" and should probably be FT_NONE, although I'd almost argue for removing the filter in favor of proto_tree_add_text. svn path=/trunk/; revision=52296
2013-09-22emem -> wmem conversion:Pascal Quantin1-3/+3
- ep_tvb_get_bits() -> wmem_packet_tvb_get_bits() - tvb_g_memdup()/ep_tvb_memdup() -> tvb_memdup() - tvb_fake_unicode()/tvb_get_ephemeral_faked_unicode() -> tvb_get_faked_unicode() - tvb_get_g_string()/tvb_get_ephemeral_string()/tvb_get_seasonal_string() -> tvb_get_string() - tvb_get_g_unicode_string()/tvb_get_ephemeral_unicode_string() -> tvb_get_unicode_string() - tvb_get_ephemeral_string_enc() -> tvb_get_string_enc() - update docs accordingly svn path=/trunk/; revision=52172
2013-09-09expert_add_info_format_text -> expert_add_info_formatMichael Mann1-1/+1
svn path=/trunk/; revision=51852
2013-08-05Keep result of [new_]register_dissector in some dissectors. [2 of x]Jakub Zawadzki1-1/+1
(don't create new dissector handle if we can use already existing one) svn path=/trunk/; revision=51159
2013-08-05Keep result of [new_]register_dissector in some dissectors.Jakub Zawadzki1-3/+4
svn path=/trunk/; revision=51156
2013-08-05Convert remaining proto_item_set_expert_flags in dissector directory.Michael Mann1-8/+17
svn path=/trunk/; revision=51142
2013-02-24Fix some Dead Store (Dead assignement/Dead increment) Warning found by ClangAlexis La Goutte1-1/+1
svn path=/trunk/; revision=47861
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-06-28Update Free Software Foundation address.Jakub Zawadzki1-1/+1
(COPYING will be updated in next commit) svn path=/trunk/; revision=43536
2012-05-15Remove unneeded #includes (stdlib, stdio, ctypes, time);Bill Meier1-3/+0
In a few cases: do some whitespace, indentation cleanup & reformatting. svn path=/trunk/; revision=42632
2012-05-11Get rid of remaining Booleans-as-encoding-arguments inGuy Harris1-5/+7
proto_tree_add_item() calls. svn path=/trunk/; revision=42560
2012-03-31Fix off by one shift errors introduced in r39530 where it seemed proper[1]Jakub Zawadzki1-2/+2
[1] I'm unsure of packet-dtpt, so I haven't patch it. svn path=/trunk/; revision=41873
2011-10-23Replace use of tvb_get_ephemeral_faked_unicode() by use of ↵Bill Meier1-2/+2
tvb_get_ephemeral_unicode_string(); Fix encoding arg as needed. svn path=/trunk/; revision=39530
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-15Convert proto_tree_add_item() 'encoding' arg for field types FT_STRING, ↵Bill Meier1-5/+5
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-10 Convert 'encoding' parameter of certain proto_tree_add_item() calls in ↵Bill Meier1-1/+1
non-autogenerated epan/dissectors: Specifically: Replace FALSE|0 and TRUE|1 by ENC_BIG_ENDIAN|ENC_LITTLE_ENDIAN as the encoding parameter for proto_tree_add_item() calls which directly reference an item in hf[] which has a type of: FT_BOOLEAN FT_IPv4 FT_EUI64 FT_GUID FT_UINT_STRING Also: For type FT_ITv6 use ENC_NA. (This was missed in SVN #39260) svn path=/trunk/; revision=39328
2011-10-06Convert 'encoding' parameter of certain proto_tree_add_item() calls in ↵Bill Meier1-29/+29
non-autogenerated epan/dissectors: Specifically: Replace FALSE|0 and TRUE|1 by ENC_BIG_ENDIAN|ENC_LITTLE_ENDIAN as the encoding parameter for proto_tree_add_item() calls which directly reference an item in hf[] which has a type of: FT_UINT8 FT_UINT16 FT_UINT24 FT_UINT32 FT_UINT64 FT_INT8 FT_INT16 FT_INT24 FT_INT32 FT_INT64 FT_FLOAT FT_DOUBLE svn path=/trunk/; revision=39288
2011-10-04Use ENC_NA as encoding for proto_tree_add_item() calls which directly ↵Bill Meier1-8/+8
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-06-22Fix some gcc 4.6 "set but not used [-Wunused-but-set-variable]" warnings;Bill Meier1-69/+69
Also: misc minor cleanup: unneeded #include; whitespace, tvb_length-->tvb_reported_length svn path=/trunk/; revision=37757
2011-03-31Fix 11 occurrences of returned pointer never used. Fixes CID's 1064-1067.Chris Maynard1-12/+11
svn path=/trunk/; revision=36426
2010-12-20Rename the routines that handle dissector tables with unsigned integerGuy Harris1-1/+1
keys to have _uint in their names, to match the routines that handle dissector tables with string keys. (Using _port can confuse people into thinking they're intended solely for use with TCP/UDP/etc. ports when, in fact, they work better for things such as Ethernet types, where the binding of particular values to particular protocols are a lot stronger.) svn path=/trunk/; revision=35224
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-6/+3
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
2010-01-03Fixed abbrev for attribute date.Stig Bjørlykke1-1/+1
svn path=/trunk/; revision=31423
2009-10-04use a fake dcerpc_call_data structure before we call into the dcerpc Ronnie Sahlberg1-2/+4
helpers svn path=/trunk/; revision=30289
2009-06-18From Kovarththanan Rajaratnam via bug 3548:Stig Bjørlykke1-60/+60
(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-02-06#include <conversation.h> not req'd ....Bill Meier1-1/+0
svn path=/trunk/; revision=27389
2008-11-30Added dumping of generic PT_UNICODE and PT_CLSID.Stig Bjørlykke1-8/+19
svn path=/trunk/; revision=26883
2008-11-27Added support for open TNEF files directly.Stig Bjørlykke1-3/+21
No we can decode those winmail.dat files. svn path=/trunk/; revision=26864
2008-09-30Minor proto_reg_handoff cleanup: use find_dissector when appropriate.Bill Meier1-2/+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
2007-09-06Moved packet-imf.c and packet-tnef.c from ASN_DISSECTOR_SRC to ↵Stig Bjørlykke1-1/+1
CLEAN_DISSECTOR_SRC, as they are not generated from ASN1. svn path=/trunk/; revision=22817
2007-07-25Small cosmetic change to show Named Property name.Graeme Lunt1-0/+3
svn path=/trunk/; revision=22402
2007-07-14New dissector for Transport-Neutral Encapsulation Format - TNEF.Graeme Lunt1-0/+821
TNEF is a Microsoft defined format for carrying additional information about a message (e.g. rich text formatting) and generally appears as a "winmail.dat" attachment. Details are here: http://msdn2.microsoft.com/en-us/library/ms530652.aspx This is a basic dissector which handles the TNEF attributes and the MAPI properties (found in MAPIPROPS TNEF attribute). It is not complete and requires further work to complete the dissection. However it will dissect TNEF generated from Outlook (including messages with attachments). It is registered under the appropriate BER OID (1.2.840.113556.3.10.1) for X.400 attachments and media type ("application/ms-tnef") for MIME messages. For MIME messages, any content-transfer-encoding (usually base64) needs to be removed before calling this dissector. There is a preference in the MIME multipart dissector to do this. svn path=/trunk/; revision=22312