All reports
Low

zsh: NULL dereference in cd in sh compatibility mode under given circumstances

Affected versions

Affected versions
Unknown
Fixed version
Not reported
Affected versions
Unknown
Fixed version
Not reported

Exploitation

CVE-2017-18205

Probability of exploitation in the next 30 days: 2.04%

FIRST EPSS · 2026-11-22

Description

In builtin.c in zsh before 5.4, when sh compatibility mode is used, there is a NULL pointer dereference during processing of the cd command with no argument if HOME is not set.

A NULL pointer dereference flaw was found in the code responsible for the cd builtin command of the zsh package. An attacker could use this flaw to cause a denial of service by crashing the user shell.