• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Kikobeats / parse-proxy-uri
100%

Build:
DEFAULT BRANCH: master
Repo Added 17 Oct 2020 02:49PM UTC
Files 1
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

LAST BUILD ON BRANCH master
branch: master
CHANGE BRANCH
x
Reset
  • master
  • cursor/critical-bug-management-6cd2
  • cursor/critical-bug-management-7631
  • cursor/critical-bug-management-9706
  • cursor/critical-bug-management-dd74
  • cursor/critical-bug-management-e596
  • cursor/critical-bug-management-e67f
  • dependabot/github_actions/actions/checkout-5
  • dependabot/github_actions/actions/checkout-6
  • dependabot/github_actions/actions/setup-node-5
  • dependabot/github_actions/actions/setup-node-6
  • dependabot/github_actions/pnpm/action-setup-6
  • fix/harden-proxy-uri-parsing
  • next

07 Aug 2026 01:14PM UTC coverage: 100.0% (+1.3%) from 98.726%
31181760862

push

github

web-flow
fix: keep ProxyURL credential mutations decode-safe (#27)

* fix: keep ProxyURL credential mutations decode-safe

Node's URL userinfo setters leave bare `%` sequences intact, so assigning
a password like `100%pure` via `.password` or `.href` made `.auth` throw
URIError and `toString()` emit a URI that got-scraping cannot decode.

Encode invalid `%` on username/password assignment, and reject href
mutations that introduce undecodable or control-character credentials
while rolling back to the previous value.

Co-authored-by: kikohumanbeatbox <kikohumanbeatbox@gmail.com>

* fix: validate every ProxyURL mutation path

The constructor's invariants only ran at parse time, so any setter could walk
a parsed proxy back into a shape parseProxy would have rejected: `href` took
paths, queries, fragments, `data:` URIs and obfuscated IPv4 hosts; `hostname`
and `host` re-opened the IPv4 rewrite closed in #25; `pathname`/`search`/`hash`
and `searchParams` desynced `href` from `toString()`.

Every mutation now runs the full check and rolls back on rejection, and
failures throw ParseProxyError (now a TypeError) so `error.code` works the
same as it does for parseProxy.

Credential setters take raw values and encode them, replacing the hybrid rule
where a password containing `%40` was silently decoded to `@` and dialed
wrong. `username`, `password` and `href` are non-enumerable, matching
URL.prototype, so spreading or logging a proxy no longer leaks credentials.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PUCXKwRQmtkcisF71E4MRj

* refactor: move ProxyURL accessors to the prototype

The guards were built per instance: 11 defineProperty calls and 13 closures
over the constructor scope for every parsed proxy, so each live proxy pinned
that scope. Defining them once on the prototype cuts parse from 2295 to 682
ns/op and 3351 to 262 bytes per live instance (200k iterations, 50k live
instances, --expose-g... (continued)

62 of 62 branches covered (100.0%)

Branch coverage included in aggregate %.

133 of 133 new or added lines in 1 file covered. (100.0%)

182 of 182 relevant lines covered (100.0%)

55.23 hits per line

Relevant lines Covered
Build:
Build:
182 RELEVANT LINES 182 COVERED LINES
55.23 HITS PER LINE
Source Files on master
  • Tree
  • List 1
  • Changed 1
  • Source Changed 1
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses

Recent builds

Builds Branch Commit Type Ran Committer Via Coverage
31181760862 master fix: keep ProxyURL credential mutations decode-safe (#27) * fix: keep ProxyURL credential mutations decode-safe Node's URL userinfo setters leave bare `%` sequences intact, so assigning a password like `100%pure` via `.password` or `.href` made ... push 07 Aug 2026 01:15PM UTC web-flow github
100.0
31016687283 master fix: keep ProxyURL credentials WHATWG-compatible (#26) * fix: keep ProxyURL credentials WHATWG-compatible Returning decoded username/password broke URL consumers that call decodeURIComponent (e.g. got-scraping): passwords with `%` throw URIError... push 05 Aug 2026 02:44PM UTC web-flow github
98.73
30890397619 master fix: harden proxy URI parsing (#25) * fix: harden proxy URI parsing Reject WHATWG misparses that silent-misroute traffic (schemeless host:port, rewritten IPv4, path/query/hash userinfo), keep credentials live across href/host mutation, and leave... push 04 Aug 2026 08:04AM UTC web-flow github
98.78
30846812957 master ci(dependabot): ignore actions minor/patch Floating major tags already pick up those updates at runtime. push 03 Aug 2026 07:42PM UTC Kikobeats github
100.0
30536094448 master chore: improve npm search metadata Co-authored-by: Cursor <cursoragent@cursor.com> push 30 Jul 2026 10:48AM UTC Kikobeats github
100.0
29928461363 master fix: prevent credential corruption in ProxyURL#toString (#21) * fix: percent-encode credentials in ProxyURL#toString Decoded username/password were interpolated into toString(), which corrupted proxy URIs when credentials contained reserved char... push 22 Jul 2026 02:25PM UTC web-flow github
100.0
24403022936 master Merge pull request #18 from Kikobeats/dependabot/github_actions/pnpm/action-setup-6 build(deps): bump pnpm/action-setup from 5 to 6 push 14 Apr 2026 01:55PM UTC web-flow github
100.0
19592281380 master Merge pull request #15 from Kikobeats/dependabot/github_actions/actions/checkout-6 build(deps): bump actions/checkout from 5 to 6 push 22 Nov 2025 07:27AM UTC web-flow github
100.0
18495266827 master Merge pull request #14 from Kikobeats/dependabot/github_actions/actions/setup-node-6 build(deps): bump actions/setup-node from 5 to 6 push 14 Oct 2025 11:39AM UTC web-flow github
100.0
17514787074 master Merge pull request #13 from Kikobeats/dependabot/github_actions/actions/setup-node-5 build(deps): bump actions/setup-node from 4 to 5 push 06 Sep 2025 12:58PM UTC web-flow github
100.0
See All Builds (54)
  • Repo on GitHub
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc