aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-windows-common.c
AgeCommit message (Collapse)AuthorFilesLines
2013-12-20Change G_GINT64_CONSTANT(xxxxU) to G_GUINT64_CONSTANT(xxxx)Jakub Zawadzki1-1/+1
svn path=/trunk/; revision=54314
2013-11-27- Create/use several extended value_stringsBill Meier1-177/+31
(sort associated value_string arrays as needed); - Use new VALUE_STRING_LIST mechanism/macros to create enums and value_string arrays for: WERR_errors, DOS_errors, SRV_errors, and HRD_errors; - Declare certain global value_string arrays as static (local) and use global extended value_strings to reference same; (e.g., ms_coiuntry_codes value_string_array) - Rename SMBE_... defs used in several different value_string arrays to prevent potential name collisions: ( e.g., for SRV_errors: SMBE_... ==> SMBE_SRV_...) Done for value_string arrays: DOS_errors, SRV_errors, HRD_errors; - WERR_errors value_string array: Note that WERR associated defs no longer exist in the latest samba doserr.h. (The WERR_errors defs were originally generated from the samba doserr.h). For now: WERR_errors kept as is. - ToDo: Fix PIDL-generated dcerpc dissectors to use NT_errors_ext and WERR_errors_ext extended value_strings. - Add editor modelines to a few files. - Make whitespace changes. svn path=/trunk/; revision=53614
2013-11-10Add missing includes in order to remove exceptions.h from proto.h (next commit).Jakub Zawadzki1-0/+1
svn path=/trunk/; revision=53230
2013-11-06Remove pinfo->private_data from DCERPC dissectors and instead have ↵Michael Mann1-3/+3
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-09-30Convert some proto_tree_add_string_format calls to something more appropriate.Michael Mann1-9/+9
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-15Convert proto_tree_add_uint_format to proto_tree_add_uint_format_value if ↵Michael Mann1-2/+2
hf_ field name is the first part of the formatted string. This was done with a perl script on the dissectors directory (packet-*.c), followed by manual inspection of the output. The manual inspection yielded a few cases that really should have been proto_tree_add_uint or proto_tree_add_item, so I updated them accordingly. The script didn't catch as many as I would have liked, but it's a start. The most common (ab)use of proto_tree_add_uint_format was for appending strings to CRC/checksum values to note good or bad CRC/checksum. svn path=/trunk/; revision=52045
2013-09-13Replace some emem with wmem.Evan Huus1-53/+53
The windows-common dissector seems to make excessive use of strbufs - I converted them and simplified a bit, but it could probably be simplified more. svn path=/trunk/; revision=52008
2013-02-27Move show_exception() and show_reported_bounds_error() toGuy Harris1-6/+24
epan/show_exception.c, as it's used outside epan/dissectors/packet-frame.c. Update their callers to include <epan/show_exception.h> to get their declaration. Add a CATCH_NONFATAL_ERRORS macro that catches all exceptions that, if there's more stuff in the packet to dissect after the dissector call that threw the exception, doesn't mean you shouldn't go ahead and dissect that stuff. Use it in all those cases, including ones where BoundsError was inappropriately being caught (you want those passed up to the top level, so that the packet is reported as having been cut short in the capture process). Add a CATCH_BOUNDS_ERRORS macro that catches all exceptions that correspond to running past the end of the data for a tvbuff; use it rather than explicitly catching those exceptions individually, and rather than just catching all exceptions (the only place that DissectorError should be caught, for example, is at the top level, so dissector bugs show up in the protocol tree). Don't catch and then immediately rethrow exceptions without doing anything else; just let the exceptions go up to the final catcher. Use show_exception() to report non-fatal errors, rather than doing it yourself. If a dissector is called from Lua, catch all non-fatal errors and use show_exception() to report them rather than catching only ReportedBoundsError and adding a proto_malformed item. Don't catch exceptions when constructing a trailer tvbuff in packet-ieee8023.c - just construct it after the payload has been dissected, and let whatever exceptions that throws be handled at the top level. Avoid some TRY/CATCH/ENDTRY cases by using checks such as tvb_bytes_exist() before even looking in the tvbuff. svn path=/trunk/; revision=47924
2013-02-01Fix some Dead Store (Dead assignement/Dead increment) Warning found by ClangAlexis La Goutte1-11/+2
svn path=/trunk/; revision=47424
2012-09-20We always HAVE_CONFIG_H so don't bother checking whether we have it or not.Jeff Morriss1-3/+1
svn path=/trunk/; revision=45017
2012-08-16From Stefan Metzmacher: Updates for the SMB2/3Bill Meier1-0/+1
This patches add some missing things for SMB2/3 and support for decryption of SMB3 traffic https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7645 From me: Change an initializer from C99 to C89 style (since the Microsoft compiler doesn't support C99). svn path=/trunk/; revision=44542
2012-08-10Use val_to_str_const() where appropriate;Bill Meier1-1/+1
Also (for a few files): - create/use some extended value strings; - remove unneeded #include files; - remove unneeded variable initialization; - re-order fcns slightly so prefs_reg_handoff...() at end, etc svn path=/trunk/; revision=44438
2012-06-28Update Free Software Foundation address.Jakub Zawadzki1-1/+1
(COPYING will be updated in next commit) svn path=/trunk/; revision=43536
2012-06-21Mark a couple more variables volatile.Jeff Morriss1-3/+3
svn path=/trunk/; revision=43437
2012-06-21From Richard Sharpe via ↵Jeff Morriss1-2/+3
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7387 : Don't break/return out of a TRY/CATCH. svn path=/trunk/; revision=43434
2012-06-19Mark another variable as volatile to pacify the buildbot.Jeff Morriss1-1/+1
svn path=/trunk/; revision=43376
2012-06-19Mark some variables as volatile to avoid compiler warnings.Jeff Morriss1-5/+6
svn path=/trunk/; revision=43357
2012-06-19Try to fix unused variable warnings and "clobbered by 'longjmp' or 'vfork' "Anders Broman1-5/+2
svn path=/trunk/; revision=43355
2012-06-19From Richard Sharpe:Anders Broman1-11/+43
Wireshark is unable to dissect Security Descriptors that span TCP segments where some are not captured or reassembled https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7363 svn path=/trunk/; revision=43352
2012-04-09Mark some function static.Jakub Zawadzki1-1/+1
svn path=/trunk/; revision=41999
2011-10-23Fix a few proto_tree_add_item() encoding args.Bill Meier1-1/+1
svn path=/trunk/; revision=39519
2011-10-10 Convert 'encoding' parameter of certain proto_tree_add_item() calls in ↵Bill Meier1-2/+2
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-3/+3
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-06-17From Gregor Beck via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6004Alexis La Goutte1-0/+31
dissect_nt_v2_ace: doesn't support ace type > 8 svn path=/trunk/; revision=37692
2011-05-18Fix some (value) mistakes in value_strings. Found by Martin's patch on the ↵Jeff Morriss1-44/+44
-dev list. svn path=/trunk/; revision=37262
2011-05-13Delete assignment of item as it's not used. Fixes Coverity CID 869.Chris Maynard1-3/+2
svn path=/trunk/; revision=37131
2011-04-18Removed some unneeded assignments.Stig Bjørlykke1-1/+1
Found by clang. svn path=/trunk/; revision=36698
2011-01-25packet-windows-common.c:1492: warning: 'wkwn_sid2_len' may be used ↵Anders Broman1-1/+1
uninitialized in this function svn path=/trunk/; revision=35648
2011-01-25Fix:Anders Broman1-2/+2
Error: the blurb for field "Well-known SID" ("nt.sid.wkwn") matches the field name in packet-windows-common.c svn path=/trunk/; revision=35647
2011-01-25From Cal Turney:Anders Broman1-103/+211
Enhancements to SID dissection. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5613 svn path=/trunk/; revision=35643
2010-12-06From Yaniv Kaul via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5372 :Jeff Morriss1-4/+4
Fix crash in LDAP dissector, in a generic way (for all callers of dissect_nt_sid()). svn path=/trunk/; revision=35127
2010-10-25Remove trailing space in field name.Jeff Morriss1-55/+55
svn path=/trunk/; revision=34639
2010-10-22Corrected check for end of well_known_sids.Stig Bjørlykke1-1/+1
This fixes bug 5328. svn path=/trunk/; revision=34619
2010-10-22Fixed printing guint64 variables.Stig Bjørlykke1-6/+5
Removed unused variables. svn path=/trunk/; revision=34617
2010-10-22C++ style comments in packet-windows-common.cAnders Broman1-2/+2
svn path=/trunk/; revision=34616
2010-10-22From CaL Turney:Anders Broman1-123/+288
Add support for well-known SIDs/RIDs and option to display in hex. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5286 svn path=/trunk/; revision=34613
2010-01-26Fix some gcc -Wshadow warningsBill Meier1-7/+7
svn path=/trunk/; revision=31673
2009-07-30Remove more unused variables.Gerald Combs1-1/+1
svn path=/trunk/; revision=29249
2009-07-07Changed flags_set_truth -> tfs_set_notsetStig Bjørlykke1-29/+29
svn path=/trunk/; revision=28989
2009-06-18From Kovarththanan Rajaratnam via bug 3548:Stig Bjørlykke1-36/+36
(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-05-05Use an emem_strbuf_t for the string for the subauthorities; it's a bitGuy Harris1-10/+6
cleaner, and also means that if there are no subauthorities we don't get an uninitialized string. svn path=/trunk/; revision=28272
2009-03-31From: yami <yamisoe [AT] gmail.com>: Update comment in .c file; copy same to ↵Bill Meier1-6/+7
.h file svn path=/trunk/; revision=27909
2009-03-22P64 changes: Fix some cases for which size_t is not requiredBill Meier1-3/+2
svn path=/trunk/; revision=27822
2008-10-03the security info bitmask is 4 bytes, not 2Ronnie Sahlberg1-1/+1
svn path=/trunk/; revision=26341
2008-10-03SAMR updatesRonnie Sahlberg1-0/+79
svn path=/trunk/; revision=26340
2007-05-18this error is returned in srvsvc when a SessDel fails because no matching ↵Ronnie Sahlberg1-0/+1
session can be found svn path=/trunk/; revision=21823
2007-05-17add a new dos error codeRonnie Sahlberg1-0/+1
svn path=/trunk/; revision=21809
2007-03-23From Sebastien Tandel: Stephen Fisher1-2/+2
(Fixing warnings) stripped away some unused variables/parameters + in prefs.c suggestion of parentheses makes gcc happy svn path=/trunk/; revision=21156
2006-09-23we did not have a proper WERR error table for the windows errors insterad ↵Ronnie Sahlberg1-0/+103
we justkept adding the errors to the DOS error table (this merging does work ok since there is so very little overlap between he values in both ranges) Add a new WERR error table to packet-windows-common so that PIDL generated dissectors can use this table instead of the DOS table. To make this table as complete and accurate as possible and to avoid having to type all the values in by hand the table is generated from the samba doserr.h file and two small commandlines. The commends in pakcet-windows-common.h explains how to regenerate the table from doserr.h svn path=/trunk/; revision=19306
2006-09-16make dissect_nt_sid return ep allocated memory and thus fix a few memory leaksRonnie Sahlberg1-9/+3
(this function is often called from dcerpc dissectors) svn path=/trunk/; revision=19243