Commit Graph

228 Commits

Author SHA1 Message Date
Michael Mann 14824e6adf Revert "Fixup: tvb_* -> tvb_captured"
https://www.wireshark.org/lists/wireshark-dev/201406/msg00131.html

This reverts commit 246fe2ca4c.

Change-Id: Ib24bae0198c13a84bd7f731bf4af921212109a8f
Reviewed-on: https://code.wireshark.org/review/2430
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-19 18:25:59 +00:00
Dario Lombardo 246fe2ca4c Fixup: tvb_* -> tvb_captured
Change-Id: I9209c1271967405c34c1b6fa43e1726a4d3a5a3f
Reviewed-on: https://code.wireshark.org/review/2377
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-06-18 14:14:58 +00:00
Bill Meier d51cac21b1 Fix "might be clobbered by 'longjmp' or 'vfork' [-Werror=clobbered]" warning from gcc 4.9
Rework code related to TRY_SCSI_CDB_ALLOC_LEN macro to simplify and clarify same.
Rename some vars to catch any incorrect usage.

Change-Id: Ibf9465c5ce7670aa1147e0c311c37e582ece427a
Reviewed-on: https://code.wireshark.org/review/1177
Reviewed-by: Bill Meier <wmeier@newsguy.com>
Tested-by: Bill Meier <wmeier@newsguy.com>
2014-04-17 00:16:52 +00:00
Yaniv Kaul f4de2a2dd1 packet-scsi.c minor changes - add WWN dissection and fix a typo
Change-Id: I0ef84e088988f1a40863ab54b722faace8bacc31
Reviewed-on: https://code.wireshark.org/review/592
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-03-11 05:27:41 +00:00
Alexis La Goutte 296591399f Remove all $Id$ from top of file
(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>
2014-03-04 14:27:33 +00:00
Alexis La Goutte c39b9e7db5 Fix Dead Store (Dead assignement/Dead increment) warning found by Clang
svn path=/trunk/; revision=54457
2013-12-26 09:54:31 +00:00
Alexis La Goutte 766d4438f2 Fix -Wunused-const-variable found by Clang
svn path=/trunk/; revision=54456
2013-12-26 09:54:22 +00:00
Alexis La Goutte 00fb8f078a From Yaniv Kaul via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9595
Small changes (mainly textual) to packet-scsi.c

The attached patch fixes small issues in SCSI dissection:
1. Extends the meaning of some fields (for example, the mysterious 'LBPME' becomes 'LBPME (logical block provisioning management enabled) / TPE'
2. Adds another ASC value which is important to me - 'Thin Provisioning Soft Threshold Reached' . Added comment where to get all of them (at  http://www.t10.org/lists/asc-alph.txt or http://www.t10.org/lists/asc-num.txt)
3. Fixes a small typo: scsi.extcopy.dest_lba is 'Destination LBA', not 'Source LBA' (silly copy-paste mistake).

svn path=/trunk/; revision=54455
2013-12-26 09:54:12 +00:00
Bill Meier eecbfd1f3b Reove _U_ from some function parameters ...
svn path=/trunk/; revision=54386
2013-12-23 15:35:07 +00:00
Martin Mathieson f687bd18da Change types to try to avoid warnings.
svn path=/trunk/; revision=54385
2013-12-23 15:25:05 +00:00
Alexis La Goutte 5742802a73 From Yaniv Kaul via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9551
Dissect SCSI XCOPY and RECEIVE COPY Parameters commands

From me :
Fix encoding-args
Fix trailing whitespace

svn path=/trunk/; revision=54381
2013-12-23 13:45:07 +00:00
Bill Meier 1de89438f2 Create/use a number of extended value-strings;
Remove or comment out dups from several value-string arrays;
 Sort a number of value-string arrays;
Reformat many hf[] entries;
Remove some unneeded initializers;
Add editor-modelines;
Use consistent indentation;
Reformat whitespace.

svn path=/trunk/; revision=53968
2013-12-12 19:26:55 +00:00
Anders Broman 2939977a4b - Make local functions static.
- Forward declaration of register functions.

svn path=/trunk/; revision=53942
2013-12-11 20:04:37 +00:00
Bill Meier 9874da2fcb #if 0 numerous "unused const variables" (mostly value-string-arrays);
Also; fix a few "set but not used" warnings.

svn path=/trunk/; revision=52780
2013-10-23 06:29:11 +00:00
Bill Meier 2ac134b3c5 whitespace fixes; mostly: remove trailing blanks
svn path=/trunk/; revision=52591
2013-10-13 19:56:52 +00:00
Jörg Mayer f737cea032 emem -> wmem
svn path=/trunk/; revision=52038
2013-09-14 14:33:04 +00:00
Evan Huus 21d9e011d0 From Yaniv Kaul via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9040
Small fixes and enhancements to SCSI INQUIRY results.

svn path=/trunk/; revision=51362
2013-08-15 02:23:53 +00:00
Anders Broman 4daf984804 From Yaniv Kaul:
small addition to SCSI dissection (media rotation speed analysis)

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9030

svn path=/trunk/; revision=51330
2013-08-13 05:19:48 +00:00
Jeff Morriss 77ff8f6d59 Remove a couple of set-but-no-longer-used variables.
svn path=/trunk/; revision=51225
2013-08-08 18:03:29 +00:00
Michael Mann 30e199e2a1 Use convert_proto_tree_add_text.pl to make many more fields filterable.
Someone may want to check that the display filter naming scheme is consistent, I at least tried to make it consistent with the new filters created.
May want to also add subtrees for the bit flags that used to be grouped in a single proto_tree_add_text.

svn path=/trunk/; revision=51223
2013-08-08 17:25:03 +00:00
Anders Broman 907e735f60 From Javier Godoy:
Dissect SCSI OSD attribute identification sense data descriptor.

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8971

svn path=/trunk/; revision=51179
2013-08-07 04:28:35 +00:00
Michael Mann 86472b67df SCSI dissector does not parse PERSISTENT RESERVE commands correctly. Bug 9012 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9012).
From Bart Van Assche.

Changes:
- Add REGISTER AND MOVE and REPLACE LOST RESERVATION service actions.
- Decode the PARAMETER LIST LENGTH field correctly - this is a four
  byte field instead of a two byte field.
- For the REGISTER AND MOVE service action, add support for decoding
  the RELATIVE TARGET PORT IDENTIFIER, TRANSPORT ID LENGTH and
  TransportID fields.
- Fix parsing of the SERVICE ACTION field - this field is five bits
  wide instead of four.
- Move the definition of the "scsi.persresv.control.unreg" field just
  below the other REGISTER AND MOVE service action parameter list fields.

See also http://www.t10.org/cgi-bin/ac.pl?t=f&f=spc4r36h.pdf.

- Only display persistent reservation information in a PERSISTENT
  RESERVE IN response if the ALLOCATION LENGTH field in the request
  was not zero.
- Correct the offset of the (SPC-2) SCOPE-SPECIFIC ADDRESS field.
  This field starts at offset 16 and not at offset 8.
- Correct the offsets of the SCOPE and TYPE fields. These fields
  are both contained in the byte at offset 21.
- Correct the base of the TRANSPORTID LENGTH field from BASE_HEX
  into BASE_NONE since this is the base required by non-numeric types.

For more information, see also:
* http://www.t10.org/cgi-bin/ac.pl?t=f&f=spc4r36h.pdf
* http://www.t10.org/cgi-bin/ac.pl?t=f&f=spc2r20.pdf

svn path=/trunk/; revision=51152
2013-08-05 15:55:10 +00:00
Alexis La Goutte 99d0205c93 From Javier Godoy via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8963
packet-scsi.c add asc/ascq code 2C:0A

Add ASC/ASCQ code 2C:0Ah "PARTITION OR COLLECTION CONTAINS USER OBJECTS" (SPC-4

svn path=/trunk/; revision=50828
2013-07-23 10:37:01 +00:00
Alexis La Goutte d7095ca214 From Javier Godoy via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8965
Packet-scsi.c: fix subtree reference: ett_sense_osd_completed

The field hf_scsi_sns_osd_object_completed should be dissected under ett_sense_osd_completed instead of ett_sense_osd_not_initiated
(It was a copy-paste error in attachment 10967 from bug 8790)

svn path=/trunk/; revision=50827
2013-07-23 10:36:52 +00:00
Jakub Zawadzki a18172147f Remove fragment_data, add fragment_head, fragment_item - for now alias it to the same structure.
This is begin of work to split fragment head and fragments items.

svn path=/trunk/; revision=50708
2013-07-17 21:12:24 +00:00
Alexis La Goutte d9b440a07a Fix typo (Missing CR)
svn path=/trunk/; revision=50342
2013-07-03 16:42:00 +00:00
Alexis La Goutte 1a364db097 Fix warning from fix-encoding-args
epan/dissectors/packet-scsi.c:  FT_BYTES:         proto_tree_add_item(tree, hf_scsi_report_opcodes_cdb_usage_data,                            tvb_v, offset_v+4, length, [[ENC_BIG_ENDIAN]-->[ENC_NA]]);

svn path=/trunk/; revision=50246
2013-06-29 22:01:13 +00:00
Alexis La Goutte e0343b57c3 Fix some Dead Store (Dead assignement/Dead increment) Warning found by Clang
svn path=/trunk/; revision=50235
2013-06-29 21:59:25 +00:00
Michael Mann dfa2156e30 Remove check_col() and the occasional tree.
svn path=/trunk/; revision=49923
2013-06-14 02:50:46 +00:00
Jeff Morriss 5fa16b2008 From Javier Godoy via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8794 :
Display the value of unknown sense descriptor codes in the tree item.
Also fix the length of the subtree.

svn path=/trunk/; revision=49916
2013-06-13 13:51:19 +00:00
Martin Kaiser 346117c265 From Javier Godoy
dissect SCSI OSD error identification sense data descriptor 

from me
- TABs -> spaces
- fix compiler errors about unused return values
- don't use another subtree within the descriptor payload

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8790

svn path=/trunk/; revision=49901
2013-06-12 14:20:36 +00:00
Anders Broman ddd78fbd78 From Javier Godoy:
dissect SCSI field pointer sense key specific information

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8789

svn path=/trunk/; revision=49895
2013-06-12 05:15:45 +00:00
Martin Kaiser 5b38f1d6e4 TABs -> spaces
add editor modelines

svn path=/trunk/; revision=49891
2013-06-11 21:33:48 +00:00
Martin Kaiser 6f6e265cf3 From Javier Godoy
dissect SCSI descriptor format sense data

from me
- replace TABs with spaces
- delete unused variable "flags"
- set format string for proto_tree_add_text()
- use val_to_str_const()

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8786

svn path=/trunk/; revision=49890
2013-06-11 21:22:58 +00:00
Anders Broman 3f896af42c From Javier Godoy:
update SCSI version descriptors defined in SPC-4 revision 36g (scsi_verdesc_val).

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8784

svn path=/trunk/; revision=49877
2013-06-11 05:06:36 +00:00
Anders Broman 0d936038c1 From Javier Godoy:
SCSI (SPC) sense key specific information field must not include SKSV.

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8782

#Backport 1.10 1.8

svn path=/trunk/; revision=49863
2013-06-09 16:51:42 +00:00
Ronnie Sahlberg 0e06d5ce58 SCSI Add decoding of Block Device Characteristics VPD page
svn path=/trunk/; revision=49592
2013-05-27 03:44:06 +00:00
Ronnie Sahlberg c8a7157414 SCSI: Print the INQUIRY EVPD page name in the info column
svn path=/trunk/; revision=49591
2013-05-27 03:13:31 +00:00
Ronnie Sahlberg 78d98f852e SCSI: add dissection of Tiemout Descriptor for REPORT SUPPORTED OPCODES
svn path=/trunk/; revision=49590
2013-05-27 01:09:49 +00:00
Ronnie Sahlberg 44e9de065d SCSI: Add support for report-one-command structure for REPORT SUPPORTED OPCODES
svn path=/trunk/; revision=49415
2013-05-19 14:45:12 +00:00
Ronnie Sahlberg a9b5d79a41 SCSI: REPORT SUPPORTED OPCODES print the reporing options in human readable
text.

svn path=/trunk/; revision=49414
2013-05-19 14:24:31 +00:00
Ronnie Sahlberg 783cf2eff2 SCSI: Add dissection of REPORT SUPPORTED OPCODES
svn path=/trunk/; revision=49408
2013-05-18 16:26:26 +00:00
Jaap Keuter 97136126bc Typo's. That is all.
svn path=/trunk/; revision=48685
2013-04-01 15:29:49 +00:00
Evan Huus 37600a157b Rename value string (and similar) functions to use a consistent pattern. This
was done using textual search+replace, not anything syntax-aware, so presumably
it got most comments as well (except where there were typos).

Use a consistent coding style, and make proper use of the WS_DLL_* defines.

Group the functions appropriately in the header.

I ended up getting rid of most of the explanatory comments since many of them
duplicated what was in the value_string.c file (and were out of sync with the
recent updates I made to those in r48633). Presumably most of the comments
should be in the .h file not the .c file, but there's enough churn ahead that
it's not worth fixing yet.

Part of https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8467

svn path=/trunk/; revision=48634
2013-03-29 00:26:23 +00:00
Guy Harris a2414d8909 Don't wire into the reassembly code the notion that reassemblies should
be done on flows from one address to another; reassembly for protocols
running atop TCP should be done on flows from one TCP endpoint to
another.

We do this by:

	adding "reassembly table" as a data structure;

	associating hash tables for both in-progress reassemblies and
	completed reassemblies with that data structure (currently, not
	all reassemblies use the latter; they might keep completed
	reassemblies in the first table);

	having functions to create and destroy keys in that table;

	offering standard routines for doing address-based and
	address-and-port-based flow processing, so that dissectors not
	needing their own specialized flow processing can just use them.

This fixes some mis-reassemblies of NIS YPSERV YPALL responses (where
the second YPALL response is processed as if it were a continuation of
a previous response between different endpoints, even though said
response is already reassembled), and also allows the DCE RPC-specific
stuff to be moved out of epan/reassembly.c into the DCE RPC dissector.

svn path=/trunk/; revision=48491
2013-03-22 23:59:54 +00:00
Anders Broman ae747e4c4b From beroset:
remove C++ incompatibilities 
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8416

svn path=/trunk/; revision=48430
2013-03-19 22:03:00 +00:00
Alexis La Goutte 824e7fd6e8 Fix some Dead Store (Dead assignement/Dead increment) Warning found by Clang
svn path=/trunk/; revision=48381
2013-03-17 19:25:08 +00:00
Ronnie Sahlberg d249e6111a SPC-3 and later has a 16-bit allocation length for the INQUIRY allocation
length.

While SPC-2 only has one byte for allocation length

Change this to treat allocation length as a 16 bit quantity starting one byte prior to the current single byte that wireshark dissects.
This makes it correct for SPC-3 and later  and still works for SPC-2 since that first byte is reserverd, == must be 0, in SPC-2 and prior.
  

svn path=/trunk/; revision=48258
2013-03-12 01:25:06 +00:00
Bill Meier 3520ab3889 Add missing 'hf_scsi_persresv_control_unreg' hf[] entry.
(Found by checkhf)

Do some minor whitespace cleanup.

svn path=/trunk/; revision=47341
2013-01-29 13:53:16 +00:00
Chris Maynard 0e34036761 Fix bug found by VS Code Analysis: warning C6336: Arithmetic operator has precedence over question operator, use parentheses to clarify intent
svn path=/trunk/; revision=47202
2013-01-22 01:56:07 +00:00