CVE-2025-54885: Thinbus SRP Client Generates Insufficient Entropy

thinbus-srp Updated 14 Dec 2025

Summary

06/08/2025
Yes i
Moderate
6.9

CVE-2025-54885: Impact A protocol compliance bug in thinbus-srp-npm versions prior to 2.0.1 causes the client to generate a fixed 252 bits of entropy instead of the intended bit length of the safe prime (defaulted to 2048 bits). Affects thinbus-srp versions < 2.0.1. Fixed in 2.0.1. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

Thinbus-srp is a JavaScript implementation of the Secure Remote Password (SRP) protocol, which is used for secure password authentication. It allows clients to authenticate to servers without transmitting passwords directly, enhancing security. However, a protocol compliance bug in versions prior to 2.0.1 leads to a significant vulnerability where the client generates insufficient entropy for key exchange.

Vulnerability Detail

The vulnerability arises from a bug in the thinbus-srp-npm package, where the client generates a fixed 252 bits of entropy instead of the required 2048 bits as per RFC 5054. This flaw reduces the security margin of the protocol, making it practically exploitable. The client public value is derived from a private value that is 4 bits below the specification, which compromises the intended security of the key exchange process.

How To Fix

Minimum fixed version

2.0.1

This is the first release that contains the fix.

npm install thinbus-srp@2.0.1

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

If you cannot upgrade to the patched version, you can apply the following code workaround to your legacy version:

// WRONG
var hexLength = this.toHex(N).length;

// CORRECT
var hexLength = this.toHex(this.N()).length;

Conclusion

The vulnerability identified as CVE-2025-54885 in the thinbus-srp package poses a significant risk due to insufficient entropy generation during key exchange. It is crucial to update to version 2.0.1 or later to ensure the security of your application. If immediate updates are not feasible, applying the provided workaround can help mitigate the risk.

See every vulnerability recorded for thinbus-srp →

Share this vulnerability

FAQ

CVE-2025-54885 is a vulnerability in the thinbus-srp package that causes the client to generate insufficient entropy for secure key exchange.

This vulnerability can potentially allow attackers to exploit the weakened security of the key exchange process, compromising the confidentiality of user credentials.

All versions of thinbus-srp prior to 2.0.1 are affected by this vulnerability.

You can use Vulert to monitor and alert for open-source vulnerabilities in your software. Visit Vulert Scanner to check if your application is affected without needing to sign up.

If you cannot upgrade to the patched version, implement the provided code workaround to mitigate the risk until you can update.

How To Fix

Minimum fixed version

2.0.1

This is the first release that contains the fix.

npm install thinbus-srp@2.0.1

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback