{"id":"CVE-2022-24723","aliases":["EUVD-2022-1428","GHSA-gmv4-r438-p67f","UBUNTU-CVE-2022-24723"],"status":"published","title":"Improper Input Validation in URI.js","description":"URI.js is a Javascript URL mutation library. Before version 1.19.9, whitespace characters are not removed from the beginning of the protocol, so URLs are not parsed properly. This issue has been patched in version 1.19.9. Removing leading whitespace from values before passing them to URI.parse can be used as a workaround.","severity":{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N","level":"medium","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-09","score":0.01941,"percentile":0.80273,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-20"],"published":"2022-03-03T19:23:36Z","modified":"2026-10-28T02:30:42Z","fixes":[{"ecosystem":"npm","package":"urijs","fixed_in":["1.19.9"],"sources":["ghsa","osv"]}],"affected":[{"source":"ghsa","ecosystem":"npm","package":"urijs","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.19.9"}]}]},{"source":"osv","ecosystem":"npm","package":"urijs","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"1.19.9"}]}]},{"source":"osv","ecosystem":"Ubuntu:20.04:LTS","package":"node-uri-js","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["4.2.2+dfsg-4","4.2.2+dfsg-5"]},{"source":"osv","ecosystem":"Ubuntu:22.04:LTS","package":"node-uri-js","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["4.4.0+dfsg-5","4.4.0+dfsg-7"]},{"source":"osv","ecosystem":"Ubuntu:24.04:LTS","package":"node-uri-js","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["4.4.0+dfsg-8"]},{"source":"osv","ecosystem":"Ubuntu:25.10","package":"node-uri-js","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["4.4.0+dfsg-8"]},{"source":"osv","ecosystem":"Ubuntu:26.10","package":"node-uri-js","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["4.4.0+dfsg-9","4.4.0+dfsg-10"]},{"source":"osv","ecosystem":"Ubuntu:26.04:LTS","package":"node-uri-js","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["4.4.0+dfsg-8","4.4.0+dfsg-9"]}],"products":[{"vendor":"medialize","product":"uri.js"},{"vendor":"uri.js_project","product":"uri.js"}],"references":[{"url":"https://github.com/medialize/URI.js/security/advisories/GHSA-gmv4-r438-p67f","tags":["x_refsource_CONFIRM","x_transferred","Mitigation","Third Party Advisory","advisory","web","report"]},{"url":"https://github.com/medialize/uri.js/commit/86d10523a6f6e8dc4300d99d671335ee362ad316","tags":["x_refsource_MISC","x_transferred","Patch","Third Party Advisory","fix","report"]},{"url":"https://github.com/medialize/URI.js/releases/tag/v1.19.9","tags":["x_refsource_MISC","x_transferred","Release Notes","Third Party Advisory","web","report"]},{"url":"https://huntr.dev/bounties/82ef23b8-7025-49c9-b5fc-1bb9885788e5/","tags":["x_refsource_MISC","x_transferred","Exploit","Issue Tracking","Patch","Third Party Advisory","web","report"]},{"url":"https://github.com/medialize/URI.js/commit/86d10523a6f6e8dc4300d99d671335ee362ad316","tags":["web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2022-24723","tags":["advisory"]},{"url":"https://github.com/advisories/GHSA-gmv4-r438-p67f"},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/24xxx/CVE-2022-24723.json","tags":["advisory"]},{"url":"https://github.com/medialize/URI.js","tags":["web"]},{"url":"https://huntr.dev/bounties/82ef23b8-7025-49c9-b5fc-1bb9885788e5","tags":["web"]},{"url":"https://ubuntu.com/security/CVE-2022-24723","tags":["report"]},{"url":"https://www.cve.org/CVERecord?id=CVE-2022-24723","tags":["report"]}],"sources":{"cve":[{"id":"CVE-2022-24723","title":"Improper Input Validation in URI.js","description":"URI.js is a Javascript URL mutation library. Before version 1.19.9, whitespace characters are not removed from the beginning of the protocol, so URLs are not parsed properly. This issue has been patched in version 1.19.9. Removing leading whitespace from values before passing them to URI.parse can be used as a workaround.","status":"published","published":"2022-03-03T20:35:11Z","modified":"2025-04-22T18:20:48.76Z","cvss":[{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N","level":"medium","assessor":"cna"}],"cwes":["CWE-20"],"updated_at":"2026-11-02T14:34:34.940806Z"}],"euvd":[{"id":"EUVD-2022-1428","description":"URI.js is a Javascript URL mutation library. Before version 1.19.9, whitespace characters are not removed from the beginning of the protocol, so URLs are not parsed properly. This issue has been patched in version 1.19.9. Removing leading whitespace from values before passing them to URI.parse can be used as a workaround.","status":"published","published":"2022-03-03T20:35:11Z","modified":"2025-04-22T18:20:48Z","cvss":[{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N","level":"medium"}],"updated_at":"2026-11-02T20:52:15.026784Z"}],"ghsa":[{"id":"GHSA-gmv4-r438-p67f","title":"Leading white space bypasses protocol validation","description":"### Impact\nWhitespace characters are not removed from the beginning of the protocol, so URLs are not parsed properly and protocol validation mechanisms may fail.\n\n### Patches\nPatched in 1.19.9\n\n### Workarounds\nRemove leading whitespace from values before passing them to URI.parse (e.g. via `.href(value)` or `new URI(value)`), e.g. by using\n\n```js\nfunction remove_whitespace(url){\n     const whitespace = /^[\\x00-\\x20\\u00a0\\u1680\\u2000-\\u200a\\u2028\\u2029\\u202f\\u205f\\u3000\\ufeff]+/;\n     url = url.replace(whitespace, '')\n     return url\n}\n```\n\n### References\n* https://huntr.dev/bounties/82ef23b8-7025-49c9-b5fc-1bb9885788e5/\n\n### For more information\nIf you have any questions or comments about this advisory:\n* Open an issue in [medialize/URI.js](https://github.com/medialize/URI.js/)\n","status":"published","published":"2022-03-03T19:23:36Z","modified":"2023-02-03T05:06:21Z","cvss":[{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N","level":"medium"}],"cwes":["CWE-20"],"updated_at":"2026-11-02T14:36:43.439065Z"}],"nvd":[{"id":"CVE-2022-24723","description":"URI.js is a Javascript URL mutation library. Before version 1.19.9, whitespace characters are not removed from the beginning of the protocol, so URLs are not parsed properly. This issue has been patched in version 1.19.9. Removing leading whitespace from values before passing them to URI.parse can be used as a workaround.","status":"published","published":"2022-03-03T21:15:07.813Z","modified":"2026-06-17T04:32:22.487Z","cvss":[{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N","level":"medium","assessor":"secondary"},{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N","level":"medium","assessor":"primary"},{"version":"2.0","score":5,"vector":"AV:N/AC:L/Au:N/C:N/I:P/A:N","level":"medium","assessor":"primary"}],"cwes":["CWE-20"],"updated_at":"2026-11-02T14:07:12.711288Z"}],"osv":[{"id":"CVE-2022-24723","title":"Improper Input Validation in URI.js","description":"URI.js is a Javascript URL mutation library. Before version 1.19.9, whitespace characters are not removed from the beginning of the protocol, so URLs are not parsed properly. This issue has been patched in version 1.19.9. Removing leading whitespace from values before passing them to URI.parse can be used as a workaround.","status":"published","published":"2022-03-03T20:35:11Z","modified":"2026-10-28T02:30:42.472465273Z","cvss":[{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N","level":"medium"}],"cwes":["CWE-20"],"updated_at":"2026-11-02T15:44:24.428403Z"},{"id":"GHSA-gmv4-r438-p67f","title":"Leading white space bypasses protocol validation","description":"### Impact\nWhitespace characters are not removed from the beginning of the protocol, so URLs are not parsed properly and protocol validation mechanisms may fail.\n\n### Patches\nPatched in 1.19.9\n\n### Workarounds\nRemove leading whitespace from values before passing them to URI.parse (e.g. via `.href(value)` or `new URI(value)`), e.g. by using\n\n```js\nfunction remove_whitespace(url){\n     const whitespace = /^[\\x00-\\x20\\u00a0\\u1680\\u2000-\\u200a\\u2028\\u2029\\u202f\\u205f\\u3000\\ufeff]+/;\n     url = url.replace(whitespace, '')\n     return url\n}\n```\n\n### References\n* https://huntr.dev/bounties/82ef23b8-7025-49c9-b5fc-1bb9885788e5/\n\n### For more information\nIf you have any questions or comments about this advisory:\n* Open an issue in [medialize/URI.js](https://github.com/medialize/URI.js/)\n","status":"published","published":"2022-03-03T19:23:36Z","modified":"2023-11-08T04:08:33.715397Z","cvss":[{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N","level":"medium"}],"cwes":["CWE-20"],"updated_at":"2026-11-02T15:46:48.191583Z"},{"id":"UBUNTU-CVE-2022-24723","description":"URI.js is a Javascript URL mutation library. Before version 1.19.9, whitespace characters are not removed from the beginning of the protocol, so URLs are not parsed properly. This issue has been patched in version 1.19.9. Removing leading whitespace from values before passing them to URI.parse can be used as a workaround.","status":"published","published":"2022-03-03T21:15:00Z","modified":"2026-10-17T12:56:21.587058656Z","cvss":[{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N","level":"medium"},{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N","level":"medium"}],"updated_at":"2026-11-02T16:53:53.13624Z"}]}}
