FreeBSD : sudo -- Privilege escalation with sudoedit (018a84d0-2548-11df-b4a3-00e0815b8da8)

medium Nessus Plugin ID 44952

Language:

Synopsis

The remote FreeBSD host is missing a security-related update.

Description

Todd Miller reports :

When sudo performs its command matching, there is a special case for pseudo-commands in the sudoers file (currently, the only pseudo-command is sudoedit). Unlike a regular command, pseudo-commands do not begin with a slash ('/'). The flaw is that sudo's the matching code would only check against the list of pseudo-commands if the user-specified command also contained no slashes. As a result, if the user ran 'sudo ./sudoedit' the normal matching code path was followed, which uses stat(2) to verify that the user-specified command matches the one in sudoers. In this case, it would compare the './sudoedit' specified by the user with 'sudoedit' from the sudoers file, resulting in a positive match.

Solution

Update the affected package.

See Also

https://www.sudo.ws/pipermail/sudo-announce/2010-February/000092.html

https://www.sudo.ws/sudo/alerts/sudoedit_escalate.html

http://www.nessus.org/u?ebcbf854

Plugin Details

Severity: Medium

ID: 44952

File Name: freebsd_pkg_018a84d0254811dfb4a300e0815b8da8.nasl

Version: 1.15

Type: local

Published: 3/2/2010

Updated: 1/6/2021

Supported Sensors: Nessus

Risk Information

VPR

Risk Factor: High

Score: 7.4

CVSS v2

Risk Factor: Medium

Base Score: 6.9

Temporal Score: 5.7

Vector: CVSS2#AV:L/AC:M/Au:N/C:C/I:C/A:C

Vulnerability Information

CPE: p-cpe:/a:freebsd:freebsd:sudo, cpe:/o:freebsd:freebsd

Required KB Items: Host/local_checks_enabled, Host/FreeBSD/release, Host/FreeBSD/pkg_info

Exploit Available: true

Exploit Ease: Exploits are available

Patch Publication Date: 3/1/2010

Vulnerability Publication Date: 1/29/2010

Exploitable With

Core Impact

Reference Information

CVE: CVE-2010-0426

BID: 38362

CWE: 264

Secunia: 38659