Security mailing lists by PureSourceCode

HSEC-2025-0004

HIGH 7.5CVSS 3.1

Broken Path Sanitization in spacecookie Library

Broken Path Sanitization in spacecookie Library

The spacecookie library exposes the functions sanitizePath and sanitizeIfNotUrl intended to
remove .. components from paths which can be used to prevent path traversal attacks. Due to
erroneous comparison code, this elimination is not actually performed which has been remedied
in version 1.0.0.3 by properly comparing using equalFilePath.

Any user of those respective functions of any version of spacecookie should upgrade to 1.0.0.3
or later. Note that the spacecookie server executable included in the same package is not affected
by the problem since a separate check would reject any malicious path that gets by sanitizePath.

Published
14 Nov 2025
Last modified
14 Nov 2025
Sources
OSVJSON

Scores

SourceScored byVersionScoreVector / decision
OSV HSEC CVSS 3.1 HIGH 7.5 CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

Affected

SourceVendor / ecosystemProduct / packageAffected versionsFixed in
OSV Hackage spacecookie >= 0.2.0.0, < 1.0.0.3 1.0.0.3

References

History

  • 25 Nov 2026 20:15 UTC · OSV: first stored (published 14 Nov 2025)
An unhandled error has occurred. Reload ×

Rejoining the server...

Rejoin failed... trying again in seconds.

Failed to rejoin.
Please retry or reload the page.

The session has been paused by the server.

Failed to resume the session.
Please retry or reload the page.