Todd Miller sudo up to 1.8.20 on Linux TTY get_process_ttyname race condition
| CVSS Meta Temp Score | Current Exploit Price (≈) | CTI Interest Score |
|---|---|---|
| 6.7 | $0-$5k | 0.00 |
Summary
A vulnerability identified as critical has been detected in Todd Miller sudo up to 1.8.20 on Linux. This affects the function get_process_ttyname of the component TTY Handler. The manipulation leads to Local Privilege Escalation.
This vulnerability is listed as CVE-2017-1000367. The attack must be carried out locally. In addition, an exploit is available.
You should upgrade the affected component.
Details
A vulnerability, which was classified as critical, has been found in Todd Miller sudo up to 1.8.20 on Linux (Operating System Utility Software). This issue affects the function get_process_ttyname of the component TTY Handler. The manipulation with an unknown input leads to a local privilege escalation vulnerability. Using CWE to declare the problem leads to CWE-362. The product contains a code sequence that can run concurrently with other code, and the code sequence requires temporary, exclusive access to a shared resource, but a timing window exists in which the shared resource can be modified by another code sequence that is operating concurrently. Impacted is confidentiality, integrity, and availability.
The bug was discovered 05/30/2017. The weakness was presented 05/30/2017 with Qualys as Potential overwrite of arbitrary files on Linux as confirmed advisory (Website). The advisory is shared at sudo.ws. The identification of this vulnerability is CVE-2017-1000367. An attack has to be approached locally. A simple authentication is required for exploitation. Technical details as well as a public exploit are known. The advisory points out:
On Linux systems, sudo parses the /proc/[pid]/stat file to determine the device number of the process's tty (field 7). The fields in the file are space-delimited, but it is possible for the command name (field 2) to include spaces, which sudo does not account for. A user with sudo privileges can cause sudo to use a device number of the user's choosing by creating a symbolic link from the sudo binary to a name that contains a space, followed by a number. If SELinux is enabled on the system and sudo was built with SELinux support, a user with sudo privileges may be able to to overwrite an arbitrary file. This can be escalated to full root access by rewriting a trusted file such as /etc/shadow or even /etc/sudoers.
A public exploit has been developed by Qualys Corporation in ANSI C and been published 3 weeks after the advisory. The exploit is available at exploit-db.com. It is declared as proof-of-concept. The vulnerability scanner Nessus provides a plugin with the ID 100644 (Amazon Linux AMI : sudo (ALAS-2017-843)), which helps to determine the existence of the flaw in a target environment. It is running in the context l. The commercial vulnerability scanner Qualys is able to test this issue with plugin 170081 (SUSE Enterprise Linux Security Update for sudo (SUSE-SU-2017:1626-1)).
Upgrading to version 1.8.20p1 eliminates this vulnerability. A possible mitigation has been published 1 weeks after the disclosure of the vulnerability.
The vulnerability is also documented in the databases at Exploit-DB (42183), Tenable (100644), SecurityFocus (BID 98745†) and SecurityTracker (ID 1038582†). seclists.org is providing further details. See VDB-101975 for similar entry. Several companies clearly confirm that VulDB is the primary source for best vulnerability data.
Not Affected
- sudo up to 1.8.6p6
Product
Type
Vendor
Name
Version
- 1.8.0
- 1.8.1
- 1.8.2
- 1.8.3
- 1.8.4
- 1.8.5
- 1.8.6
- 1.8.7
- 1.8.8
- 1.8.9
- 1.8.10
- 1.8.11
- 1.8.12
- 1.8.13
- 1.8.14
- 1.8.15
- 1.8.16
- 1.8.17
- 1.8.18
- 1.8.19
- 1.8.20
License
CPE 2.3
CPE 2.2
Video

CVSSv4
VulDB Vector: 🔍VulDB Reliability: 🔍
CVSSv3
VulDB Meta Base Score: 7.1VulDB Meta Temp Score: 6.7
VulDB Base Score: 7.8
VulDB Temp Score: 7.0
VulDB Vector: 🔍
VulDB Reliability: 🔍
NVD Base Score: 6.4
NVD Vector: 🔍
CVSSv2
| AV | AC | Au | C | I | A |
|---|---|---|---|---|---|
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| Vector | Complexity | Authentication | Confidentiality | Integrity | Availability |
|---|---|---|---|---|---|
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
VulDB Base Score: 🔍
VulDB Temp Score: 🔍
VulDB Reliability: 🔍
NVD Base Score: 🔍
Exploiting
Class: Race conditionCWE: CWE-362
CAPEC: 🔍
ATT&CK: 🔍
Physical: Partially
Local: Yes
Remote: No
Availability: 🔍
Access: Public
Status: Proof-of-Concept
Author: Qualys Corporation
Programming Language: 🔍
Download: 🔍
EPSS Score: 🔍
EPSS Percentile: 🔍
Price Prediction: 🔍
Current Price Estimation: 🔍
| 0-Day | Unlock | Unlock | Unlock | Unlock |
|---|---|---|---|---|
| Today | Unlock | Unlock | Unlock | Unlock |
Nessus ID: 100644
Nessus Name: Amazon Linux AMI : sudo (ALAS-2017-843)
Nessus File: 🔍
Nessus Risk: 🔍
Nessus Family: 🔍
Nessus Context: 🔍
OpenVAS ID: 703867
OpenVAS Name: Debian Security Advisory DSA 3867-1 (sudo - security update)
OpenVAS File: 🔍
OpenVAS Family: 🔍
Qualys ID: 🔍
Qualys Name: 🔍
Exploit-DB: 🔍
Threat Intelligence
Interest: 🔍Active Actors: 🔍
Active APT Groups: 🔍
Countermeasures
Recommended: UpgradeStatus: 🔍
Reaction Time: 🔍
0-Day Time: 🔍
Exposure Time: 🔍
Exploit Delay Time: 🔍
Upgrade: sudo 1.8.20p1
Timeline
06/05/2017 🔍05/30/2017 🔍
05/30/2017 🔍
05/30/2017 🔍
05/30/2017 🔍
05/31/2017 🔍
06/05/2017 🔍
06/06/2017 🔍
06/07/2017 🔍
06/14/2017 🔍
06/14/2017 🔍
06/25/2024 🔍
Sources
Advisory: Potential overwrite of arbitrary files on LinuxResearcher: Qualys Security
Organization: Qualys
Status: Confirmed
Confirmation: 🔍
CVE: CVE-2017-1000367 (🔍)
GCVE (CVE): GCVE-0-2017-1000367
GCVE (VulDB): GCVE-100-101873
OVAL: 🔍
SecurityFocus: 98745 - Sudo '/src/ttyname.c' Local Privilege Escalation Vulnerability
SecurityTracker: 1038582
scip Labs: https://www.scip.ch/en/?labs.20161013
Misc.: 🔍
See also: 🔍
Entry
Created: 05/31/2017 08:34Updated: 06/25/2024 15:41
Changes: 05/31/2017 08:34 (100), 10/20/2019 17:16 (6), 12/26/2020 07:12 (3), 06/25/2024 15:41 (16)
Complete: 🔍
Cache ID: 216::103
Several companies clearly confirm that VulDB is the primary source for best vulnerability data.
No comments yet. Languages: en.
Please log in to comment.