Skip to content

Reject the Unicode noncharacters, and record suiteRevision 6 at 153/153 - #4

Merged
Rul1an merged 2 commits into
mainfrom
reject-noncharacters
Jul 28, 2026
Merged

Reject the Unicode noncharacters, and record suiteRevision 6 at 153/153#4
Rul1an merged 2 commits into
mainfrom
reject-noncharacters

Conversation

@Rul1an

@Rul1an Rul1an commented Jul 28, 2026

Copy link
Copy Markdown
Owner

suiteRevision 6 adds four vectors. Two are the depth-boundary pair, ok-036 and bad-742, and the container-branch counter from #3 already handled both. The other two, bad-743 and bad-744, carry Unicode noncharacters in a vocabulary label and in a payload value, and this checker admitted them. The unchanged revision-5 build scored 151/153; this branch scores 153/153 (36/36 accepts, 117/117 rejects).

Why it admitted them

Not an oversight, which is worth recording. The earlier text scoped its MUST to string literals being well-formed sequences of Unicode scalar values, and a noncharacter is a scalar value, so the narrower rule was implemented faithfully. The revision changes the rule rather than the reading: the strict-I-JSON label above that MUST had always implied the wider RFC 7493 section 2.1 exclusion, and revision 6 closes the gap between the label and the rule underneath it.

The fix

The sixty-six code points are U+FDD0 through U+FDEF plus U+nFFFE and U+nFFFF in each of the seventeen planes. Both routes into a string body are covered, because the exclusion is over code points and a producer reaches them either way: the raw UTF-8 byte, and the escape, including a surrogate pair resolving into a plane-end noncharacter. The plane-end pairs differ only in their lowest bit, so one mask covers all thirty-four, and a test walks the entire code space to confirm the predicate selects exactly sixty-six and no more.

This run is directed, and the record says so

More so than revision 2 was: the rule was written and the vectors were named before this checker ran. What it demonstrates is that the corrected rule is implementable from the text, not that an independent reader found something. The blind evidence remains where it was, at 125/125 on revision 1 with no vector-driven fixes, and 140/140 first-run unchanged at revision 3.

Verification

  • 153/153 against astrogilda/aee-conformance@7098f4e, with exactly two verdicts moved from the revision-5 build, bad-743 and bad-744, comparing all per-vector fields.
  • No regression: the fixed build still reproduces reports/suite-revision-5.json exactly against suite ea25a1e.
  • Revision 5 is retired from continuous verification and keeps its checkerCommit (88c37d1), so its provenance stays checkable after the pin moves.
  • The workflow moves with the pin, including the parity string the corpus step greps for.

Refs in-toto/attestation#570.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • New Features

    • Added validation that rejects Unicode noncharacters in JSON input, whether provided as literal characters or escaped sequences.
    • Added comprehensive conformance coverage for the new Unicode validation rules.
  • Documentation

    • Updated conformance documentation and reproducible-run instructions to reflect suite revision 6.
    • Published updated parity results, including 153 passing conformance checks.
  • Tests

    • Added coverage confirming all 66 Unicode noncharacters are detected consistently.

Rul1an and others added 2 commits July 28, 2026 22:21
suiteRevision 6 makes the RFC 7493 section 2.1 exclusion normative: the sixty-six
noncharacters, U+FDD0 through U+FDEF and U+nFFFE and U+nFFFF in each of the
seventeen planes, are malformed wherever a string literal appears, at any depth
and in member-name as well as value position.

This checker admitted them, and the reason is worth recording because it was not
an oversight. The earlier text scoped its MUST to string literals being
well-formed sequences of Unicode scalar values, and a noncharacter is a scalar
value, so the narrower rule was implemented faithfully. What the revision changes
is the rule, not the reading: the strict-I-JSON label above that MUST had always
implied the wider RFC 7493 exclusion, and the revision closes the gap between the
label and the rule underneath it.

Both routes into a string body are covered, because the exclusion is over code
points and a producer reaches them either way: the raw UTF-8 byte, and the escape
including a surrogate pair resolving into a plane-end noncharacter. The plane-end
pairs differ only in their lowest bit, so one mask covers all thirty-four, and a
test walks the whole code space to confirm the predicate selects exactly sixty-six.

Refs in-toto/attestation#570.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The unchanged revision-5 checker scored 151/153. The depth-boundary pair ok-036
and bad-742 passed on the container-branch counter already in place; bad-743 and
bad-744 did not, and those two are what the previous commit fixes.

The record says plainly that this run is directed, and more so than revision 2
was: the rule was written and the vectors named before this checker ran, so what
it shows is that the corrected rule is implementable from the text, not that an
outside reader found something. Revision 5 is retired from continuous
verification and keeps its checkerCommit, 88c37d1, so its provenance stays
checkable after the pin moves. The workflow follows: suite pin, spec pin, the
compared report, and the parity string the corpus step greps for.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings July 28, 2026 20:22

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@coderabbitai

coderabbitai Bot commented Jul 28, 2026

Copy link
Copy Markdown

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 253bc7a1-977e-4913-8a0b-a14a1ad1e8b3

📥 Commits

Reviewing files that changed from the base of the PR and between 88c37d1 and 6112033.

📒 Files selected for processing (6)
  • .github/workflows/conformance.yml
  • NOTES.md
  • README.md
  • reports/INDEX.json
  • reports/suite-revision-6.json
  • src/json.rs

📝 Walkthrough

Walkthrough

JSON parsing now rejects Unicode noncharacters from raw UTF-8 and escaped inputs. Conformance metadata, reports, CI pins, parity requirements, and reproducibility documentation are updated for suite revision 6.

Changes

Unicode validation and conformance evidence

Layer / File(s) Summary
Unicode noncharacter parsing validation
src/json.rs
Escaped and raw Unicode scalars are validated against the noncharacter set, with exported detection logic and tests.
Suite revision 6 evidence
reports/suite-revision-6.json, reports/INDEX.json
Adds revision 6 vector results and marks revision 5 as no longer continuously verified.
Revision 6 pins and reproducibility
.github/workflows/conformance.yml, NOTES.md, README.md
Updates suite pins, digest checks, 153/153 parity assertions, report comparison, and reproducible-run documentation.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Sequence Diagram(s)

sequenceDiagram
  participant JSONInput
  participant parse_string
  participant push_scalar
  participant is_noncharacter
  JSONInput->>parse_string: provide escaped or raw string
  parse_string->>push_scalar: pass decoded scalar
  push_scalar->>is_noncharacter: check scalar membership
  is_noncharacter-->>push_scalar: return classification
  push_scalar-->>parse_string: append or reject scalar
Loading

Suggested reviewers: copilot

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch reject-noncharacters

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@Rul1an
Rul1an merged commit f8bd3a7 into main Jul 28, 2026
2 of 3 checks passed
@Rul1an
Rul1an deleted the reject-noncharacters branch July 28, 2026 20:23
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.

2 participants