Commit Graph

27 Commits

Author SHA1 Message Date
Bill Meier ac7b2df9e8 Don't call col...() and expert..() functions under 'if (tree)';
Reformat hf[] entries and various other.


svn path=/trunk/; revision=43671
2012-07-11 20:40:13 +00:00
Jakub Zawadzki bf81b42e1e Update Free Software Foundation address.
(COPYING will be updated in next commit)

svn path=/trunk/; revision=43536
2012-06-28 22:56:06 +00:00
Guy Harris 8b5748d182 Get rid of remaining Booleans-as-encoding-arguments in
proto_tree_add_item() calls.

Get rid of unnecessary include of <stdio.h>.

svn path=/trunk/; revision=42480
2012-05-07 18:59:18 +00:00
Jakub Zawadzki 9c48f9ca96 Add missing const attribute to some char *
Fix some "assignment discards qualifiers from pointer target type", etc

svn path=/trunk/; revision=41993
2012-04-09 17:53:04 +00:00
Bill Meier 20e3e0b5b5 Fix some proto_tree_add_item() encoding args;
In some files:
 Remove a few unneeded #includes;
 Do some whitespace/indentation cleanup

svn path=/trunk/; revision=39635
2011-10-27 15:59:12 +00:00
Bill Meier 794757ae8f For proto_tree_add_item(..., proto_xxx, ...)use ENC_NA as the encoding arg.
Also: remove trailing whitespace for a number of files.

svn path=/trunk/; revision=39503
2011-10-21 02:10:19 +00:00
Bill Meier 4e57694d4a Convert 'encoding' parameter of certain proto_tree_add_item() calls in 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-06 03:35:44 +00:00
Guy Harris ddd33066bb As the man said, ports are unsigned.
svn path=/trunk/; revision=38987
2011-09-13 16:39:17 +00:00
Stephen Fisher abdd48d5e3 The "Uri-Port" option is an unsigned, not signed, integer according to
its hf definition and deraft-ietf-core-coap-04 for example.


svn path=/trunk/; revision=38986
2011-09-13 16:14:28 +00:00
Guy Harris c6eb12cc5f Do more checking of the TLV length. Yes, the length can be zero or
negative in a malformed packet.  Should fix bug 6238.

svn path=/trunk/; revision=38521
2011-08-13 22:33:14 +00:00
Jeff Morriss c832e7a28e strlen returns a size_t
svn path=/trunk/; revision=38460
2011-08-10 21:27:55 +00:00
Jeff Morriss ce701a90c6 From Shoichi Sakane via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5270 :
Update COAP dissector to the latest drafts:
- corresponded to coap-07, block-04, observe-02 and link-format-06.
- improved the option handler.

From me:
Update the comment to indicate that the port is now IANA-assigned.

There's no need to memset a string to initialize it; just set the first byte
to 0.

svn path=/trunk/; revision=38459
2011-08-10 20:54:44 +00:00
Anders Broman 2ad1c8df66 VALS(& -> VALS(
svn path=/trunk/; revision=37009
2011-05-06 12:28:11 +00:00
Stig Bjørlykke 8ce65d5dee Added some missing breaks.
Coverity 447.

svn path=/trunk/; revision=36360
2011-03-27 13:35:30 +00:00
Guy Harris a8bc4a0d13 Rename the routines that handle dissector tables with unsigned integer
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-12-20 05:35:29 +00:00
Jeff Morriss 075954f5a5 From Shoichi Sakane via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5270 :
Fix the dissection of the length of the option field.

svn path=/trunk/; revision=34965
2010-11-19 02:12:19 +00:00
Jeff Morriss b0e1f62ef8 From Shoichi Sakane via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5270 :
I improved the coap dissector.  It is resulted by the 2nd coap test event. 
This patch is diff from 34794.  The fuzzying test passed more than 62000.

Changed:
- removed "#if 0", and expanded exp2().
- added new error codes.
- improved looks of the block options
- renamed to "token" from "opaque_bytes" according to new draft.


From me: Use a use a left shift operation instead of multiplying by 2 many
times.

svn path=/trunk/; revision=34878
2010-11-15 18:01:19 +00:00
Jeff Morriss 58da72c54e Fix the randpkt assertion reported in https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5348 :
Always pass a length of 1 to proto_tree_add_item() for the ctype (this fixes
the assertion).  If the length indicated in the message is not 1, add an
expert info.

svn path=/trunk/; revision=34710
2010-10-30 12:48:29 +00:00
Jeff Morriss 450be02fc2 From Shoichi Sakane via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5270 :
Update to use add the time as a filterable field and other cosmetic changes.

From me: exp2() seems to be C99 so #if the use of it out.

svn path=/trunk/; revision=34611
2010-10-21 22:41:39 +00:00
Jeff Morriss 5c18160006 From Shoichi Sakane via bug 5270: minor changes and remove an unused hf variable.
svn path=/trunk/; revision=34600
2010-10-21 03:04:15 +00:00
Jeff Morriss f6a88f2be5 From Shoichi Sakane via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5270 :
I made a patch to support more COAP options.
some options includes variable length field.

svn path=/trunk/; revision=34592
2010-10-20 20:40:53 +00:00
Jeff Morriss a3bf744a0f From Shoichi Sakane via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5270 :
Remove some unused hf variables.

svn path=/trunk/; revision=34568
2010-10-19 13:30:40 +00:00
Stig Bjørlykke 1f2b9eca16 Init ett_coap_noop, another fix for bug 5305.
svn path=/trunk/; revision=34566
2010-10-19 06:58:08 +00:00
Bill Meier 8832221ca4 Remove some unneeded #includes ...
svn path=/trunk/; revision=34560
2010-10-18 17:46:12 +00:00
Stig Bjørlykke 7e42c00c9c Added some length checks for integers.
This fixes bug 5305.

svn path=/trunk/; revision=34550
2010-10-18 07:13:45 +00:00
Stig Bjørlykke ce60782e08 coap_handle is only used in proto_reg_handoff_coap.
svn path=/trunk/; revision=34532
2010-10-17 12:20:25 +00:00
Stig Bjørlykke 9d253d77ad From Shoichi Sakane via bug 5270:
Added COAP protocol support.

From me:
Made the port number configurable.

svn path=/trunk/; revision=34530
2010-10-17 11:48:40 +00:00