Commit Graph
28 Commits
Author SHA1 Message Date
b0fe5ef8ba Initial commit of a fuzzer for Meshtastic (#5790)
* Initial commit of a fuzzer for Meshtastic.

* Use a max of 5 for the phone queues

* Only write files to the temp dir

* Limitless queue + fuzzer = lots of ram :)

* Use $PIO_ENV for path to program

* spelling: s/is/to/

* Use loopCanSleep instead of a lock in Router

* realHardware allows full use of a CPU core

* Ignore checkov CKV_DOCKER_2 & CKV_DOCKER_3

* Add Atak seed

* Fix lint issues in build.sh

* Use exception to exit from portduino_main

* Separate build & source files into $WORK & $SRC

* Use an ephemeral port for the API server

* Include CXXFLAGS in the link step

* Read all shared libraries

* Use a separate work directory for each sanitizer

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-01-16 18:42:21 -06:00
Eric SeveranceandGitHub 124936b6cf Avoid a potential NULL pointer reference in nrf52/BluetoothPhoneAPI (#5830) 2025-01-12 12:05:04 -06:00
Eric SeveranceandGitHub 0fe8d4ccc7 Run the AddressSanitizer during tests (#5815)
* Run the AddressSanitizer during tests

* Show details for test failures
2025-01-12 13:51:43 +08:00
Eric SeveranceandGitHub 253ab458ef Add lsb-release on the github runner (#5825) 2025-01-11 22:29:24 -06:00
Eric SeveranceandGitHub b4a4d2db4e Cache Python & PlatformIO dependencies (#5822) 2025-01-11 19:40:39 -06:00
Eric SeveranceandGitHub e7802d960f Manage when destructor is called for native HttpAPI (#5807) 2025-01-11 06:15:50 -06:00
Eric SeveranceandGitHub 1d756ae574 Fix potential memory leak in AtakPluginModule (#5803) 2025-01-10 08:25:25 +08:00
Eric SeveranceandGitHub 27fbfd03d6 Add unit tests for MQTT (#5724)
* Add unit tests for MQTT

* Test received fields
2025-01-07 07:10:42 -06:00
Eric SeveranceandGitHub b41efc17ba Disable BUILD_EPOCH for unit tests (#5723) 2025-01-02 10:32:38 -06:00
Eric SeveranceandGitHub 9f7cbf1b4f MQTT unit test can inject WiFiClient (#5716) 2025-01-02 19:32:39 +08:00
Eric SeveranceandGitHub 93e2bc7058 Use relative paths in coverage info files (#5721) 2025-01-02 14:53:07 +08:00
Eric SeveranceandGitHub 7a1c32b89a test_native.yaml checks out code for the PR. (#5720) 2025-01-02 12:41:13 +08:00
Eric SeveranceandGitHub 88d8ab53c8 Disable coverage generation (#5719)
* Disable coverage generation

* Comment a bit more of the report generation
2025-01-02 11:37:11 +08:00
Eric SeveranceandGitHub 183f68ba00 Run tests as part of the main CI (#5712)
* Create an shared action to install native dependecies

* Create a workflow for running native tests

* Artifact names contain version

* Add test-native to main_matrix.yml

* No permission are required for test_native.yml

* Add permissions for dorny/test-reporter

* No permissions when running tests

* s/Generate Reports/Generate Test Reports/
2025-01-01 19:26:12 -06:00
Eric SeveranceandGitHub 9f32995d7f Implement MeshModule destructor (#5714) 2025-01-01 19:25:01 -06:00
Eric SeveranceandGitHub c2c06ed0ad Move DecodedServiceEnvelope into its own file (#5715) 2025-01-02 08:40:14 +08:00
cc357df489 Include log messages in unit tests (#5666)
* Include log messages in unit tests

* Provide an initial time value

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-12-26 13:42:15 +11:00
Eric SeveranceandGitHub 1281da627e Generate a coverage report for End to end tests (#5667)
* Generate coverage report after running tests

* Wait for integration program to stop/start
2024-12-25 19:47:03 -06:00
Eric SeveranceandGitHub a7d9e8107a More accurately determine if MQTT uses the default server (#5663)
* More accurately determine if MQTT uses the default server

* Channels::anyMqttEnabled() uses same logic

* Remove previous static bool
2024-12-25 08:33:53 -06:00
Eric SeveranceandGitHub fbdd6e7223 Synchronize test workflow packages with native (#5664) 2024-12-25 16:31:35 +11:00
143e1d1a0d Check if MQTT remote IP is private (#5647)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-12-23 09:48:07 -06:00
Eric SeveranceandGitHub 2fd5a4848a Separate host:port before checking for private IP (x2) (#5643) 2024-12-21 14:07:20 -06:00
Eric SeveranceandGitHub 398d29064e Separate host/port before checking for private IP (#5630) 2024-12-21 14:06:01 +11:00
Eric SeveranceandGitHub 9a10907a2d Check if MQTT remote IP is private (#5627) 2024-12-20 19:25:31 -06:00
Eric SeveranceandGitHub 58d80b8557 Use IPAddress.fromString for parsing private IPs (#5621) 2024-12-21 11:21:27 +11:00
Eric SeveranceandGitHub 658459aaf3 Use encoded ServiceEnvelope in mqttQueue (#5619) 2024-12-20 14:59:23 -06:00
e1de439a7f Remove unnecessary memcpy for PKI crypto (#5608)
* Remove unnecessary memcpy for PKI crypto

* Update comment s/packet_id/id/

* Create a copy of bytes for each channel decrypt

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2024-12-19 19:14:27 -06:00
8c6eec52f2 Refactor MQTT::onReceive to reduce if/else nesting (#5592)
* Refactor MQTT::onReceive to reduce if/else nesting

* Fix missing #include <functional>

* const DecodedServiceEnvelope e

* Combine validDecode if statement.

* Only call pb_release when validDecode.

* s/ptr/channelName/

* Use reference type for deleter

* Use lambda instead of bind

* Document deleter

* Reorder 'if's to avoid object creation

* Remove unnecessary comment

* Remove 'else'; simpifies #5516

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-12-19 05:47:46 -06:00