You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
compat and diff don't see a dependency's encoding declarations #206
inspect and the validator read encoding declarations from a package and its dependencies, through Encodings::of. compat and diff read only the package's own config, so they can get a dependency's framing wrong.
Visible case: a protocol uses a framing declared by a dependency, the framing states payload: json, and the package sets no wire.format.
comline inspect reports json@1, which is correct.
encodings_in_play in compat.rs and WireFacts::of in schema/ir/diff.rs call default_format with only the package's own declarations, so they read packed@1.
WireFacts then applies packed@1's rules, which are the strictest, so a change can be reported as more breaking than it is. It shouldn't under-report here. compat's facts name the wrong format, though.
Also: the declared lookup in encodings_in_play finds a profile hash only in the package's own config, so a dependency's encoding gets none there. That predates #205.
Likely fix: carry dependency configs in compat's Loaded and in WireFacts::of's inputs, and build a complete Encodings as inspect does. WireFacts::of has several callers (compat.rs, doc.rs, package/build/cas/build.rs), and old versions' stored configs need checking for whether their dependencies' configs are available.
This is a safety gap, not only a wrong report. Under the fail-closed rule in ComlineProject/docs#162, nothing may judge a guarantee with less than the full picture. Tracked by the audit in #225 (part of #219).
The #225 audit confirmed this issue on 35ab4b8: with a framing declared by a dependency that states payload: json, inspect reports json@1 and compat's facts report packed@1. Other places with the same partial view: compat.rs around line 299, cas/build.rs around line 192, and doc.rs around line 426 (changelog).
A laxer case from the same missing input:declared in encodings_in_play (compat.rs, around line 898) looks for a profile hash only in the package's own config. So a framing, format or handshake that a dependency declares gets no profile param. If the dependency changes that profile under the same name, param_hash stays equal, and peers and compat see "same encoding". This under-reports a change, so I'm labelling this issue security.
The fix described above covers both: carry dependency configs (a complete Encodings) into Loaded, encodings_in_play and WireFacts::of. History needs #251.
Activity
Kinflou commentedon Nov 9, 2026
This is a safety gap, not only a wrong report. Under the fail-closed rule in ComlineProject/docs#162, nothing may judge a guarantee with less than the full picture. Tracked by the audit in #225 (part of #219).
Kinflou commentedon Nov 11, 2026
The #225 audit confirmed this issue on
35ab4b8: with a framing declared by a dependency that statespayload: json,inspectreportsjson@1and compat's facts reportpacked@1. Other places with the same partial view:compat.rsaround line 299,cas/build.rsaround line 192, anddoc.rsaround line 426 (changelog).A laxer case from the same missing input:
declaredinencodings_in_play(compat.rs, around line 898) looks for a profile hash only in the package's own config. So a framing, format or handshake that a dependency declares gets noprofileparam. If the dependency changes that profile under the same name,param_hashstays equal, and peers and compat see "same encoding". This under-reports a change, so I'm labelling this issuesecurity.The fix described above covers both: carry dependency configs (a complete
Encodings) intoLoaded,encodings_in_playandWireFacts::of. History needs #251.compat, diff and the CAS see a dependency's encoding declarations (#206…