Location: j1939/pgn_test.go:24-61 (TestDecodeEncodeRoundTrip, TestIsPeerToPeer)
Finding: The only PGN test cases in this file are 0x0FECA, 0x00E800, and 0x0FF00 — all DP=0. No test constructs or checks a DP=1 PGN. Worse, the sole encode/decode test is a pure round-trip (EncodeID output fed straight into DecodeID), so a shared, symmetric bug in both directions — exactly what the DP-bit-placement issue is — passes cleanly even though the externally-visible PGN value is wrong. There's no test that asserts a fixed, independently-known-correct 29-bit CAN ID against a hand-computed golden value for a given (priority, PGN, src) tuple.
Recommendation: Add golden-value test vectors — including at least one DP=1 PGN — that check EncodeID against a hand-computed 29-bit ID and DecodeID against a hand-computed PGN, independent of each other, so the two directions can't mask a shared defect.
Filed from the 2026-07-29 ecosystem audit register; independently re-verified against current HEAD before filing.
Location:
j1939/pgn_test.go:24-61(TestDecodeEncodeRoundTrip,TestIsPeerToPeer)Finding: The only PGN test cases in this file are 0x0FECA, 0x00E800, and 0x0FF00 — all DP=0. No test constructs or checks a DP=1 PGN. Worse, the sole encode/decode test is a pure round-trip (
EncodeIDoutput fed straight intoDecodeID), so a shared, symmetric bug in both directions — exactly what the DP-bit-placement issue is — passes cleanly even though the externally-visible PGN value is wrong. There's no test that asserts a fixed, independently-known-correct 29-bit CAN ID against a hand-computed golden value for a given (priority, PGN, src) tuple.Recommendation: Add golden-value test vectors — including at least one DP=1 PGN — that check
EncodeIDagainst a hand-computed 29-bit ID andDecodeIDagainst a hand-computed PGN, independent of each other, so the two directions can't mask a shared defect.Filed from the 2026-07-29 ecosystem audit register; independently re-verified against current HEAD before filing.