-
Notifications
You must be signed in to change notification settings - Fork 715
#1754 Add Modbus Support #1823
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: dev
Are you sure you want to change the base?
#1754 Add Modbus Support #1823
Conversation
yahyayozo
commented
May 18, 2025
- Add ModbusLayer first implementation with header parsing only (no test included)
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## dev #1823 +/- ##
==========================================
+ Coverage 82.96% 83.00% +0.03%
==========================================
Files 285 288 +3
Lines 49063 49173 +110
Branches 10599 10607 +8
==========================================
+ Hits 40707 40815 +108
- Misses 7196 7234 +38
+ Partials 1160 1124 -36
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
@seladb I've prepared only 1 constructor which initiates the layer with default fields values |
@yahyayozo we usually have at least 2 c'tors, sometimes more:
|
…sPlus into feature/modbus
Hi @seladb can you please guide me briefly on how to add tests for my ModbusLayer for parsing/crafting headers? As I want to pass to function types request/response after testing the header part. |
@yahyayozo sure! You can learn about tests here: https://pcapplusplus.github.io/docs/tests At a high level:
Please look at similar tests that were written for other layers and follow the same patterns. Please let me know if you have any questions. |
@seladb I'll add tests for the headers crafting/parsing implementation and then you can a review before we move to adding the different PDU types |
… instead of raw data
@yahyayozo CI fails, can you please look into it? 🙁 |
|
@seladb I'll check further |
@seladb all the pre-commit checks have passed + the build was successful |
… transaction ID, unit ID, and function code
…sPlus into feature/modbus
@seladb CI passed! can you please make a review of the already done work before moving forward? |