Live threats

All CVEs / Trailing-slash Project

CVE-2021-23387Trailing-slash Project Trailing-slash

Medium 6.1 No auth needed

Priority
52
CVSS 3.1
6.1
EPSS
1.1%
probability of exploitation in 30 days · percentile 68
Auth required
No
Published
May 24, 2021
Updated
Jun 17, 2026
Category
Application · Cross-platform
Weakness (CWE)
CWE-601
Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N

What happens

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.

Original NVD text.

What to do

  1. Apply the vendor's security update for Trailing-slash.
  2. It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.

Affected packages

EcosystemPackageAffected versionsFixed inHow to upgrade
npm trailing-slash < 2.0.1 2.0.1 npm install trailing-slash@2.0.1

Per OSV / GitHub Advisories (GHSA-rfhr-62xp-2fp2). Check the version in your lockfile before upgrading.

Affected products (CPE)

VendorProductVersions
trailing-slash_projecttrailing-slash< 2.0.1

Official sources

References

Links published by the sources. Open them with care.