Commit Graph

120 Commits

Author SHA1 Message Date
Anders Broman 4a5c674c04 From Dave Richards
1) Fixes context-tagged BACnet errors.
2) Fixes indeterminate tag data.  If the tag length/value/type variable 
was 6 or 7 you could not tell whether it was an open/close tag or had 
length 6/7.
3) Don't make assumptions about property types for proprietary BACnet 
object types.



svn path=/trunk/; revision=16104
2005-10-04 05:15:23 +00:00
Anders Broman ad5fab657d From Steve Karg
svn path=/trunk/; revision=15666
2005-09-02 05:49:25 +00:00
Ronnie Sahlberg ec3ab9ec3e rename ep_tvb_get_string() to tvb_get_ephemeral_string() asnd update the documentation in README.developer
svn path=/trunk/; revision=15270
2005-08-10 13:41:13 +00:00
Anders Broman e6856b69f3 From David Richards:
here are the highlights of what's fixed:

1) Decoding of vendor-defined types
2) Decoding of some event notification parameters (not all)
3) Decoding of ABSTRACT-SYNTAX&Type
4) Decoding of BACnetTimeStamp
5) Some problems with context-tagged values (like booleans)
6) Continuation segments - don't try to decode them since you can't 
start mid-PDU
7) Removed some excessive levels of subtrees

svn path=/trunk/; revision=15226
2005-08-05 19:37:57 +00:00
Jörg Mayer 34493e8f9e char -> const char warning fixes
svn path=/trunk/; revision=15126
2005-07-28 07:53:38 +00:00
Ronnie Sahlberg 835df3a1d2 convert some uses of tvb_get_string() to ep_tvb_get_string()
there was at least one obvious memleak in one of the uses of tvb_get_string()



svn path=/trunk/; revision=15027
2005-07-24 02:43:41 +00:00
Jörg Mayer 19e90d9a5c Warning fix:
packet-bacapp.c:1264: warning: ISO C does not allow extra ';' outside of
a function


svn path=/trunk/; revision=14420
2005-05-23 12:32:37 +00:00
Jörg Mayer 83f9a803ac Warning fix:
packet-bacapp.c:1266:1: warning: C++ style comments are not allowed in ISO C90
packet-bacapp.c:1266:1: warning: (this will be reported only once per input file)


svn path=/trunk/; revision=14418
2005-05-23 12:18:10 +00:00
Anders Broman 33aa290b25 From Steve Karg:
* added additional value string enumerations from BACnet-2004
* removed vendor specific value string enumerations
* corrected some value strings enumerations that were incorrect
* refactored some common strings as strings + format
* refactored some value strings to use a reserved range and a 
proprietary range by using val_to_split_str function which now correctly 
shows the split range when a value is not matched.
* corrected some spelling errors
* converted some item text values to dissector registration
* added protocol tree for the BACnet tag headers
* added value strings tree display for some bit string BACnet properties
* added value strings tree display for some enumerated BACnet properties
* changed the conversion of signed, unsigned, and enumerated BACnet 
values to use ntohx functions.
* added proper handling for large values of signed, unsigned, and 
enumerated BACnet values.
* refactored BACnet Null and Boolean Tag tree
* refactored BACnet Real and Double Tag tree
* changed comments into functions for special tags
* changed some white space to match existing file style
* refactored tvb_reported_length to tvb_length_remaining to simplify
* corrected octet-string tree when length is zero
* refactored octet-string tree to use tvb_bytes_to_str
* corrected application tagged productions that were context tagged
* corrected context tagged productions that were application tagged
* corrected offset for BACnet character strings
* refactored some identical service request tree handling
* changed confirmed APDU to highlight the correct portion of the APDU
* changed some dissector registration values to display as decimal
* changed cast in call to iconv() to fix compiler warning
* corrected bit-wise AND in AtomicFile tree handling

packet-bvlc.c
* added error text in tree when encoded length doesn't match actual length

svn path=/trunk/; revision=14417
2005-05-23 05:52:28 +00:00
Guy Harris 25443a7a87 Change data types to match those of "iconv()", at least on OS X.
svn path=/trunk/; revision=14314
2005-05-05 11:03:46 +00:00
Gerald Combs 2e0f4b9750 Fix a couple of infinite loops. Make similar changes elsewhere to keep the
code consistent.

svn path=/trunk/; revision=14260
2005-05-02 00:57:44 +00:00
Ronnie Sahlberg 0f66df8509 BACAPP updates
svn path=/trunk/; revision=14188
2005-04-26 08:03:22 +00:00
Ronnie Sahlberg a5863ec066 From Steve Karg
updates to BACNet


svn path=/trunk/; revision=14075
2005-04-14 09:20:02 +00:00
Guy Harris ab32b090b7 Back out the BACnet application layer dissectin code - its use of
recursion instead of iteration means that packets with sufficiently
large lists can cause it to overflow the stack and crash.

svn path=/trunk/; revision=13643
2005-03-07 01:22:55 +00:00
Guy Harris 722832f739 The length field in the "BACnet encoding rules" is limited to 32 bits
("Data lengths larger than 2^32-1 are not encodable using primitive
tags"), so it doesn't need to be a "guint64" - but it *can* be that big,
so we should handle the 65536-2^32-1 case.

Don't gratuitously throw away the upper 24 bits of various lengths by
casting them to guint8.

Show signed values as such.

Don't use "match_strval()" - it returns a null pointer if it doesn't
find the value in the value_string table; instead, use "val_to_str()" so
we don't blow up if the value isn't found.

svn path=/trunk/; revision=13640
2005-03-06 22:14:24 +00:00
Guy Harris a313c47a59 Get rid of an unused variable.
svn path=/trunk/; revision=13621
2005-03-06 04:41:00 +00:00
Guy Harris 39ad72864f No, they don't use BER for the variable portion of a PDU; update the
comment appropriately.

Make a bunch of routines static.

Don't just dissect stuff past the end of the variable portion as data -
the protocol spec doesn't appear to say there's anything after that.

Don't pass the offset to the routines to dissect the different types of
PDUs, just have them start at 0.

Use guint8 for 8-bit unsigned quantities.

Rename the routine to dissect Abort PDUs to match the other PDU
dissectors.

svn path=/trunk/; revision=13611
2005-03-06 02:24:49 +00:00
Guy Harris 476c8da086 Don't use "long" and "%l[doux]" for 64-bit quantities, use guint64 and %
followed by PRIu64.

Don't use C++/C99-style comments.

Use "tvb_reported_length()" to get packet lengths - don't use
"tvb_length()", and especially don't directly refer to the "length"
field of the tvbuff.

svn path=/trunk/; revision=13609
2005-03-06 01:53:56 +00:00
Guy Harris ea23bf66f9 From Herbert Lischka: implement some (not all) tags according to BACNET
application handbook.

svn path=/trunk/; revision=13605
2005-03-06 00:17:37 +00:00
Gilbert Ramirez 669db206cb Move dissectors to epan/dissectors directory.
Also move ncp222.py, x11-fields, process-x11-fields.pl,
make-reg-dotc, and make-reg-dotc.py.

Adjust #include lines in files that include packet-*.h
files.

svn path=/trunk/; revision=11410
2004-07-18 18:06:47 +00:00