Back

HIGH

zsh: privilege escalation via environment variables

Published Feb 27, 2018

Description

zsh before 5.0.7 allows evaluation of the initial values of integer variables imported from the environment (instead of treating them as literal numbers). That could allow local privilege escalation, under some specific and atypical conditions where zsh is being invoked in privilege-elevation contexts when the environment has not been properly sanitized, such as when zsh is invoked by sudo on systems where "env_reset" has been disabled.

Affected products

Remediation

Red Hat statement

Red Hat Product Security has rated this issue as having security impact of Low. This issue is not currently planned to be addressed in future updates. For additional information, refer to the Issue Severity Classification: https://access.redhat.com/security/updates/classification/.

Red Hat mitigation

Don't allow environment variables 'OPTIND' and 'TRY_BLOCK_ERROR' to be inherited by shells called through zsh. Mitigated by default on Red Hat Enterprise Linux versions 5, 6 and 7, since this is the default configuration on those versions.

Metrics

Weaknesses (2)

References (7)

Change history (0)

No recorded changes yet.

Sources
CVE.org / MITRE
Status PUBLISHED
Assigner mitre
Published Feb 27, 2018
Updated Aug 6, 2024
Reserved Feb 27, 2018
NVD
Status Modified
Modified Jun 17, 2026
Red Hat
Severity Low
Public date Feb 26, 2018