René's URL Explorer Experiment


Title: lab-ops-hub: container validator accepts IDNA-invalid hosts the Worker refuses — unassigned codepoints and bidi-violating mixed labels · Issue #583 · developing-today/code · GitHub

Open Graph Title: lab-ops-hub: container validator accepts IDNA-invalid hosts the Worker refuses — unassigned codepoints and bidi-violating mixed labels · Issue #583 · developing-today/code

X Title: lab-ops-hub: container validator accepts IDNA-invalid hosts the Worker refuses — unassigned codepoints and bidi-violating mixed labels · Issue #583 · developing-today/code

Description: Summary The container crawl validator (pkgs/lab-ops-hub/container/app.py, validate_crawl_url) certifies hosts that are not valid IDNA/UTS-46 domain names at all — and that the Worker's validator refuses outright — in (at least) two whole...

Open Graph Description: Summary The container crawl validator (pkgs/lab-ops-hub/container/app.py, validate_crawl_url) certifies hosts that are not valid IDNA/UTS-46 domain names at all — and that the Worker's validator re...

X Description: Summary The container crawl validator (pkgs/lab-ops-hub/container/app.py, validate_crawl_url) certifies hosts that are not valid IDNA/UTS-46 domain names at all — and that the Worker's validato...

Opengraph URL: https://github.com/developing-today/code/issues/583

X: @github

direct link

Domain: github.com

IPv4 address: 140.82.114.4


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"lab-ops-hub: container validator accepts IDNA-invalid hosts the Worker refuses — unassigned codepoints and bidi-violating mixed labels","articleBody":"## Summary\n\nThe container crawl validator (`pkgs/lab-ops-hub/container/app.py`, `validate_crawl_url`) certifies hosts that are not valid IDNA/UTS-46 domain names at all — and that the Worker's validator refuses outright — in (at least) two whole classes the hand-maintained checks cannot see:\n\n1. **Unassigned codepoints.** A label containing a codepoint Unicode has not assigned (e.g. U+0378, U+0380, U+05EB) is accepted and passed on as a public DNS name.\n2. **Bidi-rule violations.** A label mixing left-to-right Latin with right-to-left Hebrew/Arabic characters (e.g. `exאample.com`, `localאhost`) is accepted, even though IDNA's bidi requirements forbid it — Python's own stdlib IDNA codec raises `Violation of BIDI requirement 2` on exactly this input, but the validator never calls it.\n\nThe Worker side needs no code to reject these: `new URL()` / WHATWG domain-to-ASCII (UTS-46, `CheckBidi` + disallowed/unassigned checks) throws, and `validateCrawlUrl` (`pkgs/lab-ops-hub/src/lib.ts`) returns `url is not a valid URL`. So the two validators that are supposed to hold the same crawl-target policy (#441 defence in depth: the component that actually fetches re-validates independently) disagree on thousands of spellings.\n\n## Evidence (verified 2026-10-22 on main `59ba8cf1`)\n\nDifferential probe: every codepoint U+0080–U+32FF inserted into `ex\u003ccp>ample.com` and `local\u003ccp>host`, plus script-digit IP spellings and ASCII structural insertions — 26,040 hosts run through both real validators (Python `validate_crawl_url` imported from `container/app.py`; TS `validateCrawlUrl` imported from `src/lib.ts`):\n\n- **3,174 divergences, all in one direction** (container accepts / Worker refuses); **0** in the reverse direction.\n- By first non-ASCII codepoint: ~2,070 unassigned, ~1,001 RTL bidi (`AL`/`R`), plus smaller pockets (e.g. U+0601, U+066B, U+115F, enclosed digits like U+2478).\n\nHeadline cases:\n\n| URL | container `validate_crawl_url` | Worker `validateCrawlUrl` / `new URL` |\n|---|---|---|\n| `http://exאample.com/` (Latin + Hebrew alef in one label) | **accepts**, returns URL unchanged | rejects — `new URL` throws |\n| `http://͸ample.com/` (U+0378, unassigned) | **accepts** | rejects — `new URL` throws |\n| `http://localאhost/` | **accepts** | rejects — `new URL` throws |\n| `http://אא.com/` (pure RTL label, control) | accepts | accepts (`xn--4dba.com`) — validators agree |\n\nRoot cause, `container/app.py`:\n\n- `validate_crawl_url` (line 62) never performs an IDNA validity check on the mapped host. Its only IDNA-adjacent step is the length check at line 190, which measures `\"xn--\" + label.encode(\"punycode\")` — raw punycode encoding succeeds for *any* string, valid IDN or not.\n- The invalid-codepoint defence is the hand-enumerated `_IDNA_DISALLOWED` frozenset (line 55, from #516: ~30 codepoints). A denylist cannot cover unassigned ranges (thousands of codepoints, growing/shrinking per Unicode version) or contextual rules like bidi, which are properties of the whole label, not of single codepoints.\n- Even the obvious quick fix is insufficient on its own: `\"exאample\".encode(\"idna\")` raises the bidi error (verified), but `\"\\u0378\".encode(\"idna\")` happily returns `b\"xn--zva\"` — the stdlib IDNA-2003 codec accepts unassigned codepoints that UTS-46 marks disallowed. Parity needs a check that matches WHATWG behaviour for both classes, not just a codec call.\n\nConsequences, same shapes this series has fixed before (#502, #507, #516):\n\n- The container certifies a non-name as a public DNS name; for bidi-violating spellings the failure then surfaces deep inside the fetcher (the resolver's IDNA step raises) as a 502 crawl failure, instead of the validator's up-front refusal — and the Worker fallback never sees the target the same way, so behaviour depends on which crawler runs.\n- Defence in depth is weakened asymmetrically: any future check layered on \"the validator only passes real DNS names\" (blocked-suffix, length, punycode A-label handling — cf. open #580) is reasoning about a host form this gap lets through unjudged in IDNA terms.\n\n## Acceptance criteria\n\n- `validate_crawl_url` refuses hosts whose labels are not valid UTS-46/IDNA domain labels — covering at minimum the unassigned-codepoint and bidi-violation classes above — with the same accept/refuse verdict as the Worker's `validateCrawlUrl` on a differential battery (the 26,040-host probe above, or an equivalent committed test corpus).\n- Pure RTL labels, ordinary IDN (`münchen.de`), and every currently-accepted public host in the existing suites stay accepted; CONTEXTJ handling stays as tracked separately in #531 (this issue is about spellings the Worker *refuses*).\n- New tests in `test/test_container_validate.py` pin the headline cases (mixed LTR+RTL label refused, unassigned codepoint refused, pure RTL label accepted), and the TS suite gains the same cases if it does not already pin them.\n- No regression in the existing Python (32 tests) or TS suites.\n\n## Notes\n\n- Single-repo: `validate_crawl_url` / `_IDNA_DISALLOWED` exist only in `developing-today/code` (grep across the opencode / openchamber / nix clones: no copies). Not an mcpx set.\n- Related, distinct: #580 (A-label/punycode spelling of Arabic-Indic digits — an *encoded* form of an already-covered refusal), #531 (opposite direction: container over-refuses CONTEXTJ-valid ZWNJ/ZWJ). This issue is the remaining under-refusal: whole IDNA-validity classes neither validator check enumerates.\n","author":{"url":"https://github.com/dezren39","@type":"Person","name":"dezren39"},"datePublished":"2026-10-22T11:25:31Z","url":"https://github.com/developing-today/code/issues/583"}

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:90321dd5-0b16-42b2-ee91-68f1d99879c7
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idAEF0:5F360:AD092F:DFD5A6:6B063731
html-safe-nonce7ab7d268f91da6e5ca2d37ac4c8bc875ae13d9c91271b1c29d52adaf0b4d9f8e
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBRUYwOjVGMzYwOkFEMDkyRjpERkQ1QTY6NkIwNjM3MzEiLCJ2aXNpdG9yX2lkIjoiOTAzNDE4NjE5ODIwOTY3MzAwOSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmacfae9e511840828a90d5714d2fe406740a467b363474119aae7c6539a984c9e64
hovercard-subject-tagissue:5978379145
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/developing-today/code/583/issue_layout
twitter:imagehttps://opengraph.githubassets.com/d781340ce9bfc2512dc545247d834cf640dcae7e8a30cc1e8d1f2a65ee123f95/developing-today/code/issues/583
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/d781340ce9bfc2512dc545247d834cf640dcae7e8a30cc1e8d1f2a65ee123f95/developing-today/code/issues/583
og:image:altSummary The container crawl validator (pkgs/lab-ops-hub/container/app.py, validate_crawl_url) certifies hosts that are not valid IDNA/UTS-46 domain names at all — and that the Worker's validator re...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamedezren39
hostnamegithub.com
expected-hostnamegithub.com
Nonec3584c853cd39700ecff6e2cf8364295ffdb5313e571046c41cd2479270f7df0
turbo-cache-controlno-preview
go-importgithub.com/developing-today/code git https://github.com/developing-today/code.git
octolytics-dimension-user_id26439447
octolytics-dimension-user_logindeveloping-today
octolytics-dimension-repository_id627308783
octolytics-dimension-repository_nwodeveloping-today/code
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id627308783
octolytics-dimension-repository_network_root_nwodeveloping-today/code
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release9eb3bb1597d09170a5f282cd38ae376dee1a5ec1
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/developing-today/code/issues/583#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fdeveloping-today%2Fcode%2Fissues%2F583
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fdeveloping-today%2Fcode%2Fissues%2F583
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=developing-today%2Fcode
Reloadhttps://github.com/developing-today/code/issues/583
Reloadhttps://github.com/developing-today/code/issues/583
Reloadhttps://github.com/developing-today/code/issues/583
developing-todayhttps://github.com/developing-today
codehttps://github.com/developing-today/code
Codehttps://github.com/developing-today/code
Issues1.1k (1.1k)https://github.com/developing-today/code/issues
Pull requests159 (159)https://github.com/developing-today/code/pulls
Discussionshttps://github.com/developing-today/code/discussions
Actionshttps://github.com/developing-today/code/actions
Projectshttps://github.com/developing-today/code/projects
Wikihttps://github.com/developing-today/code/wiki
Security and qualityhttps://github.com/developing-today/code/security
Insightshttps://github.com/developing-today/code/insights
https://github.com/developing-today/code
New issuehttps://github.com/login?return_to=https://github.com/developing-today/code/issues/583
New issuehttps://github.com/login?return_to=https://github.com/developing-today/code/issues/583
#590https://github.com/developing-today/code/pull/590
lab-ops-hub: container validator accepts IDNA-invalid hosts the Worker refuses — unassigned codepoints and bidi-violating mixed labelshttps://github.com/developing-today/code/issues/583#top
#590https://github.com/developing-today/code/pull/590
https://github.com/dezren39
https://github.com/dezren39
dezren39https://github.com/dezren39
on Oct 22, 2026https://github.com/developing-today/code/issues/583#issue-5978379145
#441https://github.com/developing-today/code/issues/441
lab-ops-hub: container validator still allows IDNA-disallowed Unicode hosts (space separators, bidi/format controls, U+FFFD) the Worker validator refuses #516https://github.com/developing-today/code/issues/516
#502https://github.com/developing-today/code/issues/502
#507https://github.com/developing-today/code/issues/507
#516https://github.com/developing-today/code/issues/516
lab-ops-hub: container validator still accepts the A-label (punycode) spelling of Arabic-Indic-digit hosts that PR #575 refused in raw form — including xn--9hbcp.xn--8hb.xn--8hb.xn--9hb, the encoded 127.0.0.1 #580https://github.com/developing-today/code/issues/580
lab-ops-hub: container validator blanket-refuses CONTEXTJ-valid ZWNJ/ZWJ hosts (virama and Arabic-script joining contexts) the Worker validator accepts #531https://github.com/developing-today/code/issues/531
lab-ops-hub: container validator still accepts the A-label (punycode) spelling of Arabic-Indic-digit hosts that PR #575 refused in raw form — including xn--9hbcp.xn--8hb.xn--8hb.xn--9hb, the encoded 127.0.0.1 #580https://github.com/developing-today/code/issues/580
lab-ops-hub: container validator blanket-refuses CONTEXTJ-valid ZWNJ/ZWJ hosts (virama and Arabic-script joining contexts) the Worker validator accepts #531https://github.com/developing-today/code/issues/531
github-actionshttps://github.com/apps/github-actions
dezren39https://github.com/dezren39
on Oct 22, 2026https://github.com/developing-today/code/issues/583#event-33943664896
dezren39https://github.com/dezren39
on Oct 22, 2026https://github.com/developing-today/code/issues/583#event-33960063688
Merge pull request #590 from developing-today/sweep/583-idna-validityhttps://github.com/developing-today/code/commit/ead788e134f0c27c5172edf01557963a2ea312c3
#590https://github.com/developing-today/code/pull/590
ead788ehttps://github.com/developing-today/code/commit/ead788e134f0c27c5172edf01557963a2ea312c3
dezren39https://github.com/dezren39
completedhttps://github.com/developing-today/code/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Acompleted
#590https://github.com/developing-today/code/pull/590
on Oct 22, 2026https://github.com/developing-today/code/issues/583#event-33960063878
Sign up for freehttps://github.com/signup?return_to=https://github.com/developing-today/code/issues/583
Sign in to commenthttps://github.com/login?return_to=https://github.com/developing-today/code/issues/583
dezren39https://github.com/dezren39
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Response headers:
Servergithub.com
Content-Typetext/html; charset=utf-8
Cache-Controlmax-age=0, private, must-revalidate

Viewport: width=device-width


URLs of crawlers that visited me.