Skip to content

fix(xchk-registry): reject private JWK members, non-canonical base64url, boolean Instant(now), and duplicate JSON keys (#378) - #383

Open
drk-ram wants to merge 1 commit into
agentrust-io:mainfrom
drk-ram:drk-ram-fix-xchk-378
Open

drk-ram wants to merge 1 commit into
agentrust-io:mainfrom
drk-ram:drk-ram-fix-xchk-378

Conversation

@drk-ram

@drk-ram drk-ram commented Oct 25, 2026

Copy link
Copy Markdown

Closes #378

Summary

  • Reject all RFC 7517/7518 private/symmetric JWK parameters ("d", "p", "q", "dp", "dq", "qi", "oth", "k") and enforce canonical unpadded 32-byte base64url in is_ed25519_jwk and canonical base64 in key_from_published.
  • Reject boolean or negative now in Instant.__init__.
  • Enforce duplicate-key and NaN/Infinity rejection in load_json and published_key.
  • Add unit tests in integrations/xchk-registry/tests/test_trust_record.py.

Validation

  • pytest integrations/xchk-registry/tests/test_trust_record.py -q — passed

…rl, boolean Instant(now), and duplicate JSON keys (agentrust-io#378)

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Signed-off-by: Raghuvar Durga <177662415+drk-ram@users.noreply.github.com>
@drk-ram
drk-ram requested review from a team, carloshvp and imran-siddique as code owners October 25, 2026 07:00
@github-actions

github-actions Bot commented Oct 25, 2026 •

Copy link
Copy Markdown
Contributor

🟡 Contributor Check: MEDIUM

Check Result
Profile MEDIUM
Credential LOW
Overall MEDIUM

Automated check by AgenTrust Contributor Check.

@github-actions github-actions Bot added the needs-review:MEDIUM Contributor check flagged MEDIUM risk label Oct 25, 2026

@carloshvp carloshvp left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed exact head 9de214b1b0976b2debd3b089a22c90a900601ce9 in an isolated checkout.

The registry consumer refuses private/symmetric JWK material, noncanonical key encodings, invalid explicit verification times and ambiguous local/published-key JSON. Its existing pinned-key trust boundary and historical-time reporting remain intact. All 27 offline tests pass; the live-registry test is intentionally skipped. The focused rejection control fails against the actual baseline module. pip check, repository CI Ruff and diff whitespace checks pass in the hash-locked environment. No live registry availability or new tier/conformance claim is made; hosted checks and maintainer policy remain separate.

Reviewed with OpenAI Codex.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-review:MEDIUM Contributor check flagged MEDIUM risk

Projects

None yet

2 participants