CVE-2026-40194: phpseclib Observable Timing Discrepancy
Vulnerability summary
CVE-2026-40194 is a low (CVSS 3.7) Observable Timing Discrepancy vulnerability in phpseclib. EPSS estimates a 0.37% chance of exploitation in the next 30 days, higher than 29.2% of scored vulnerabilities.
Advisory lineage
Upstream 0 · Downstream 1 · Related 2Timeline
- 10-04-2026PublishedVulnerability first disclosed.
- 08-05-2026Last modifiedVulnerability information updated.
Description
phpseclib is a PHP secure communications library. Starting in 0.1.1 and prior to 3.0.51, 2.0.53, and 1.0.28, phpseclib\Net\SSH2::get_binary_packet() uses PHP's != operator to compare a received SSH packet HMAC against the locally computed HMAC. != on equal-length binary strings in PHP uses memcmp(), which short-circuits on the first differing byte. This is a real variable-time comparison (CWE-208), proven by scaling benchmarks. This vulnerability is fixed in 3.0.51, 2.0.53, and 1.0.28.
CVSS metrics
6 scores · 6 sources · 1 version- OSV · UbuntuEcosystem advisory · calculated3.7LowCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:N
- OSV · DebianEcosystem advisory · calculated3.7LowCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:N
- OSV · WolfiEcosystem advisory · calculated3.7LowCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:N
- OSV · ChainguardEcosystem advisory · calculated3.7LowCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:N
- NVDNIST3.7LowCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:N
EPSS trend
Probability
0.37%
Chance of exploitation in the next 30 days
Percentile
29%
Versus all other CVEs
30-day change
+0.01 pp
From 0.36% on 21-09-2026
Known exploited
Compare KEV catalogsNot in any of the 3 tracked catalogs.
Public exploits
0 foundNo public exploits indexed.
Weaknesses
CWE · root causeAffected systems
Chainguard4 products
- nextcloud-server-30All versions (No fix recorded)
- nextcloud-server-31All versions (No fix recorded)
- nextcloud-server-32< 32.0.8-r2
- nextcloud-server-33< 33.0.3-r0
Debian3 products
- php-phpseclib< 2.0.42-1+deb12u4 | < 2.0.48-3+deb13u2 | < 2.0.53-1
- php-phpseclib3< 3.0.19-1+deb12u5 | < 3.0.43-2+deb13u2 | < 3.0.51-1
- phpseclib< 1.0.20-1+deb12u4 | < 1.0.23-6+deb13u2
Ubuntu3 products
- php-phpseclib< 2.0.1-1ubuntu0.1~esm1 | < 2.0.9-1ubuntu0.1~esm3 | < 2.0.23-2ubuntu0.1~esm3 | < 2.0.36-1ubuntu0.1~esm3 | < 2.0.47-1ubuntu0.1~esm1 | All versions (No fix recorded) | < 2.0.51-1ubuntu0.1~esm1
- php-phpseclib3All versions (No fix recorded)
- phpseclibAll versions (No fix recorded)
Wolfi2 products
- nextcloud-server-32< 32.0.8-r2
- nextcloud-server-33< 33.0.3-r0
Phpseclib1 product
- phpseclib≥ 0.1.1, < 1.0.28 | ≤ 1.0.27 | ≥ 2.0.0, < 2.0.53 | ≥ 3.0.0, < 3.0.51
5 vendors · 13 products
References
11 links- github.com/phpseclib/phpseclib/security/advisories/GHSA-r854-jrxh-36qxX Refsource CONFIRMREPORTAdvisoryVendor Advisory
- github.com/phpseclib/phpseclib/commit/ffe48b6b1b1af6963327f0a5330e3aa004a194acX Refsource MISCREPORTFIXPatch