Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 545918 (CVE-2015-1821) - <net-misc/chrony-1.31.1: Multiple vulnerabilities (CVE-2015-{1821,1822,1853})
Summary: <net-misc/chrony-1.31.1: Multiple vulnerabilities (CVE-2015-{1821,1822,1853})
Status: RESOLVED FIXED
Alias: CVE-2015-1821
Product: Gentoo Security
Classification: Unclassified
Component: Vulnerabilities (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Security
URL: http://chrony.tuxfamily.org/News.html
Whiteboard: B2 [glsa cve]
Keywords:
Depends on:
Blocks:
 
Reported: 2015-04-08 06:45 UTC by Agostino Sarubbo
Modified: 2015-11-22 14:59 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Agostino Sarubbo gentoo-dev 2015-04-08 06:45:46 UTC
From ${URL} :

7 Apr 2015 : chrony-1.31.1 released

It includes the following security fixes:

Protect authenticated symmetric NTP associations against DoS attacks (CVE-2015-1853)
Fix access configuration with subnet size indivisible by 4 (CVE-2015-1821)
Fix initialization of reply slots for authenticated commands (CVE-2015-1822)
CVE-2015-1853: DoS attack on authenticated symmetric NTP associations

An attacker knowing that NTP hosts A and B are peering with each other (symmetric association) can send a packet with random timestamps to host A with source address of B which will set the NTP state variables on A to the values sent by the attacker. Host A will 
then send on its next poll to B a packet with originate timestamp that doesn't match the transmit timestamp of B and the packet will be dropped. If the attacker does this periodically for both hosts, they won't be able to synchronize to each other.

Authentication using a symmetric key can fully protect against this attack, but in implementations following the NTPv3 (RFC 1305) or NTPv4 (RFC 5905) specification the state variables were updated even when the authentication check failed and the association was 
not protected.

CVE-2015-1821: Heap-based buffer overflow in access configuration

When NTP or cmdmon access was configured (from chrony.conf or via authenticated cmdmon) with a subnet size that is indivisible by 4 and an address that has nonzero bits in the 4-bit subnet remainder (e.g. 192.168.15.0/22 or f000::/3), the new setting was written 
to an incorrect location, possibly outside the allocated array.

An attacker that has the command key and is allowed to access cmdmon (only localhost is allowed by default) could exploit this to crash chronyd or possibly execute arbitrary code with the privileges of the chronyd process.

CVE-2015-1822: Use of uninitialized pointer in command processing

When allocating memory to save unacknowledged replies to authenticated command requests, the last "next" pointer was not initialized to NULL. When all allocated reply slots were used, the next reply could be written to an invalid memory instead of allocating a 
new slot for it.

An attacker that has the command key and is allowed to access cmdmon (only localhost is allowed by default) could exploit this to crash chronyd or possibly execute arbitrary code with the privileges of the chronyd process.


@maintainer(s): after the bump, in case we need to stabilize the package, please let us know if it is ready for the stabilization or not.
Comment 1 Jeroen Roovers (RETIRED) gentoo-dev 2015-04-21 03:57:19 UTC
Arch teams, please test and mark stable:
=net-misc/chrony-1.31.1
Targeted stable KEYWORDS : amd64 arm hppa ppc sparc x86
Comment 2 Jeroen Roovers (RETIRED) gentoo-dev 2015-04-21 04:32:30 UTC
Stable for HPPA.
Comment 3 GLSAMaker/CVETool Bot gentoo-dev 2015-04-22 18:36:12 UTC
CVE-2015-1822 (http://nvd.nist.gov/nvd.cfm?cvename=CVE-2015-1822):
  chrony before 1.31.1 does not initialize the last "next" pointer when saving
  unacknowledged replies to command requests, which allows remote
  authenticated users to cause a denial of service (uninitialized pointer
  dereference and daemon crash) or possibly execute arbitrary code via a large
  number of command requests.

CVE-2015-1821 (http://nvd.nist.gov/nvd.cfm?cvename=CVE-2015-1821):
  Heap-based buffer overflow in chrony before 1.31.1 allows remote
  authenticated users to cause a denial of service (chronyd crash) or possibly
  execute arbitrary code by configuring the (1) NTP or (2) cmdmon access with
  a subnet size that is indivisible by four and an address with a nonzero bit
  in the subnet remainder.
Comment 4 Agostino Sarubbo gentoo-dev 2015-04-23 11:17:59 UTC
amd64 stable
Comment 5 Agostino Sarubbo gentoo-dev 2015-04-23 11:18:41 UTC
x86 stable
Comment 6 Pacho Ramos gentoo-dev 2015-04-26 17:27:30 UTC
ppc stable
Comment 7 Agostino Sarubbo gentoo-dev 2015-04-29 09:19:37 UTC
sparc stable
Comment 8 Jeroen Roovers (RETIRED) gentoo-dev 2015-04-30 15:58:16 UTC
ARM had no stable keyword.
Comment 9 Yury German Gentoo Infrastructure gentoo-dev 2015-05-13 23:35:53 UTC
Arches and Maintainer(s), Thank you for your work.

New GLSA Request filed.
Comment 10 GLSAMaker/CVETool Bot gentoo-dev 2015-07-05 16:24:43 UTC
This issue was resolved and addressed in
 GLSA 201507-01 at https://security.gentoo.org/glsa/201507-01
by GLSA coordinator Mikle Kolyada (Zlogene).