{"id":"CVE-2026-42770","aliases":["CVE-2026-42770"],"related":[],"kind":"vulnerability","state":"published","title":"FFC-DH Peer Validation Uses Attacker-Supplied q","summary":"Issue summary: When EVP_PKEY_derive_set_peer() is called with a DHX (X9.42)\npeer key, the peer key is not properly checked for the subgroup membership.\n\nImpact summary: A malicious peer which presents an X9.42 key carrying the\nvictim's p and g parameters, a forged q = r (a small prime factor of the\ncofactor (p−1)/q_local), and a public value Y of order r can recover the\nvictim's private key after a small number of key exchange attempts.\n\nWhen EVP_PKEY_derive_set_peer() is called with a DHX (X9.42) peer key, the\nsubgroup membership check Y^q ≡ 1 (mod p) is performed using the peer's\nown q parameter, not the local key's q. The peer's domain parameters are\nthen matched against the domain parameters of the private key, but the value\nof q is not compared.\n\nA malicious peer who presents an X9.42 key carrying the victim's p, g,\na forged q = r (a small prime factor of the cofactor), and a public\nvalue Y of order r passes all checks. The shared secret then takes only\nr distinct values, leaking priv mod r. Repeating for each small-prime\nfactor of the cofactor and combining via CRT recovers the full private\nkey (Lim–Lee / small-subgroup-confinement attack).\n\nThe realistic attack surface is narrow: principally CMP deployments with\nlong-lived RA/CA DHX keys and bespoke enterprise or government applications\nusing X9.42 DHX static keys with interactive protocols and therefore this\nissue was assigned Low severity.\n\nThe FIPS modules in 4.0, 3.6, 3.5, 3.4, 3.1.2 and 3.0 are affected by this\nissue.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Issue summary: When EVP_PKEY_derive_set_peer() is called with a DHX (X9.42)\npeer key, the peer key is not properly checked for the subgroup membership.\n\nImpact summary: A malicious peer which presents an X9.42 key carrying the\nvictim's p and g parameters, a forged q = r (a small prime factor of the\ncofactor (p−1)/q_local), and a public value Y of order r can recover the\nvictim's private key after a small number of key exchange attempts.\n\nWhen EVP_PKEY_derive_set_peer() is called with a DHX (X9.42) peer key, the\nsubgroup membership check Y^q ≡ 1 (mod p) is performed using the peer's\nown q parameter, not the local key's q. The peer's domain parameters are\nthen matched against the domain parameters of the private key, but the value\nof q is not compared.\n\nA malicious peer who presents an X9.42 key carrying the victim's p, g,\na forged q = r (a small prime factor of the cofactor), and a public\nvalue Y of order r passes all checks. The shared secret then takes only\nr distinct values, leaking priv mod r. Repeating for each small-prime\nfactor of the cofactor and combining via CRT recovers the full private\nkey (Lim–Lee / small-subgroup-confinement attack).\n\nThe realistic attack surface is narrow: principally CMP deployments with\nlong-lived RA/CA DHX keys and bespoke enterprise or government applications\nusing X9.42 DHX static keys with interactive protocols and therefore this\nissue was assigned Low severity.\n\nThe FIPS modules in 4.0, 3.6, 3.5, 3.4, 3.1.2 and 3.0 are affected by this\nissue.","source":"cvelist"},{"lang":"es","text":"Resumen del problema: Cuando se llama a EVP_PKEY_derive_set_peer() con una clave de par DHX (X9.42), la clave de par no se verifica correctamente para la pertenencia al subgrupo.\n\nResumen del impacto: Un par malicioso que presenta una clave X9.42 que contiene los parámetros p y g de la víctima, una q forjada = r (un pequeño factor primo del cofactor (p?1)/q_local), y un valor público Y de orden r puede recuperar la clave privada de la víctima después de un pequeño número de intentos de intercambio de claves.\n\nCuando se llama a EVP_PKEY_derive_set_peer() con una clave de par DHX (X9.42), la verificación de pertenencia al subgrupo Y^q ? 1 (mod p) se realiza utilizando el propio parámetro q del par, no la q de la clave local. Los parámetros de dominio del par se comparan entonces con los parámetros de dominio de la clave privada, pero el valor de q no se compara.\n\nUn par malicioso que presenta una clave X9.42 que contiene la p, g de la víctima, una q forjada = r (un pequeño factor primo del cofactor), y un valor público Y de orden r pasa todas las verificaciones. El secreto compartido toma entonces solo r valores distintos, filtrando priv mod r. Repitiendo para cada factor primo pequeño del cofactor y combinando mediante CRT se recupera la clave privada completa (ataque Lim-Lee / de confinamiento de subgrupo pequeño).\n\nLa superficie de ataque realista es estrecha: principalmente despliegues de CMP con claves DHX de RA/CA de larga duración y aplicaciones empresariales o gubernamentales a medida que utilizan claves estáticas DHX X9.42 con protocolos interactivos y, por lo tanto, a este problema se le asignó una severidad Baja.\n\nLos módulos FIPS en 4.0, 3.6, 3.5, 3.4 y 3.0 se ven afectados por este problema.","source":"nvd"}],"published":"2026-06-09T16:03:29.802Z","modified":"2026-07-23T08:10:00.137Z","severity":{"scorer":"CISA-ADP","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:N","score":3.7,"rating":"LOW"},"severities":[{"scorer":"CISA-ADP","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:N","score":3.7,"rating":"LOW"}],"cwes":["CWE-325"],"affected":[{"ranges":[{"type":"semver","introduced":"4.0.0","fixed":"4.0.1","status":"affected"},{"type":"semver","introduced":"3.6.0","fixed":"3.6.3","status":"affected"},{"type":"semver","introduced":"3.5.0","fixed":"3.5.7","status":"affected"},{"type":"semver","introduced":"3.4.0","fixed":"3.4.6","status":"affected"},{"type":"semver","introduced":"3.0.0","fixed":"3.0.21","status":"affected"}],"vendor":"OpenSSL","product":"OpenSSL","source":"cvelist"},{"ranges":[{"status":"affected","introduced":"3.0.0","fixed":"3.0.21"},{"status":"affected","introduced":"3.4.0","fixed":"3.4.6"},{"status":"affected","introduced":"3.5.0","fixed":"3.5.7"},{"status":"affected","introduced":"3.6.0","fixed":"3.6.3"},{"status":"affected","version":"4.0.0"}],"vendor":"openssl","product":"openssl","cpe":"cpe:2.3:a:openssl:openssl:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://openssl-library.org/news/secadv/20260609.txt","tags":["vendor-advisory"],"sources":["cvelist","nvd"]},{"url":"https://github.com/openssl/openssl/commit/3da5a516cd2635a320ff748503db2cef7c4b0f02","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://github.com/openssl/openssl/commit/3ddbb7ab50bd93dfc59cbe08e269a67605aeebdb","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://github.com/openssl/openssl/commit/ca2237ab5615641b662183b077f62c08d75e8070","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://github.com/openssl/openssl/commit/5f452bba2c681423d8fcffd120a19b757ee42e3c","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://github.com/openssl/openssl/commit/7fbfde7677ed8808828bf00ff01c937ca04bdda2","tags":["patch"],"sources":["cvelist","nvd"]}],"credits":["Alex Gaynor (Anthropic)","Viktor Dukhovni","Norbert Pócs"],"assigner":"openssl","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2026-06-09T19:34:57.693Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-42770","url":"https://www.cve.org/CVERecord?id=CVE-2026-42770","licence":"CVE Terms of Use","modified":"2026-07-20T16:09:50.313Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-42770","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-42770","licence":"Public domain","modified":"2026-07-23T08:10:00.137Z"}],"updatedAt":"2026-11-25T22:59:24.135Z","epss":{"score":0.00503,"percentile":0.44607,"date":"2026-12-01T12:00:22.000Z"}}