Repository navigation
fix(export): preserve Hysteria2 URI semantics - #4
Conversation
Share one parser between node validation and sing-box export, support default and port-hopping authorities, preserve userpass and IPv6, map Salamander and Gecko, and fail closed for unsupported certificate pinning and ECH. Add focused fixtures, parser/export regressions, warning-first configuration coverage, and update the export matrix and roadmap. No production deployment, Cloudflare secret mutation, or real Gist write is performed.
Deploying with
|
| Status | Name | Latest Commit | Updated (UTC) |
|---|---|---|---|
| ✅ Deployment successful! View logs |
subman | a332f6d | Aug 28 2026, 09:01 AM |
Replace unsupported negated null matchers with equivalent boolean assertions so the tests remain compatible with the repository's minimal Bun matcher declarations.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e4ab15983a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| inferredType, | ||
| declaredType: declaredType ?? null, | ||
| syntaxValid: true, | ||
| coreFieldsValid: true, |
There was a problem hiding this comment.
Reject unsupported Hysteria2 networks during validation
For a node such as hy2://password@example.com?network=icmp, the shared parser succeeds and this branch reports coreFieldsValid: true, but parseHysteria2 rejects the same value because only tcp and udp are supported. The editor therefore accepts a node that is later dropped during export, preserving the validation/export mismatch this change is intended to eliminate; validate network in the shared parser as well.
Useful? React with 👍 / 👎.
| if (separatorIndex < 0) { | ||
| return decodeURIComponent(rawAuth) || null; | ||
| } | ||
| if (rawAuth.indexOf(":", separatorIndex + 1) >= 0) return null; |
There was a problem hiding this comment.
Preserve colons inside userpass passwords
For a valid userpass authority such as hy2://user:pa:ss@example.com, this check returns missing-auth solely because the password contains a second literal colon. Colons are permitted within URI userinfo, and the equivalent percent-encoded password is accepted, so otherwise usable links are unnecessarily skipped; split on the first delimiter and decode the complete remainder as the password.
Useful? React with 👍 / 👎.
Summary
Verification
The repository CI must pass the complete reusable verification chain: unit tests, Svelte/TypeScript checks, Biome, build, Cloudflare integration, Wrangler deploy dry-run, Durable Object export assertion, and Playwright.
No production deployment, Cloudflare secret mutation, or real Gist write is performed.