REDHAT-BUG-598154: Medium severity Sudo Sudo vulnerability

Published May 31, 2010
·
Updated

Anders Kaseorg and Evan Broder reported a flaw in the way sudo handled duplicated environment variables. When sudo set certain environment variables (such as PATH set to securepath value, or special sudo environment variables SUDO), the value overwrote first value from user's environment (if it had been preserved and had not removed previously due to envreset / envkeep / envdelete settings), but left following environment variables with the same name unchanged.

This problem can be used to override securepath setting from /etc/sudoers file for shell scripts executed using sudo, as bash uses last PATH environment variable value. In configurations where securepath is used to enforce sane PATH setting for shell scripts, this can allow users with the privileges to run some script using sudo to run arbitrary command with the privileges of the target user.

Upstream fixes to handle duplicated environment variables: http://www.sudo.ws/repos/sudo/rev/3057fde43cf0 http://www.sudo.ws/repos/sudo/rev/a09c6812eaec

This issue affects sudo packages shipped in Red Hat Enterprise Linux 5, however not the default configuration. In default configuration, no securepath is set. envreset is used by default, and PATH is not preserved during the environment reset (unlike the upstream sudo default).

The sudo packages in Red Hat Enterprise Linux 3 and 4 do not allow setting securepath in the /etc/sudoers, there is no compile-time default for the securepath either. Whether the user PATH setting is preserved depends on envreset / envdelete configuration.

Current Fedora configuration specifies securepath, but also removes PATH from the environment by default.

Affected Software

1 affected component
Sudo Sudo

Event History

May 31, 2010
Data Sourced
via Red Hat·03:19 PM
DescriptionSeverityAffected Software

Frequently Asked Questions

1

What is the severity of REDHAT-BUG-598154?

The severity of REDHAT-BUG-598154 has not been explicitly defined, but it relates to improper handling of environment variables which could impact security.

2

How do I fix REDHAT-BUG-598154?

To fix REDHAT-BUG-598154, update your sudo package to the latest version provided by your distribution.

3

Which versions of software are affected by REDHAT-BUG-598154?

REDHAT-BUG-598154 affects Red Hat Enterprise Linux versions 3, 4, 5, and Fedora.

4

What is the nature of the vulnerability in REDHAT-BUG-598154?

The vulnerability in REDHAT-BUG-598154 involves sudo improperly handling duplicated environment variables.

5

Can REDHAT-BUG-598154 lead to privilege escalation?

Yes, REDHAT-BUG-598154 could potentially lead to privilege escalation due to the mismanagement of environment variables.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203