Skip to content
FlawDB
Sign in
Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

CVE-2026-105963

MEDIUM 5.1EPSS 49%

Secret key base exposed in stack trace arguments on wrong-typed Plug.Crypto arguments

Mitigation

  • Upgrade plug to 1.7.0 or later.
  • Upgrade plug_crypto to 2.2.1 or later.
  • Upgrade plug_crypto to 981887493dada0fce7003c61861c00dfbb0fc8c5 or later.
  • Vendor workaround: Check argument types in the calling code before entering Plug.Crypto, so no head guard ever fails. Pass a token to Phoenix.Token.verify/4, Phoenix.Token.decrypt/4, Plug.Crypto.verify/4 or Plug.Crypto.decrypt/4 only when is_binary(token) holds, and treat anything else as an invalid token. Call Plug.Crypto.secure_compare/2 only when both operands are binaries, treating a missing header or parameter as a failed comparison rather than passing nil.
  • Where the leaked value matters more than the crash, configuring the error tracker to drop stack-frame arguments also keeps the secret out of the forwarded report. For Sentry this means not sending vars with the crash report. This narrows exposure but leaves the value in the local error log.

Who should check

  • Anyone running elixir-plug plug >= 1.6.3, < 1.7.0
  • Anyone running elixir-plug plug >= 56000c33d8a0a2fbac491f8be06b9c5112bc2276, < *
  • Anyone running elixir-plug plug_crypto >= 1.0.0, < 2.2.1
  • Anyone running elixir-plug plug_crypto >= 2d078b7b8264c565f0ff71235c515f4f46882dcf, < 981887493dada0fce7003c61861c00dfbb0fc8c5

Vulnerability facts

Affected
elixir-plug plug >= 1.6.3, < 1.7.0; elixir-plug plug >= 56000c33d8a0a2fbac491f8be06b9c5112bc2276, < *; elixir-plug plug_crypto >= 1.0.0, < 2.2.1; elixir-plug plug_crypto >= 2d078b7b8264c565f0ff71235c515f4f46882dcf, < 981887493dada0fce7003c61861c00dfbb0fc8c5
Fixed in
elixir-plug plug 1.7.0, elixir-plug plug_crypto 2.2.1, elixir-plug plug_crypto 981887493dada0fce7003c61861c00dfbb0fc8c5
Exploited in the wild
Not in CISA KEV
Public exploit / PoC
None known
Remote exploitation
Remote, login needed
CVSS
5.1 (v4.0, CNA)CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:NOpen in CVSS calculator
Show all 11 CVSS metrics
  • Attack vector: Network
  • Attack complexity: Low
  • Attack requirements: None
  • Privileges required: High
  • User interaction: None
  • Confidentiality impact: Low
  • Integrity impact: None
  • Availability impact: None
  • Confidentiality impact on other systems: None
  • Integrity impact on other systems: None
  • Availability impact on other systems: None
EPSS
0.71% chance of exploitation in 30 days (percentile 49, 2026-11-26)
CWE
CWE-532
Published
Modified

Description

Externally-Generated Error Message Containing Sensitive Information vulnerability in plug_crypto in elixir-plug plug_crypto allows an unauthenticated remote attacker to expose the secret key base through application logs via a wrong-typed argument. Every public function in Plug.Crypto validates argument types in a function-head guard. A failed guard makes the Erlang VM raise FunctionClauseError with the actual argument values in the top stack frame, so the secret key base, a derived key, or the value an API key is compared against lands in that frame. The library's rescue blocks and Plug.Crypto.prune_args_from_stacktrace/1 only reach exceptions raised inside a function body, so they never see a guard failure. Plug.Cowboy and Bandit write the frame to the error log and attach it as crash_reason Logger metadata, which error trackers forward. Two entry points take request data. Plug.Crypto.verify/4 exposes the secret key base when the token is neither a binary nor nil, which Phoenix.Token.verify/4 reaches because it forwards the token unguarded. Plug.Crypto.secure_compare/2 exposes the other operand when one side is not a binary, as happens when a missing request header yields nil. Reading the leaked value needs separate access to the logs or the error tracker, so the request alone does not disclose the secret to the attacker. This issue affects plug: from 1.6.3 before 1.7.0; plug_crypto: from 1.0.0 before 2.2.1.

Affected and fixed versions

Package / productAffectedFixedSource
elixir-plug plug>= 1.6.3, < 1.7.0—cvelist
elixir-plug plug>= 56000c33d8a0a2fbac491f8be06b9c5112bc2276, < *—cvelist
elixir-plug plug_crypto>= 1.0.0, < 2.2.1—cvelist
elixir-plug plug_crypto>= 2d078b7b8264c565f0ff71235c515f4f46882dcf, < 981887493dada0fce7003c61861c00dfbb0fc8c5—cvelist

Check your systems with an agent

Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.

Check whether anything I run is affected by CVE-2026-105963. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2026-105963.md
Affected: elixir-plug plug >= 1.6.3, < 1.7.0; elixir-plug plug >= 56000c33d8a0a2fbac491f8be06b9c5112bc2276, < *; elixir-plug plug_crypto >= 1.0.0, < 2.2.1; elixir-plug plug_crypto >= 2d078b7b8264c565f0ff71235c515f4f46882dcf, < 981887493dada0fce7003c61861c00dfbb0fc8c5
Fixed in: elixir-plug plug 1.7.0, elixir-plug plug_crypto 2.2.1, elixir-plug plug_crypto 981887493dada0fce7003c61861c00dfbb0fc8c5

Steps:
1. Search this machine and project for elixir-plug plug, elixir-plug plug_crypto: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.

References

FAQ

Is CVE-2026-105963 being exploited?

There is no confirmed exploitation: CVE-2026-105963 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.71% chance of exploitation in the next 30 days (as of 2026-11-26).

How serious is CVE-2026-105963?

Medium: CVSS 5.1 (v4.0, scored by CNA). Remote, login needed.

Which versions are affected by CVE-2026-105963?

elixir-plug plug >= 1.6.3, < 1.7.0; elixir-plug plug >= 56000c33d8a0a2fbac491f8be06b9c5112bc2276, < *; elixir-plug plug_crypto >= 1.0.0, < 2.2.1; elixir-plug plug_crypto >= 2d078b7b8264c565f0ff71235c515f4f46882dcf, < 981887493dada0fce7003c61861c00dfbb0fc8c5.

Is there a fix for CVE-2026-105963?

Yes. Fixed in elixir-plug plug 1.7.0, elixir-plug plug_crypto 2.2.1, elixir-plug plug_crypto 981887493dada0fce7003c61861c00dfbb0fc8c5. Upgrade plug to 1.7.0 or later. Upgrade plug_crypto to 2.2.1 or later. Upgrade plug_crypto to 981887493dada0fce7003c61861c00dfbb0fc8c5 or later. Vendor workaround: Check argument types in the calling code before entering Plug.Crypto, so no head guard ever fails. Pass a token to Phoenix.Token.verify/4, Phoenix.Token.decrypt/4, Plug.Crypto.verify/4 or Plug.Crypto.decrypt/4 only when is_binary(token) holds, and treat anything else as an invalid token. Call Plug.Crypto.secure_compare/2 only when both operands are binaries, treating a missing header or parameter as a failed comparison rather than passing nil. Where the leaked value matters more than the crash, configuring the error tracker to drop stack-frame arguments also keeps the secret out of the forwarded report. For Sentry this means not sending vars with the crash report. This narrows exposure but leaves the value in the local error log.

How do I check if I'm affected by CVE-2026-105963?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

Sponsors