All vulnerabilities

Go

CVE-2026-121716

fzf: Arbitrary command execution via bash arithmetic expansion on unvalidated layout size in fzf-tmux (-l/-u attached value)

Severity
High 7.0
Published
19 Nov 2026
Last changed
19 Nov 2026
Added to UpHeron
23 Nov 2026
Fixed in
0.74.5
Exploit chance
0.3% in the next 30 daysHigher than 17% of CVEs. EPSS by FIRST, 24 Nov 2026
Weakness
OS command injection (CWE-78)
Attack
Needs local access · Only under certain conditions · No login needed · Needs someone to click or open something
Attacker can
Read data · Change data · Take it down
CVSS vector
CVSS:3.1/AV:L/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H
Also known as
GHSA-w6x2-f5m4-xw82
Sources
OSV.dev and GitHub

Description

bin/fzf-tmux fails to validate layout size values given in the attached form (e.g. -l50). For -l/-u these values reach bash arithmetic expansion ($(( max - size ))), where an operand like a[$(cmd)] executes cmd as the invoking user during option parsing — before any tmux interaction and even outside tmux. A second sink embeds unvalidated popup geometry (-x/-y/-w/-h/-p) into an unquoted tmux popup ... $opt ... invocation, allowing injection of tmux flags such as -e BASH_ENV= (command execution via non-interactive bash sourcing $BASH_ENV).

In bin/fzf-tmux (tag 0.74.4, commit a140afeb), the option parser validates size values with a regex (^[0-9%,]+$ / ^[A-Z]$) only for the separate-argument form (line 82). The attached form is captured unvalidated at line 80:

For -l and -u, swap is non-empty (lines 68/75), so size reaches arithmetic evaluation:

From the GitHub Advisory Database, CC BY 4.0. Shortened; the full text is there.

Affected software

SoftwareAffected versions
github.com/junegunn/fzfGo · osv:Go:github.com/junegunn/fzf
  • Every version before 0.74.5

About github.com/junegunn/fzf

Vulnerabilities in github.com/junegunn/fzf

In our list
2
Published in the last 12 months
2
Critical, last 12 months
0
High, last 12 months
1
Known exploited
0
Search the list for github.com/junegunn/fzf

References