GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — id(world): sanitize_display_name / sanitize_chat filter Cc only — Cf format characters (U+202E, U+200B, bidi isolates) pass into participant names and broadcast chat, and a zero-width-only name passes the join empty check · Issue #2112 · developing-today/code

id(world): sanitize_display_name / sanitize_chat filter Cc only — Cf format characters (U+202E, U+200B, bidi isolates) pass into participant names and broadcast chat, and a zero-width-only name passes the join empty check #2112

New issue
Copy link
New issue
Copy link
Closed
#4084
Closed
id(world): sanitize_display_name / sanitize_chat filter Cc only — Cf format characters (U+202E, U+200B, bidi isolates) pass into participant names and broadcast chat, and a zero-width-only name passes the join empty check#2112
#4084
Copy link
Assignees
dezren39
Labels
app/idPackage/app: id (pkgs/ or apps/ in this repo)effort/sSmall: expected under 2 hours of workkind/bugSomething isn't working (prefixed form of the classic bug label)priority/normalOrdinary priority (the default)source/creatorFiled by the new-issue-creator jobtask/triageQueue packet kind: verify, reproduce, and route this item

Description

@dezren39
dezren39
opened on Oct 29, 2026
Issue body actions

Problem

The world runtime's two text sanitizers promise to strip control characters from participant display names and chat text, but they filter with char::is_control — Unicode category Cc only. Category-Cf format characters (U+200B ZERO WIDTH SPACE, U+202E RIGHT-TO-LEFT OVERRIDE, U+2066/U+2069 bidi isolates, U+2060 WORD JOINER, U+FEFF, U+00AD SOFT HYPHEN) pass both sanitizers untouched, so a participant can join with an invisible or bidi-reordering display name, and chat lines broadcast to every other participant can carry the same characters. A display name consisting solely of zero-width spaces also passes the join path's non-empty check, so a participant can be present under a literally invisible name.

This is the same Cf class as #1674 (petname), #1778 (directory) and #1770 (invite), but a different module and fix surface: none of those covers pkgs/id/src/world/util.rs or the world join/chat paths in world/core.rs. #1833 covers web/collab cursor names, a different subsystem.

Evidence (verified this run on main 42796be5)

  • sanitize_display_name (pkgs/id/src/world/util.rs:69-76): .filter(|ch| !ch.is_control()), then take(48), then trim. Rust's char::is_control is general category Cc only.
  • sanitize_chat (pkgs/id/src/world/util.rs:78-85): same filter (allowing \n/\t), then trim.
  • Call sites: join — world/core.rs:847 sanitizes the display name, core.rs:848-851 refuses only if the sanitized name is empty; chat — world/core.rs:955 (participant chat) and core.rs:578 (host/system chat) sanitize before the event is committed and broadcast.
  • Laptop probe (verbatim copies of both functions, main 42796be5, world/util.rs sha256 6c6cab01…; probe ~/git/fleet/probe-2026-10-28-laneB-worldcf/):
    • "Ann\u{202E}nimdA" → name and chat output unchanged (RLO survives).
    • "\u{200B}\u{200B}" (zero-width only) → output unchanged and non-empty, so the join empty-name refusal does not fire.
    • "Ann\u{200B}", "An\u{00AD}n", "\u{2060}\u{FEFF}Bo", chat "hi \u{2066}evil\u{2069}" and "pay \u{202E} 100" → all unchanged.
    • Control: Cc U+0007 is stripped from both ("A\u{0007}nn" → "Ann"), as documented.
    • is_control() returns false for U+200B, U+202E, U+2066, U+2060, U+FEFF and U+00AD.

Why it matters

Display names and chat are the identity other participants see inside a shared world. A RIGHT-TO-LEFT OVERRIDE in a name or chat line reorders the text around it for every viewer (the classic spoofing primitive), zero-width characters make two visually identical names distinct (or one name invisible), and bidi isolates can hide or fake quoted text. The sanitizers are the single choke point for both surfaces, so this is the layer where the Cf class has to be closed for worlds — the directory/petname fixes do not reach it.

Acceptance criteria

  • sanitize_display_name and sanitize_chat in pkgs/id/src/world/util.rs remove (or refuse, per a contract pinned in triage) the Cf characters U+200B, U+202E, U+2066–U+2069, U+2060, U+FEFF and U+00AD — consistent with whatever shared rule id(petname): format characters (Cf) bypass both petname guards — U+200B makes a spoof of another contact's name, U+202E passes the 'no control characters' rule #1674/id(directory): format characters (Cf) bypass clean_name/clean_description — U+202E and U+200B pass the 'no control characters' rule for account and group names #1778 settle on, if one exists by then.
  • A display name that is only Cf/whitespace sanitizes to empty, so the existing join refusal in world/core.rs fires for invisible names.
  • Chat text containing Cf reaches other participants without those characters; legitimate text (including \n/\t in chat, non-Latin scripts, emoji/ZWJ sequences if the pinned rule allows them — ZWJ U+200D is also Cf and the rule must say explicitly what happens to it) is otherwise unchanged.
  • Unit tests in world/util.rs (or world/core.rs) cover: RLO in a name, a zero-width-only name, bidi isolates in chat, and the Cc control case continuing to pass.
  • Existing world tests pass.

Activity

Next
  1. developing-today commented on Oct 29, 2026

    @developing-today
    developing-todayBot
    on Oct 29, 2026 – with developing.today
    Contributor
    More actions

    CODE-1016

  2. dezren39
    added
    kind/bugSomething isn't working (prefixed form of the classic bug label)
    priority/normalOrdinary priority (the default)
    queue/queuedHas a queued queue task
    source/creatorFiled by the new-issue-creator job
    task/triageQueue packet kind: verify, reproduce, and route this item
    status/needs-triageNot yet triaged; needs a first look
    app/idPackage/app: id (pkgs/ or apps/ in this repo)
    effort/sSmall: expected under 2 hours of work
    on Oct 29, 2026
  3. dezren39 commented on Oct 29, 2026

    @dezren39
    dezren39
    on Oct 29, 2026
    MemberAuthor
    More actions

    🤖 Agent note · filed

    • Agent: new-issue-creator job (lane B, new-issue-creator-code-b)
    • Session / ID: cron new-issue-creator-code-b run 2026-10-29T04:29Z
    • Found via: filed this run
    • Task: Filed after verifying on main 42796be that world/util.rs sanitize_display_name (:69) and sanitize_chat (:78) filter Cc only (char::is_control), so Cf format characters pass into participant display names (core.rs:847 join) and broadcast chat (core.rs:955, :578), and a zero-width-only name passes the join empty check; enqueued a triage packet.
    • Expectation: effort/s — triage pins the Cf rule (strip vs refuse, and explicitly the U+200D ZWJ / emoji-sequence case) consistent with id(petname): format characters (Cf) bypass both petname guards — U+200B makes a spoof of another contact's name, U+202E passes the 'no control characters' rule #1674/id(directory): format characters (Cf) bypass clean_name/clean_description — U+202E and U+200B pass the 'no control characters' rule for account and group names #1778, then routes a small_fix packet.
    • Links: packet queue-pilot/packet-2112-triage.json (repo-health-code-pilot); probe ~/git/fleet/probe-2026-10-28-laneB-worldcf/ (laptop)
  4. github-actions
    assigned
    dezren39
    on Oct 29, 2026
  5. dezren39
    added
    work/assignedQueue worker lifecycle state
    queue/claimedQueue worker lifecycle state
    and removed
    status/needs-triageNot yet triaged; needs a first look
    queue/queuedHas a queued queue task
    on Nov 1, 2026
  6. 3 remaining items

  7. dezren39
    added
    queue/claimedQueue worker lifecycle state
    status/in-progressQueue worker lifecycle state
    work/assignedQueue worker lifecycle state
    and removed
    status/in-progressQueue worker lifecycle state
    queue/claimedQueue worker lifecycle state
    work/assignedQueue worker lifecycle state
    on Nov 1, 2026
  8. dezren39 commented on Nov 1, 2026

    @dezren39
    dezren39
    on Nov 1, 2026
    MemberAuthor
    More actions

    agent-note:v1
    event: picked_up
    task: 5089 (repo-health-code-pilot, OpenChamber scheduled lane)
    state: Fresh GitHub shows #2112 OPEN, no held/do-not-edit labels, and no matching open implementation PR. I will reuse the existing petname Cf classifier as pinned by triage 3074.

  9. dezren39 commented on Nov 1, 2026

    @dezren39
    dezren39
    on Nov 1, 2026
    MemberAuthor
    More actions

    🤖 Agent note · picked up

    • Agent: queue worker (repo-worker-code), lane D shift
    • Session / ID: task 5089
    • Found via: queue claim
    • Task: Fix issue id(world): sanitize_display_name / sanitize_chat filter Cc only — Cf format characters (U+202E, U+200B, bidi isolates) pass into participant names and broadcast chat, and a zero-width-only name passes the join empty check #2112 per the rule pinned by triage task 3074 — sanitize_display_name strips the full Cf set (incl. U+200C/U+200D) sharing petname's is_format_char table; sanitize_chat strips Cf except U+200C/U+200D; unit tests for the pinned cases.
    • Expectation: effort class s; done = fix + tests on a branch, targeted world/util tests passing, PR opened.
    • Links: branch queue/5089-2112-cf-sanitizers, worktree ~/git/fleet/task-5089 on the laptop, base main 74a872a. Note: is_format_char is already pub in pkgs/id/crates/id-core/src/petname.rs and re-exported as crate::petname (invite.rs already uses it), so no petname change is needed — the sanitizers consume the shared table directly.
  10. dezren39
    added a commit that references this issue on Nov 2, 2026

    Merge pull request #4084 from developing-today/queue/5089-2112-cf-san…

    3c9dcfd
  11. dezren39
    closed this as completedin #4084on Nov 2, 2026
  12. dezren39 commented on Nov 2, 2026

    @dezren39
    dezren39
    on Nov 2, 2026
    MemberAuthor
    More actions

    🤖 Agent note · done

    • Agent: queue worker (repo-worker-code), lane D shift
    • Session / ID: task 5089
    • Found via: queue claim
    • Task: Fix issue id(world): sanitize_display_name / sanitize_chat filter Cc only — Cf format characters (U+202E, U+200B, bidi isolates) pass into participant names and broadcast chat, and a zero-width-only name passes the join empty check #2112 per the rule pinned by triage task 3074.
    • Result — FIXED AND MERGED: PR fix(id): strip Cf format chars in world display-name/chat sanitizers (#2112) #4084 merged as 3c9dcfd; issue id(world): sanitize_display_name / sanitize_chat filter Cc only — Cf format characters (U+202E, U+200B, bidi isolates) pass into participant names and broadcast chat, and a zero-width-only name passes the join empty check #2112 closed by the merge.
      • sanitize_display_name (pkgs/id/src/world/util.rs) now also strips the shared petname Cf table (crate::petname::is_format_char, already pub via id-core — no petname change needed), including U+200C/U+200D; a zero-width-only name sanitizes to empty and the join refusal fires.
      • sanitize_chat strips Cf except U+200C/U+200D, preserving ZWJ emoji sequences and joining scripts; newline/tab behavior unchanged.
      • Tests: 8 new unit tests in world::util covering every pinned case — laptop run cargo test -p id --lib world::util: 8 passed, 0 failed; the pre-existing sanitize-named tests also pass (4 passed under the sanitize filter run). Logs: /tmp/task5089-test2.log on the laptop, read back directly.
      • Codex review on head 872aa09: completed, zero findings.
    • Links: PR fix(id): strip Cf format chars in world display-name/chat sanitizers (#2112) #4084 fix(id): strip Cf format chars in world display-name/chat sanitizers (#2112) #4084 · branch queue/5089-2112-cf-sanitizers · worktree ~/git/fleet/task-5089 (laptop)
  13. dezren39
    removed
    status/in-progressQueue worker lifecycle state
    queue/claimedQueue worker lifecycle state
    work/assignedQueue worker lifecycle state
    on Nov 2, 2026
  14. dezren39
    added a commit that references this issue on Nov 2, 2026

    fix(id): accept pre-#2112 legacy display names on restore (#2960)

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

Metadata

Metadata

Assignees

  • @dezren39
    dezren39

Labels

app/idPackage/app: id (pkgs/ or apps/ in this repo)effort/sSmall: expected under 2 hours of workkind/bugSomething isn't working (prefixed form of the classic bug label)priority/normalOrdinary priority (the default)source/creatorFiled by the new-issue-creator jobtask/triageQueue packet kind: verify, reproduce, and route this item

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402775 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.