---
id: "CVE-2026-65629"
kind: "vulnerability"
aliases: ["CVE-2026-65629"]
title: "jose (Erlang): weak password key derivation exposes exported private keys to cracking"
severity: "high"
cvss: 7.4
epss: null
exploited: false
status: "open"
category: "package"
products: []
ecosystems: []
tags: ["elixir", "erlang", "jose", "jwt", "package"]
not_affected_if: ["default-config", "no-password-key-export"]
published_at: "2026-10-26T20:17:58+00:00"
first_seen_at: "2026-10-26T20:50:18+00:00"
updated_at: "2026-10-26T20:51:37+00:00"
sources: [{"source": "nvd", "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-65629", "first_seen_at": "2026-10-26T20:50:18+00:00"}]
---

# jose (Erlang): weak password key derivation exposes exported private keys to cracking

When jose exports a password-encrypted private key, it hardcodes PBKDF2-HMAC-SHA256 with only 2048 iterations and an 8-byte salt, far below current guidance. An attacker who obtains an exported key blob can crack the export password offline and recover the full private key.

_Summary, check and fix written by a model from the sources; labelled as such._

## How to check

- Check the jose version in the project's lock file (for example `rebar.lock` or `mix.lock`) and see whether it falls in `1.10.0` to before `1.11.13`
- Search the codebase and backups for code calling `jose_jwk:to_der/2` or `JOSE.JWK.to_der/2` with a password

## Fix

- Upgrade jose to `1.11.13` or later
- Rotate any private keys that were exported with a password while an affected version was in use, since exported blobs may already be exposed

## Timeline

- 2026-10-26T20:50:18+00:00 nvd https://nvd.nist.gov/vuln/detail/CVE-2026-65629

## From the sources

Use of Password Hash With Insufficient Computational Effort in the jose library allows an attacker who obtains a password-encrypted private-key export to recover the private key through an offline password-cracking attack.

When jose exports a password-encrypted private key with jose_jwk:to_der/2 (JOSE.JWK.to_der/2), the jose_jwk_der:to_binary/3 function in src/jwk/jose_jwk_der.erl serializes the key as a PKCS#8 EncryptedPrivateKeyInfo using the PBES2 scheme with hardcoded key-derivation parameters: PBKDF2-HMAC-SHA256 with an iteration count of 2048 and an 8-byte (64-bit) random salt. Neither value can be overridden by the caller.

Both values are far below current guidance (OWASP recommends on the order of 600,000 iterations for PBKDF2-HMAC-SHA256, and NIST recommends salts of at least 128 bits), so the key-stretching work factor is roughly 300 times lower than intended and the short salt reduces the cost of precomputation across keys. The symmetric encryption (AES-256-CBC with a 16-byte random IV) is not affected; the weakness is entirely in the derivation strength. An attacker who obtains one of these exported blobs (for example from a backup, configuration repository, object storage, or logs) can mount a cheap offline dictionary or brute-force attack against the export password, and success yields the full private key.

This issue affects jose: from 1.10.0 before 1.11.13.

---

_Free to read at a human pace. An API with keys and an MCP server are in preparation; early access: hello@infrastack.ai_
