Skip to content
Heist/ feed
Back to feed
High

Non-CA certificate accepted as intermediate issuer in public_key path validation

Type: advisorySources: OSV

## Summary Improper Following of a Certificate's Chain of Trust vulnerability in Erlang OTP `public_key` (`pubkey_cert` module) allows a non-CA certificate to be accepted as an intermediate issuer, enabling certificate chain forgery. In `lib/public_key/src/pubkey_cert.erl`, `pubkey_cert:validate_extensions/7` contains two flaws that together allow a certificate with `basicConstraints cA:false` and no `keyUsage` extension to be used as an intermediate issuer in a chain passed to `public_key:pkix_path_validation/3`: the `cA:false` clause recurses into the remaining extensions without rejecting the certificate when it is in issuer position, and the `keyUsage` check only fires when the extension is present, so a certificate lacking `keyUsage` entirely bypasses the `keyCertSign` enforcement. Any party holding an end-entity certificate with `basicConstraints cA:false` and no `keyUsage` extension, issued by any CA in the victim's trust store, can use that certificate's private key to sign forged leaf certificates for arbitrary identities. `public_key:pkix_path_validation/3` accepts the resulting chain, and by extension every TLS or mTLS endpoint built on the OTP `ssl` application that relies on the default verifier is affected, including server identity verification on the client side and client certificate verification on mTLS servers. This issue affects OTP from OTP 17.0 before OTP 27.3.4.19, OTP 28.5.0.8, and OTP 29.1.2, corresponding to public_key from 0.22 before 1.17.1.7, 1.20

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2026-42789
Confirmed fixed CVEs
Not specified
Updated in this feed
30 Oct 2026, 12:15 UTC · Revision 1

Source evidence

Non-CA certificate accepted as intermediate issuer in public_key path validation

core-osv · Original source

Published 27 May 2026, 12:23 UTC

## Summary Improper Following of a Certificate's Chain of Trust vulnerability in Erlang OTP `public_key` (`pubkey_cert` module) allows a non-CA certificate to be accepted as an intermediate issuer, enabling certificate chain forgery. In `lib/public_key/src/pubkey_cert.erl`, `pubkey_cert:validate_extensions/7` contains two flaws that together allow a certificate with `basicConstraints cA:false` and no `keyUsage` extension to be used as an intermediate issuer in a chain passed to `public_key:pkix_path_validation/3`: the `cA:false` clause recurses into the remaining extensions without rejecting the certificate when it is in issuer position, and the `keyUsage` check only fires when the extension is present, so a certificate lacking `keyUsage` entirely bypasses the `keyCertSign` enforcement. Any party holding an end-entity certificate with `basicConstraints cA:false` and no `keyUsage` extension, issued by any CA in the victim's trust store, can use that certificate's private key to sign forged leaf certificates for arbitrary identities. `public_key:pkix_path_validation/3` accepts the resulting chain, and by extension every TLS or mTLS endpoint built on the OTP `ssl` application that relies on the default verifier is affected, including server identity verification on the client side and client certificate verification on mTLS servers. This issue affects OTP from OTP 17.0 before OTP 27.3.4.19, OTP 28.5.0.8, and OTP 29.1.2, corresponding to public_key from 0.22 before 1.17.1.7, 1.20

osv:EEF-CVE-2026-42789
Complete source record
{
  "id": "924ce02fd1ee9c971aeb0646abb051407b05492fdcb1d79acf4ce8da843bebc6",
  "url": "https://osv.dev/vulnerability/EEF-CVE-2026-42789",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "Non-CA certificate accepted as intermediate issuer in public_key path validation",
    "summary": "## Summary Improper Following of a Certificate's Chain of Trust vulnerability in Erlang OTP `public_key` (`pubkey_cert` module) allows a non-CA certificate to be accepted as an intermediate issuer, enabling certificate chain forgery. In `lib/public_key/src/pubkey_cert.erl`, `pubkey_cert:validate_extensions/7` contains two flaws that together allow a certificate with `basicConstraints cA:false` and no `keyUsage` extension to be used as an intermediate issuer in a chain passed to `public_key:pkix_path_validation/3`: the `cA:false` clause recurses into the remaining extensions without rejecting the certificate when it is in issuer position, and the `keyUsage` check only fires when the extension is present, so a certificate lacking `keyUsage` entirely bypasses the `keyCertSign` enforcement. Any party holding an end-entity certificate with `basicConstraints cA:false` and no `keyUsage` extension, issued by any CA in the victim's trust store, can use that certificate's private key to sign forged leaf certificates for arbitrary identities. `public_key:pkix_path_validation/3` accepts the resulting chain, and by extension every TLS or mTLS endpoint built on the OTP `ssl` application that relies on the default verifier is affected, including server identity verification on the client side and client certificate verification on mTLS servers. This issue affects OTP from OTP 17.0 before OTP 27.3.4.19, OTP 28.5.0.8, and OTP 29.1.2, corresponding to public_key from 0.22 before 1.17.1.7, 1.20",
    "evidence": "osv:EEF-CVE-2026-42789",
    "products": [],
    "severity": "high",
    "structured": {
      "id": "EEF-CVE-2026-42789",
      "aliases": [
        "CVE-2026-42789",
        "EEF-CVE-2026-42789",
        "GHSA-c99q-jmpx-v8qq"
      ],
      "metrics": [
        {
          "type": "CVSS_V4",
          "score": "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:L/VA:N/SC:H/SI:H/SA:N"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/erlang/otp",
              "type": "GIT",
              "events": [
                {
                  "introduced": "84adefa331c4159d432d22840663c38f155cd4c1"
                },
                {
                  "fixed": "0a05b7ca33fb0b3f0a6cb9ae34252bb3a74032b8"
                },
                {
                  "fixed": "75ca4c0dc2bbdb286ac3c3fe89cb4b4d2b4dc333"
                },
                {
                  "fixed": "82af606b5437c4de1276dbcc8855a47e88231226"
                }
              ]
            }
          ],
          "versions": [
            "OTP-27.3.4.18",
            "OTP-28.5.0.7",
            "OTP-29.1.1",
            "patch-base-28",
            "OTP-28.5",
            "patch-base-27",
            "OTP-27.3.4",
            "OTP-27.3.4.17",
            "OTP-28.5.0.6",
            "OTP-29.1",
            "OTP-29.0",
            "OTP-27.3.4.9",
            "OTP-27.3.4.10",
            "OTP-28.5.0.2",
            "OTP-28.5.0.5",
            "OTP-27.3.4.14",
            "OTP-27.3.4.16",
            "OTP-27.3.4.15",
            "OTP-28.5.0.4",
            "OTP-28.5.0.3",
            "OTP-27.3.4.13",
            "OTP-28.4",
            "OTP-27.3.4.12",
            "OTP-28.5.0.1",
            "OTP-27.0",
            "OTP-27.3.4.11",
            "OTP-29.0-rc3",
            "OTP-28.0",
            "OTP-29.0-rc2",
            "OTP-27.3.4.8",
            "OTP-27.3.4.6",
            "OTP-27.3.4.7",
            "OTP-29.0-rc1",
            "OTP-27.3",
            "OTP-27.3.4.5",
            "OTP-27.3.4.4",
            "OTP-28.1",
            "OTP-27.3.4.3",
            "OTP-27.3.3",
            "OTP-27.3.4.2",
            "OTP-26.0",
            "OTP-25.0",
            "OTP-27.3.4.1",
            "OTP-28.0-rc4",
            "OTP-27.3.2",
            "OTP-28.0-rc3",
            "OTP-27.2",
            "OTP-28.0-rc2",
            "OTP-27.3.1",
            "OTP-28.0-rc1",
            "OTP-27.1",
            "OTP-27.0-rc3",
            "OTP-27.0-rc2",
            "OTP-27.0-rc1",
            "OTP-24.0",
            "OTP-26.0-rc3",
            "OTP-26.0-rc2",
            "OTP-26.0-rc1",
            "OTP-23.0",
            "OTP-21.0",
            "OTP-25.0-rc3",
            "OTP-25.0-rc2",
            "OTP-25.0-rc1",
            "OTP-22.0",
            "OTP-24.0-rc3",
            "OTP-24.0-rc2",
            "OTP-24.0-rc1",
            "OTP-23.0-rc3",
            "OTP-23.0-rc2",
            "OTP-23.0-rc1",
            "OTP-20.0",
            "OTP-22.0-rc3",
            "OTP-22.0-rc2",
            "OTP-22.0-rc1",
            "OTP-19.0",
            "OTP-21.0-rc2",
            "OTP-18.0",
            "OTP-21.0-rc1",
            "OTP-17.0",
            "OTP-20.0-rc2",
            "OTP-20.0-rc1",
            "OTP-19.0-rc2",
            "OTP-19.0-rc1",
            "OTP_R16B",
            "OTP-18.0-rc1",
            "OTP_17.0-rc2",
            "OTP_17.0-rc1",
            "OTP_R13B03",
            "OTP_R16A_RELEASE_CANDIDATE",
            "OTP_R14B03",
            "OTP_R15B",
            "OTP_R15A",
            "OTP_R14B02",
            "OTP_R14B01",
            "OTP_R14B",
            "OTP_R13B04",
            "OTP_R14A"
          ],
          "database_specific": {
            "source": "https://cna.erlef.org/osv/EEF-CVE-2026-42789.json"
          }
        }
      ],
      "modified": "2026-10-14T17:01:07.895774215Z",
      "provider": "osv",
      "references": [
        "https://github.com/erlang/otp/security/advisories/GHSA-c99q-jmpx-v8qq",
        "https://cna.erlef.org/cves/CVE-2026-42789.html",
        "https://www.erlang.org/doc/system/versions.html#order-of-versions",
        "https://github.com/erlang/otp/commit/0a05b7ca33fb0b3f0a6cb9ae34252bb3a74032b8",
        "https://github.com/erlang/otp/commit/75ca4c0dc2bbdb286ac3c3fe89cb4b4d2b4dc333",
        "https://github.com/erlang/otp/commit/82af606b5437c4de1276dbcc8855a47e88231226"
      ],
      "provider_metadata": {
        "cpe_ids": [
          "cpe:2.3:a:erlang:erlang\\/otp:*:*:*:*:*:*:*:*"
        ],
        "cwe_ids": [
          "CWE-295",
          "CWE-296"
        ],
        "capec_ids": [
          "CAPEC-475"
        ]
      }
    },
    "related_cves": [
      {
        "value": "CVE-2026-42789",
        "evidence": "/aliases"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 316455,
  "published_at": "2026-05-27T12:23:06.355+00:00"
}