Bug 1184573 (CVE-2014-9297, CVE-2014-9750) - CVE-2014-9297 CVE-2014-9750 ntp: vallen in extension fields are not validated
Summary: CVE-2014-9297 CVE-2014-9750 ntp: vallen in extension fields are not validated
Keywords:
Status: CLOSED ERRATA
Alias: CVE-2014-9297, CVE-2014-9750
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
low
low
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
URL:
Whiteboard:
: 1189406 (view as bug list)
Depends On: 1189412 1193501 1221565
Blocks: 1184574 1189411 1193283 1210268
TreeView+ depends on / blocked
 
Reported: 2015-01-21 16:58 UTC by Vasyl Kaigorodov
Modified: 2021-02-17 05:46 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
A stack-based buffer overflow was found in the way the NTP autokey protocol was implemented. When an NTP client decrypted a secret received from an NTP server, it could cause that client to crash.
Clone Of:
Environment:
Last Closed: 2019-06-08 02:38:23 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2015:1459 0 normal SHIPPED_LIVE Moderate: ntp security, bug fix, and enhancement update 2015-07-21 14:15:04 UTC
Red Hat Product Errata RHSA-2015:2231 0 normal SHIPPED_LIVE Moderate: ntp security, bug fix, and enhancement update 2015-11-19 09:03:04 UTC

Description Vasyl Kaigorodov 2015-01-21 16:58:37 UTC
It was reported [1] that ntp miss validation of vallen value, leading to various info leaks:

* ntpd/ntp_crypto.c:571
* ntpd/ntp_crypto.c:1162
* ntpd/ntp_crypto.c:1559
* ntpd/ntp_crypto.c:2117
* ntpd/ntp_crypto.c:1461

Upstream commits that fixes this:
http://bk.ntp.org/ntp-stable/?PAGE=patch&REV=5492d353ncauuWt_PONxaDhC5Qv_SA
http://bk1.ntp.org/ntp-stable/?PAGE=patch&REV=54abb266In81wLNAqIaovtP8f2UmUw
http://bk1.ntp.org/ntp-stable/?PAGE=patch&REV=54a7c595jlwS3KmAxBML75HFGLR_pQ

[1]: http://bugs.ntp.org/2671

Comment 5 Martin Prpič 2015-02-05 09:49:26 UTC
*** Bug 1189406 has been marked as a duplicate of this bug. ***

Comment 6 Martin Prpič 2015-02-05 09:52:36 UTC
External References:

http://support.ntp.org/bin/view/Main/SecurityNotice#vallen_is_not_validated_in_sever

Comment 11 Fedora Update System 2015-02-15 03:17:19 UTC
ntp-4.2.6p5-20.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 12 Fedora Update System 2015-02-15 03:25:36 UTC
ntp-4.2.6p5-27.fc21 has been pushed to the Fedora 21 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 16 Huzaifa S. Sidhpurwala 2015-04-09 06:52:54 UTC
The vulnerable code is a part of the NTP autokey protocol. The client sends a public RSA key to the server, which encrypts a 32 bit secret and sends it back to the client. The client then decrypts it and stores it in a 32 bit integer temp32, However, the decrypted cleartext can be up to (keysize/8)-42 in size (e.g. 214 bytes for a 2048 bit key), which can result in a stack based buffer overflow.

There are two factors which cause this issue to have low security impact:

1. "autokey" needs to be explicitly enabled by generated a key using "ntp-keygen" utility and adding the following to the config file:

crypto pw serverpassword
keysdir /etc/ntp

A mitigation is to disable autokey protocol, until this vulnerability is patched.

2. By default, the version of "ntp-keygen" utility shipped with Red Hat Enterprise Linux generate 512-bit RSA keys. Depending on the arch, this may overwrite upto 18 bytes on the stack and does not seem to cause any significant security impact.

Comment 17 Huzaifa S. Sidhpurwala 2015-04-09 06:54:27 UTC
Statement:

This issue affects the versions of ntp as shipped with Red Hat Enterprise Linux 5.

Red Hat Enterprise Linux 5 is now in Production 3 Phase of the support and maintenance life cycle. This has been rated as having Low security impact and is not currently planned to be addressed in future updates. For additional information, refer to the Red Hat Enterprise Linux Life Cycle: https://access.redhat.com/support/policy/updates/errata/.

A mitigation for Red Hat Enterprise Linux 6 and 7 is available at: https://bugzilla.redhat.com/show_bug.cgi?id=1184573#c16

Comment 19 errata-xmlrpc 2015-07-22 07:00:26 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 6

Via RHSA-2015:1459 https://rhn.redhat.com/errata/RHSA-2015-1459.html

Comment 22 Tomas Hoger 2015-10-15 20:16:16 UTC
The CVE-2014-9297 (and CVE-2014-9298) was rejected, apparently because of an incorrect use on some unspecified place, where ids were ids were probably swapped.  CVE-2014-9750 is now expected to be used for the issue the CVE-2014-9297 previously referred to.  This bug report was previously updated to replace rejected CVE id with the new one.  However, as the rejected id was already used in a released RHSA and is still the only id listed on the upstream security pages, I'm re-adding the rejected id here.  Released RHSA erratum was updated to also list the new CVE id as fixed.

Comment 23 errata-xmlrpc 2015-11-19 08:37:53 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7

Via RHSA-2015:2231 https://rhn.redhat.com/errata/RHSA-2015-2231.html


Note You need to log in before you can comment on or make changes to this bug.