CVE-2019-0217 - Concurrent Execution using Shared Resource with Improper Synchronization ('Race Condition')

Severity

75%

Complexity

16%

Confidentiality

98%

In Apache HTTP Server 2.4 release 2.4.38 and prior, a race condition in mod_auth_digest when running in a threaded server could allow a user with valid credentials to authenticate using another username, bypassing configured access control restrictions.

In Apache HTTP Server 2.4 release 2.4.38 and prior, a race condition in mod_auth_digest when running in a threaded server could allow a user with valid credentials to authenticate using another username, bypassing configured access control restrictions.

CVSS 3.1 Base Score 7.5. CVSS Attack Vector: network. CVSS Attack Complexity: high. CVSS Vector: (CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H).

CVSS 2.0 Base Score 6. CVSS Attack Vector: network. CVSS Attack Complexity: medium. CVSS Vector: (AV:N/AC:M/Au:S/C:P/I:P/A:P).

Demo Examples

Concurrent Execution using Shared Resource with Improper Synchronization ('Race Condition')

CWE-362

This code could be used in an e-commerce application that supports transfers between accounts. It takes the total amount of the transfer, sends it to the new account, and deducts the amount from the original account.


               
NotifyUser("New balance: $newbalance");
FatalError("Bad Transfer Amount");
FatalError("Insufficient Funds");

A race condition could occur between the calls to GetBalanceFromDatabase() and SendNewBalanceToDatabase().

Suppose the balance is initially 100.00. An attack could be constructed as follows:


               
PROGRAM-2 sends a request to update the database, setting the balance to 99.00

At this stage, the attacker should have a balance of 19.00 (due to 81.00 worth of transfers), but the balance is 99.00, as recorded in the database.

To prevent this weakness, the programmer has several options, including using a lock to prevent multiple simultaneous requests to the web application, or using a synchronization mechanism that includes all the code between GetBalanceFromDatabase() and SendNewBalanceToDatabase().

Concurrent Execution using Shared Resource with Improper Synchronization ('Race Condition')

CWE-362

The following function attempts to acquire a lock in order to perform operations on a shared resource.


               
}
pthread_mutex_unlock(mutex);/* access shared resource */

However, the code does not check the value returned by pthread_mutex_lock() for errors. If pthread_mutex_lock() cannot acquire the mutex for any reason, the function may introduce a race condition into the program and result in undefined behavior.

In order to avoid data races, correctly written programs must check the result of thread synchronization functions and appropriately handle all errors, either by attempting to recover from them or reporting it to higher levels.


               
}
return pthread_mutex_unlock(mutex);
return result;
/* access shared resource */

Concurrent Execution using Shared Resource with Improper Synchronization ('Race Condition')

CWE-362

Suppose a processor's Memory Management Unit (MMU) has 5 other shadow MMUs to distribute its workload for its various cores. Each MMU has the start address and end address of "accessible" memory. Any time this accessible range changes (as per the processor's boot status), the main MMU sends an update message to all the shadow MMUs.

Suppose the interconnect fabric does not prioritize such "update" packets over other general traffic packets. This introduces a race condition. If an attacker can flood the target with enough messages so that some of those attack packets reach the target before the new access ranges gets updated, then the attacker can leverage this scenario.

Overview

First reported 5 years ago

2019-04-08 21:29:00

Last updated 5 years ago

2019-12-10 13:15:00

Affected Software

Apache Software Foundation Apache HTTP Server

Debian Linux 8.0 (Jessie)

8.0

Debian Linux 9.0

9.0

Fedora 28

28

Fedora 29

29

Fedora 30

30

Canonical Ubuntu Linux 12.04 ESM (Extended Security Maintenance)

12.04

Canonical Ubuntu Linux 14.04 LTS (Long-Term Support)

14.04

Canonical Ubuntu Linux 16.04 LTS (Long-Term Support)

16.04

Canonical Ubuntu Linux 18.04 LTS Edition

18.04

Canonical Ubuntu Linux 18.10

18.10

Red Hat Enterprise Linux

RedHat Enterprise Linux Desktop 7.0

7.0

RedHat Enterprise Linux Server 7.0

7.0

RedHat Enterprise Linux Workstation 7.0

7.0

openSUSE Leap 15.0

15.0

openSUSE Leap 42.3

42.3

Oracle Enterprise Manager Ops Center 12.3.3

12.3.3

Oracle Enterprise Manager Ops Center 12.4.0

12.4.0

Oracle HTTP Server 12.2.1.3.0

12.2.1.3.0

Oracle Retail Xstore Point Of Service 7.0

7.0

Oracle Retail Xstore Point Of Service 7.1

7.1

References

openSUSE-SU-2019:1190

Mailing List, Third Party Advisory

openSUSE-SU-2019:1209

Mailing List, Third Party Advisory

openSUSE-SU-2019:1258

Mailing List, Third Party Advisory

[oss-security] 20190401 CVE-2019-0217: mod_auth_digest access control bypass

Mailing List, Third Party Advisory

107668

Third Party Advisory, VDB Entry

RHSA-2019:2343

Third Party Advisory

RHSA-2019:3436

Third Party Advisory

RHSA-2019:3932

Third Party Advisory

RHSA-2019:3933

Third Party Advisory

RHSA-2019:3935

Third Party Advisory

RHSA-2019:4126

https://bugzilla.redhat.com/show_bug.cgi?id=1695020

Issue Tracking, Third Party Advisory

https://httpd.apache.org/security/vulnerabilities_24.html

Vendor Advisory

[httpd-cvs] 20190815 svn commit: r1048743 [4/4] - in /websites/staging/httpd/trunk/content: ./ security/vulnerabilities-httpd.xml security/vulnerabilities_13.html security/vulnerabilities_20.html security/vulnerabilities_22.html security/vulnerabilities_24.html

Mailing List, Vendor Advisory

[httpd-cvs] 20190815 svn commit: r1048742 [4/4] - in /websites/staging/httpd/trunk/content: ./ security/vulnerabilities-httpd.xml security/vulnerabilities_13.html security/vulnerabilities_20.html security/vulnerabilities_22.html security/vulnerabilities_24.html

Mailing List, Vendor Advisory

[httpd-dev] 20190402 re: svn commit: r33393 - /release/httpd/CHANGES_2.4

Mailing List, Vendor Advisory

[httpd-cvs] 20200401 svn commit: r1058586 [4/4] - in /websites/staging/httpd/trunk/content: ./ security/vulnerabilities-httpd.xml security/vulnerabilities_13.html security/vulnerabilities_20.html security/vulnerabilities_22.html security/vulnerabilities_24.html

[httpd-cvs] 20200401 svn commit: r1058587 [4/4] - in /websites/staging/httpd/trunk/content: ./ security/vulnerabilities-httpd.xml security/vulnerabilities_13.html security/vulnerabilities_20.html security/vulnerabilities_22.html security/vulnerabilities_24.html

[debian-lts-announce] 20190403 [SECURITY] [DLA 1748-1] apache2 security update

Mailing List, Third Party Advisory

FEDORA-2019-a4ed7400f4

Third Party Advisory

FEDORA-2019-119b14075a

Third Party Advisory

EDORA-2019-cf7695b470

Third Party Advisory

20190403 [SECURITY] [DSA 4422-1] apache2 security update

Issue Tracking, Mailing List, Third Party Advisory

https://security.netapp.com/advisory/ntap-20190423-0001/

Third Party Advisory

https://support.hpe.com/hpsc/doc/public/display?docLocale=en_US&docId=emr_na-hpesbux03950en_us

Third Party Advisory

USN-3937-1

Third Party Advisory

USN-3937-2

Third Party Advisory

DSA-4422

Third Party Advisory

N/A

https://www.oracle.com/technetwork/security-advisory/cpujul2019-5072835.html

Patch, Third Party Advisory

https://www.oracle.com/technetwork/security-advisory/cpuoct2019-5072832.html

Broken Link

Stay updated

ExploitPedia is constantly evolving. Sign up to receive a notification when we release additional functionality.

Get in touch

If you'd like to report a bug or have any suggestions for improvements then please do get in touch with us using this form. We will get back to you as soon as we can.