{"id":"CVE-2021-23387","published":"2021-05-24T18:16:34Z","modified":"2024-09-17T02:31:13Z","title":"Open Redirect","vendor":null,"product":null,"tier":"tail","description":{"text":"The package trailing-slash before 2.0.1 are vulnerable to Open Redirect via the use of trailing double slashes in the URL when accessing the vulnerable endpoint (such as https://example.com//attacker.example/). The vulnerable code is in index.js::createTrailing(), as the web server uses relative URLs instead of absolute URLs.","provenance":"source","from":"CVE.org"},"cvss":{"score":5.4,"severity":"MEDIUM","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N/E:P/RL:O/RC:C","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.0115,"percentile":0.6666,"provenance":"source"},"cwes":[],"references":[{"url":"https://snyk.io/vuln/SNYK-JS-TRAILINGSLASH-1085707","tags":["x_refsource_MISC"]},{"url":"https://github.com/fardog/trailing-slash/blob/f640ece055fe85275c983de5eb94661b95e35670/index.js%23L36","tags":["x_refsource_MISC"]},{"url":"https://github.com/fardog/trailing-slash/commit/f8e66f1429308247e5a119d430203077d8f05048","tags":["x_refsource_MISC"]}],"priority":{"score":17.1,"factors":[{"name":"EPSS percentile","points":13.33},{"name":"CVSS severity","points":3.78}]},"affectedVersions":[{"vendor":"n/a","product":"trailing-slash","versions":[">= unspecified, < 2.0.1"]}],"affected":[{"ecosystem":"npm","package":"trailing-slash","vulnerableRanges":["<2.0.1"],"patched":["2.0.1"],"from":["GHSA-rfhr-62xp-2fp2"],"provenance":"source"}],"summary":{"text":"The trailing-slash npm package before version 2.0.1 contains an open redirect flaw in the createTrailing() function within index.js, where the web server builds relative rather than absolute URLs. An attacker can exploit it over the network without authentication by getting a user to visit a crafted URL with trailing double slashes (for example, https://example.com//attacker.example/) that causes the endpoint to redirect the user to an attacker-chosen site.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T21:03:14Z"},"euvd":{"id":"EUVD-2021-1397","exploited":false,"provenance":"source"}}