Bug 1271076 (CVE-2015-5300) - CVE-2015-5300 ntp: MITM attacker can force ntpd to make a step larger than the panic threshold
Summary: CVE-2015-5300 ntp: MITM attacker can force ntpd to make a step larger than th...
Keywords:
Status: CLOSED ERRATA
Alias: CVE-2015-5300
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
URL:
Whiteboard:
Depends On: 1272152 1272153 1272154 1272155 1274165
Blocks: 1260670
TreeView+ depends on / blocked
 
Reported: 2015-10-13 06:34 UTC by Martin Prpič
Modified: 2021-08-11 12:55 UTC (History)
7 users (show)

Fixed In Version: ntp 4.2.8p4
Doc Type: Bug Fix
Doc Text:
It was found that ntpd did not correctly implement the threshold limitation for the '-g' option, which is used to set the time without any restrictions. A man-in-the-middle attacker able to intercept NTP traffic between a connecting client and an NTP server could use this flaw to force that client to make multiple steps larger than the panic threshold, effectively changing the time to an arbitrary value at any time.
Clone Of:
Environment:
Last Closed: 2015-11-26 14:27:51 UTC
Embargoed:


Attachments (Terms of Use)
CVE-2015-5300 patch (362 bytes, patch)
2015-10-13 06:35 UTC, Martin Prpič
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2015:1930 0 normal SHIPPED_LIVE Important: ntp security update 2015-10-27 01:22:37 UTC

Description Martin Prpič 2015-10-13 06:34:45 UTC
It was found that ntpd did not correctly implement the -g option:

-g   Normally, ntpd exits with a message to the system log if the offset exceeds the panic threshold, which is 1000 s by default. This option allows the time to be set to any value without restriction; however, this can happen only once. If the thresh‐ old is exceeded after that, ntpd will exit with a message to the system log. This option can be used with the -q and -x options. See the tinker command for other options.

ntpd could actually step the clock multiple times by more than the panic threshold if its clock discipline doesn't have enough time to reach the sync state and stay there for at least one update. If a man-in-the-middle attacker can control the NTP traffic since ntpd was started (or maybe up to 15-30 minutes after that), they can prevent the client from reaching the sync state and force it to step its clock by any amount any number of times, which can be used by attackers to expire certificates, etc.

This is contrary to what the documentation says. Normally, the assumption is that an MITM attacker can step the clock more than the panic threshold only once when ntpd starts and to make a larger adjustment the attacker has to divide it into multiple smaller steps, each taking 15 minutes, which is slow.

Comment 1 Martin Prpič 2015-10-13 06:35:26 UTC
Created attachment 1082271 [details]
CVE-2015-5300 patch

Comment 8 Martin Prpič 2015-10-22 07:39:03 UTC
External References:

https://www.cs.bu.edu/~goldbe/NTPattack.html

Comment 9 Martin Prpič 2015-10-22 07:40:18 UTC
Created ntp tracking bugs for this issue:

Affects: fedora-all [bug 1274166]

Comment 10 errata-xmlrpc 2015-10-26 21:23:43 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7
  Red Hat Enterprise Linux 6

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

Comment 11 Fedora Update System 2015-11-02 18:53:15 UTC
ntp-4.2.6p5-34.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.

Comment 12 Fedora Update System 2015-11-04 22:49:50 UTC
ntp-4.2.6p5-34.fc21 has been pushed to the Fedora 21 stable repository. If problems still persist, please make note of it in this bug report.

Comment 15 Martin Prpič 2015-12-01 08:26:35 UTC
Statement:

Red Hat Enterprise Linux 5 is now in Production 3 Phase of the support and maintenance life cycle. This has been rated as having Moderate 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/

Comment 17 ashu.cs178 2016-01-05 17:22:40 UTC
Hi,

This CVE-2015-5300  patch is applicable for 4.2.6.

but there is no fix available for 4.2.8.

Even  4.2.8p4's change log doesn't mention about this issue.

So what it is fix for NTP 4.2.8 version.


thanks 
Ashish

Comment 18 Kurt Seifried 2016-01-05 17:27:45 UTC
(In reply to ashu.cs178 from comment #17)
> Hi,
> 
> This CVE-2015-5300  patch is applicable for 4.2.6.
> 
> but there is no fix available for 4.2.8.
> 
> Even  4.2.8p4's change log doesn't mention about this issue.
> 
> So what it is fix for NTP 4.2.8 version.
> 
> 
> thanks 
> Ashish

You will need to contact ntp.org upstream and ask them, I checked http://support.ntp.org/bin/view/Main/SecurityNotice#October_2015_NTP_Security_Vulner and it doesn't mention CVE-2015-5300 unfortunately.

Comment 19 Fedora Update System 2016-02-21 02:25:35 UTC
ntp-4.2.6p5-36.fc22 has been pushed to the Fedora 22 stable repository. If problems still persist, please make note of it in this bug report.


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