Commit Graph

3055 Commits

Author SHA1 Message Date
Steve Karg 58a6373ffb Update release.yml (#472)
fix tag name from releases
2023-08-21 08:56:24 -05:00
Steve Karg ac9b99d46c Update change log for v1.1.2 2023-08-18 15:20:24 -05:00
Steve Karg 8a4d530caf Incremented version to 1.1.2 for release on 18-Aug-2023 2023-08-18 15:20:14 -05:00
Steve Karg a7012fbd12 Feature/add release script (#471)
* add release script

* updated changelog

---------

Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-08-18 14:59:01 -05:00
Steve Karg 2a15a451d0 improve router-mstp app usage (#470)
* improve router-mstp app usage

* add router-mstp app environment shell script

---------

Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-08-15 11:24:22 -05:00
Steve Karg 2b35883df6 Added MSTP Slave Node option to stm32f10x port (#467)
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-08-07 09:45:30 -05:00
anthony-crystalpeak acb3b0f57d [libbacnet]: bacapp_data_len() + bacnet_tag_number_and_value_decode() (#453)
* Bugfix: bacapp_data_len() + bacnet_tag_number_and_value_decode()

* Fix bacnet_tag_number_and_value_decode function.
Add read buffer safe functions for opening, closing, context specific tags.
Fix bacapp_data_len function changes as indicated by unit testing.

* refactor bacapp_data_len
---------
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-07-31 16:50:14 -05:00
Mateusz Klatecki 28de333b6e Fix encode_context_bacnet_address (#464)
the original solution caused that after encode_bacnet_address the apdu pointer was moved too far because apdu_len took into account the length of the opening_tag
2023-07-31 11:24:25 -05:00
Greg Shue dad9e13485 Issues/issue 461 update to zephyr v3 4 0 in ci (#463)
* [WIP] Remove unit testcases duplicated under non-unit tree

* [WIP] Update west.yml to Zephyr v3.3.0 (twister verified)

* Update CI to Zephyr v3.4.0 w/ reduced module set

- Update zephyr/module.yml to use Zephyr v3.4.0 + cmsis;
- Update tests to use ZTEST_NEW_API for zephyr builds

Verified by:

1. make clean test
2. ./zephyr/scripts/twister -p unit_testing -T bacnet/zephyr/tests/bacnet

---------

Co-authored-by: Gregory Shue <gregory.shue@legrand.com>
2023-07-26 14:47:01 -07:00
Greg Shue 3f7a4d2e19 Trim west.yml imported repository set (#460) (#462)
Verified by:

1. cd $workspace && \
   rm -rf modules/ && \
   west update && \
   zephyr/scripts/twister -p unit_testing \
      -T bacnet-stack/zephyr/tests/

   Visually verified all tests passed.

Signed-off-by: Greg Shue <greg.shue@outlook.com>
2023-07-24 20:36:03 -05:00
Steve Karg 077be0005f Fix spurious interrupts from STM32 ORE (#456)
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-07-17 13:49:59 -05:00
Steve Karg 7db03ac5e5 Fix spurious interrupts from STM32 ORE (#456)
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-07-17 13:49:40 -05:00
anthony-crystalpeak fcc9647983 AFL + Libfuzzer harnesses (#455)
* Package fuzzers

* Provide ability to remove main

* Don't build fuzzers by default
2023-07-17 10:06:32 -05:00
Steve Karg 9e7f8978fa fix router apps action for unknown dnet (#454)
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-07-13 16:52:30 -05:00
anthony-crystalpeak da4db7c65e BUG: Prevent npdu_len from wrapping around at npdu_len=1 (#452) 2023-07-13 14:44:48 -05:00
anthony-crystalpeak 758cac3bed DOS: port might be null (#451) 2023-07-13 14:12:38 -05:00
Steve Karg 2bf1e9a548 Bugfix/writeproperty app known property (#450)
* Fix write-property app known property option

* Fix write-property app priority handling

---------

Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-07-13 10:21:21 -05:00
Steve Karg 4efaf097c0 Fix [bug#80] npdu_decode via deprecation (#447)
* Fix [bug#80] npdu_decode via deprecation

---------

Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-07-10 17:27:10 -05:00
Steve Karg 13c85db4cb Fix [bug#79] Out of bounds jump in h_apdu.c:apdu_handler (#446)
* Fix [bug#79] Out of bounds jump in h_apdu.c:apdu_handler
---------
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-07-10 15:15:55 -05:00
Steve Karg 1cfe6ee80f update change log 2023-07-08 09:49:43 -05:00
Jefrin da8f93ad79 Fix segfault on mstp cleanup on linux port (#445) 2023-07-08 09:47:50 -05:00
Steve Karg 7bac8aa0bd Add bitstring to minimal config (#443)
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-07-08 09:14:23 -05:00
Steve Karg dbed4040ae Improve MSTP debug. Fix WhoIs app APDU timeout. (#444)
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-07-08 09:13:56 -05:00
Steve Karg 95174ce96e added changelog. updated security statement. 2023-07-02 09:43:01 -05:00
Steve Karg d9d61b4ba7 Merge remote-tracking branch 'origin/master' into bacnet-stack-1.1 2023-06-30 17:49:05 -05:00
Steve Karg cfe3086ae5 increment version to 1.1.1 for release on 30-June-2023 2023-06-30 17:09:02 -05:00
Steve Karg b676f09c4b Merge branch 'master' 2023-06-30 17:04:23 -05:00
Steve Karg a9c2474534 Fix BACnetARRAY encoder for index=ALL (#442)
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-06-30 15:39:15 -05:00
Steve Karg 5b7eac60cf cleaned up lwIP function header javadoc (#441)
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-06-28 12:46:56 -05:00
Steve Karg db21bf1bfa Increment version to 1.1.0 for release 2023-06-25 09:32:15 -05:00
Steve Karg a4750b8999 Increment version to 1.1.0 for release 2023-06-25 09:31:07 -05:00
Steve Karg 9bb367982b Improve MSTP debug. Fix WhoIs app APDU timeout. 2023-06-25 09:27:05 -05:00
Steve Karg c8a6ea74b8 Fix WPM decoding. Add unit test for WPM. (#438)
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-06-14 17:25:38 -05:00
Steve Karg 2c771414bd fix BACnet Array size encoding (#437)
* fix BACnet Array size encoding

* test BACnet Array size encoding

---------

Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-06-14 17:13:52 -05:00
Steve Karg 6e5524bee3 Create SECURITY.md 2023-05-30 14:34:04 -05:00
Steve Karg 5e0f7b79ef Fix potential XSS vulnerability in jQuery #1 (#436)
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-05-30 14:24:47 -05:00
Steve Karg 682d913686 fix compiler warnings for C89 builds (#433)
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-05-22 08:49:17 -05:00
Ondřej Hruška dab95eec3f Implement parsing for proprietary events (complex-event-type) (#420)
* Implement parsing for proprietary events (complex-event-type)

* Fix unit test linking for event.c
---------

Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-05-16 23:55:55 -05:00
Steve Karg c02a8281a7 Cleanup win32 build warnings (#431)
* Cleanup win32 build warnings

* Add README for MinGW32 build under Windows

---------

Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-05-13 15:13:15 -05:00
Steve Karg f59a460292 Fixed array index out of range for binary-value, multistate-output, and lighting-output objects. Thanks, Roy! (#430)
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-05-09 15:58:28 -05:00
Steve Karg 65792ab408 Update address in VMAC table for IPv6 (#429)
* Update address in VMAC table for IPv6

* fix compile warnings in IPv6 handler

* cleanup BIP6 PRINTF

* enable unit test for BBMD6 hander

* keylist should only return FALSE when growing fails

---------

Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-05-03 23:33:06 -05:00
Steve Karg ced9dff0f2 Added AddListElement and RemoveListElement services (#418)
* Added AddListElement and RemoveListElement services

Added list-element codec and unit tests.
Added BACnetDestination codec and unit tests.
Added RecipientList handling to NotificationClass object.
Added AddListElement and RemoveListElement client example app.

* Fix defects found by scan-build and CPPCHECK

* Update ports errors found during CI builds

* Update zephy os test build missing files in CMakeLists

---------

Co-authored-by: Ondřej Hruška <ondra@ondrovo.com>
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-04-16 14:12:11 -05:00
Steve Karg e517df0d47 Bugfix/bacnet array encoding overflows (#414)
* Add common BACnetARRAY encode function to fix Device object list buffer overflow. Refactor device, analog-output, access-door and binary-output objects to use common BACnetARRAY encoder.

* Fix non-POSIX builds (win32).

* Cleanup some ports/stm32 build warnings
---------

Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-04-13 20:43:54 -05:00
jci-zimm 064c6f7f1c MSTP stat lost_token_counter was missing a drop case (#421)
Co-authored-by: jzimmen_jcplc <nathan.m.zimmerman@jci.com>
2023-04-13 20:36:22 -05:00
dependabot[bot] 8bea1a33a8 Bump actions/checkout from 2 to 3 (#402)
Bumps [actions/checkout](https://github.com/actions/checkout) from 2 to 3.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2...v3)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-03-07 17:02:11 -06:00
Greg Shue c74a8cf3a9 Feature/bacnet bacerror unit tests (#407)
* Add <zephyr/fff.h> from zephyr v3.1.0

Zephyr is deprecating the zmock library in favor of using
the FFF faking library for defining and controlling fake
implementations of depended-upon APIs called by the code-under-test.

Signed-off-by: Gregory Shue <gregory.shue@legrand.com>

* Fix bacerror_decode_service_request return value; add unit tests

bacerror_decode_service_request() return value now includes
the apdu bytes parsed for invoke_id and service.

Also added a unit test for functions in bacerror.c, using `fff`
for faking the depended-upon functions.

Verified by:

1. (Pass) cd $bacnet-stack/test && make test

2. (Pass) west build -p always -b unit_testing \
              bacnet-stack/zephyr/tests/unit/bacnet/bacerror/ && \
              ./build/testbinary

3. (Pass) ./zephyr/scripts/twister -p unit_testing  \
              -T bacnet-stack/zephyr/tests/unit/bacnet/bacerror/

Signed-off-by: Gregory Shue <gregory.shue@legrand.com>

---------

Signed-off-by: Gregory Shue <gregory.shue@legrand.com>
Co-authored-by: Gregory Shue <gregory.shue@legrand.com>
2023-03-07 17:01:33 -06:00
Greg Shue fe69978387 Add <zephyr/fff.h> from zephyr v3.1.0 (#406)
Zephyr is deprecating the zmock library in favor of using
the FFF faking library for defining and controlling fake
implementations of depended-upon APIs called by the code-under-test.

Signed-off-by: Gregory Shue <gregory.shue@legrand.com>
Co-authored-by: Gregory Shue <gregory.shue@legrand.com>
2023-03-07 16:42:25 -06:00
Steve Karg 261a506eb4 refactor mstimer callback handling (#400)
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-02-18 10:02:13 -06:00
Steve Karg 343d9f893d Fix and extend BACnetReliability per 135-2020 (#399)
Fix member-fault and tripped values.
Extend BACnetReliability to include:
monitored-object-fault (14),
tripped (15),
lamp-failure (16),
activation-failure (17),
renew-dhcp-failure (18),
renew-fd-registration-failure (19),
restart-auto-negotiation-failure (20),
restart-failure (21),
proprietary-command-failure (22),
faults-listed (23),
referenced-object-fault (24),
multi-state-out-of-range (25),

Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-02-17 08:24:48 -06:00
Steve Karg e95aed9b93 Added UTC option to BACnet TimeSync app (#396)
Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
2023-02-08 13:12:44 -06:00