Skip to content

Reject unsupported exceptions in configured RTU read checks - #5

Merged
KaiserIIII merged 1 commit into
mainfrom
codex/modbus-rtu-exception-20261016
Oct 16, 2026
Merged

KaiserIIII merged 1 commit into
mainfrom
codex/modbus-rtu-exception-20261016

Conversation

@KaiserIIII

Copy link
Copy Markdown
Owner

Configured Modbus RTU reads with accept_exception: true could report success for a CRC-correct response carrying an unsupported exception byte, including 00 or FF. Validate that byte against the existing exception-code contract before applying the acceptance flag, retain the captured frame and explain the rejection. Defined exceptions keep their existing policy and messages; serial settings, read-only requests, transport code and any/all control flow are unchanged.

Validation: 421 local tests passed, including 35 new regressions that initially produced 11 failures. Tests exercise the real parser and configured caller with Fake serial, plus CRC, identity, truncation and defined-code controls. A separate zero-third-party replay checked all 4,096 code/function/target/flag combinations, 144 unchanged defined-exception results, 24 ordinary read results and 1,976 unchanged request encodings. Configuration validation and all 23 offline self-checks passed.

Implementation, tests and documentation are AI-assisted. No physical serial device was opened. Broad local coverage is 2,006/3,693 lines (54.32%) and 635/1,456 branches (43.61%); this correction is not hardware or full-service security certification. Independent review and remote CI are checked before integration.

@KaiserIIII
KaiserIIII merged commit 9d9cfa9 into main Oct 16, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant