Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1336 CNY

100%

CVE-2026-84308— phpseclib — non-constant-time X25519 scalar multiplication permits full private-key recovery

Quick assessment

Affected
phpseclib phpseclib
Exploitation
No confirmed in-the-wild exploitation; assess based on exposure
Recommended action
Check the vendor advisory and references for a fixed version. If immediate upgrade is impossible, restrict exposure and increase monitoring.

以下是该漏洞描述的中文翻译: phpseclib 是一个 PHP 安全通信库。在 3.0.57 和 4.0.1 版本之前,位于 中的纯 PHP 实现 X25519 标量乘法,其 和 函数中存在依赖于数据条件的模数归约操作。在 中的蒙哥马利梯(Montgomery Ladder)中,每一步的归约行为依赖于秘密标量前缀,从而产生了可观测的每步时序差异和 libgmp 调用次数差异,这些差异可能泄露被重复使用的 251 位钳制(clamped)私有标量。 利用路径方面: 中的密钥推导路径直接调用纯 PHP 乘法,且未检查

CVSS 6.3 · Medium

Affected Version Matrix 2

VendorProduct Version RangeStatus
phpseclib phpseclib < 3.0.57 affected
>= 4.0.0, < 4.0.1 affected
Get alerts for future matching vulnerabilities Log in to subscribe

I. Basic Information for CVE-2026-84308

Vulnerability Information

Have questions about the vulnerability? See if Shenlong's analysis helps!
View Shenlong Deep Dive ↗

Although we use advanced large model technology, its output may still contain inaccurate or outdated information.Shenlong tries to ensure data accuracy, but please verify and judge based on the actual situation.

Vulnerability Title
phpseclib — non-constant-time X25519 scalar multiplication permits full private-key recovery
Source: CVE Program / CVE List V5
Vulnerability Description
phpseclib is a PHP secure communications library. Prior to 3.0.57 and 4.0.1, pure-PHP X25519 scalar multiplication in phpseclib/Math/PrimeField/Integer.php performs data-dependent conditional modular reductions in add() and subtract(). During the Montgomery ladder in phpseclib/Crypt/EC/BaseCurves/Montgomery.php, the reduction behavior of each step depends on the secret scalar prefix, creating per-step timing and libgmp call-count observations that can reveal a reused 251-bit clamped private scalar. The phpseclib/Crypt/EC/Formats/Keys/MontgomeryPrivate.php derivation path invokes the pure-PHP multiplication without a native-engine check, while phpseclib/Crypt/EC/Formats/Keys/PKCS8.php reaches it when ext-sodium is unavailable. Exploitation requires a reused or long-lived X25519 private key, knowledge of the corresponding public key, execution of the pure-PHP path, and a local observer capable of resolving individual ladder steps or libgmp entry-point calls. Ephemeral X25519 keys, including phpseclib's normal SSH exchange path, are not affected. Recovery of the scalar permanently compromises operations that reuse that key. This issue is fixed in versions 3.0.57 and 4.0.1.
Source: CVE Program / CVE List V5
CVSS Information
CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:N
Source: CVE Program / CVE List V5
Vulnerability Type
通过时间差异性导致的信息暴露
Source: CVE Program / CVE List V5

Affected Products

Vendor Product Affected Versions CPE Subscribe
phpseclib phpseclib < 3.0.57 -

II. Public POCs for CVE-2026-84308

# POC Description Source Link Shenlong Link
AI-Generated POC Premium

No public POC found.

Login to generate AI POC

III. Intelligence Information for CVE-2026-84308

登录查看更多情报信息。

Other References for CVE-2026-84308 (4)

IV. Related Vulnerabilities

V. Comments for CVE-2026-84308

No comments yet


Leave a comment