Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 515268 - <x11-misc/x11vnc-0.9.13_p20150111, <net-libs/libvncserver-0.9.10-r1: LZO Denial of Service and Arbitrary Code Execution through embedded code (CVE-2014-4607)
Summary: <x11-misc/x11vnc-0.9.13_p20150111, <net-libs/libvncserver-0.9.10-r1: LZO Deni...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Security
Classification: Unclassified
Component: Vulnerabilities (show other bugs)
Hardware: All Linux
: Normal minor (vote)
Assignee: Gentoo Security
URL: http://seclists.org/oss-sec/2014/q2/676
Whiteboard: B3 [noglsa]
Keywords:
Depends on: CVE-2014-6051
Blocks: CVE-2014-4607
  Show dependency tree
 
Reported: 2014-06-27 01:04 UTC by Yury German
Modified: 2016-06-04 14:34 UTC (History)
3 users (show)

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


Attachments
x11vnc-0.9.13_p20150111.ebuild (x11vnc-0.9.13_p20150111.ebuild,1.46 KB, text/plain)
2015-04-22 18:11 UTC, Alex Xu (Hello71)
no flags Details
x11vnc-0.9.13_p20150111.ebuild v2 (x11vnc-0.9.13_p20150111.ebuild,1.38 KB, text/plain)
2015-04-22 18:17 UTC, Alex Xu (Hello71)
no flags Details
x11vnc-0.9.13_p20150111.ebuild v3 (x11vnc-0.9.13_p20150111.ebuild,1.39 KB, text/plain)
2015-04-23 14:06 UTC, Alex Xu (Hello71)
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Yury German Gentoo Infrastructure gentoo-dev 2014-06-27 01:04:41 UTC
It is suspected that this package is vulnerable to a security vulnerability in LZO. As such we ask maintainers with packages suspected to be vulnerable to verify if the package is (or have been) affected. 

Please see the information contained in the tracker bug 515246. "An integer overflow may occur when processing any variant of a "literal run" in the lzo1x_decompress_safe function. Each of these three locations is subject to an integer overflow when processing zero bytes.", additional information about the upstream vulnerability is available at http://seclists.org/oss-sec/2014/q2/665


Reproducible: Didn't try
Comment 1 Alex Xu (Hello71) 2014-06-27 12:20:43 UTC
if necessary, we can patch this locally by just copying in LZO from upstream; chances of regression are slim afaik.
Comment 2 Alex Xu (Hello71) 2014-11-24 03:26:04 UTC
upstream bug was resolved, but some funky stuff seems to have happened with the releases and the project was moved somewhere along the way and the build system was rewritten or something like that.
Comment 3 Alex Xu (Hello71) 2014-11-24 03:39:27 UTC
I'm calling this a C3 because:
1) it only applies where the attacker can control the VNC connection (meaning already authenticated)
2) generally the configuration is that x11vnc runs with user privileges
3) typically an authenticated user can already perform actions at the privilege of the x11vnc user, which means they can already execute code or kill x11vnc.
4) there is no evidence of a RCE being feasible with just LZO, let alone how it is used in libvncserver.

feel free to correct if any of the above assumptions are incorrect.
Comment 4 Alex Xu (Hello71) 2015-04-05 16:46:05 UTC
oops.
Comment 5 Yury German Gentoo Infrastructure gentoo-dev 2015-04-06 04:29:30 UTC
Alex look at the Vulnerability treatment policy. We just assign the whiteboard based on the vulnerability and not the method of attack. Or the frequency of use.

The B = Pulled in by default.
Since net-libs/libvncserver is pulled in by: kde-base/krdc and since that is pulled in by default by kde-base/kdenetwork-meta without the user knowing it is a B.
Comment 6 Alex Xu (Hello71) 2015-04-22 18:11:13 UTC
Created attachment 401824 [details]
x11vnc-0.9.13_p20150111.ebuild

new x11vnc required because all x11vnc releases bundle libvncserver.
Comment 7 Alex Xu (Hello71) 2015-04-22 18:17:00 UTC
Created attachment 401826 [details]
x11vnc-0.9.13_p20150111.ebuild v2

please review and commit.
Comment 8 Ian Delaney (RETIRED) gentoo-dev 2015-04-23 08:09:55 UTC
(In reply to Alex Xu (Hello71) from comment #7)
> Created attachment 401826 [details]
> x11vnc-0.9.13_p20150111.ebuild v2
> 
> please review and commit.

ebuild manages

~/cvsPortage/gentoo-x86/x11-misc/x11vnc $ ebuild x11vnc-0.9.13_p20150111.ebuild clean install

>>> Completed installing x11vnc-0.9.13_p20150111 into /mnt/gen2/TmpDir/portage/x11-misc/x11vnc-0.9.13_p20150111/image/

strip: x86_64-pc-linux-gnu-strip --strip-unneeded -R .comment -R .GCC.command.line -R .note.gnu.gold-version
   usr/bin/x11vnc
ecompressdir: bzip2 -9 /usr/share/doc
ecompressdir: bzip2 -9 /usr/share/man

repoman full yields

RepoMan scours the neighborhood...
  KEYWORDS.dropped              1
   x11-misc/x11vnc/x11vnc-0.9.13_p20150111.ebuild: arm64
  dependency.missingslot        3
   x11-misc/x11vnc/x11vnc-0.9.13-r1.ebuild: RDEPEND: 'dev-libs/openssl' matches more than one slot, please specify an explicit slot and/or use the := or :* slot operator
   x11-misc/x11vnc/x11vnc-0.9.13-r1.ebuild: RDEPEND: 'dev-lang/tk' matches more than one slot, please specify an explicit slot and/or use the := or :* slot operator
   x11-misc/x11vnc/x11vnc-0.9.13_p20150111.ebuild: RDEPEND: 'dev-libs/openssl' matches more than one slot, please specify an explicit slot and/or use the := or :* slot operator

1. Simply re-add arm64 to KEYWORDS
2. I believe the use of := would be fine for dev-libs/openssl, dev-lang/tk
Comment 9 Ian Delaney (RETIRED) gentoo-dev 2015-04-23 08:15:13 UTC
(hit return unintentionally)

 & dev-libs/openssl.
3. KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~arm-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris"
could also re reduced after adding arm64 however this would be an option at your discretion.  Some of these are defunct or excess to arches that likely really need them.
Comment 10 Alex Xu (Hello71) 2015-04-23 14:06:14 UTC
Created attachment 401866 [details]
x11vnc-0.9.13_p20150111.ebuild v3
Comment 11 Ian Delaney (RETIRED) gentoo-dev 2015-04-24 00:47:10 UTC
ah;  dev-lang/tk came from x11vnc-0.9.13-r1.ebuild so I ought not have included that.

*x11vnc-0.9.13_p20150111 (24 Apr 2015)

  24 Apr 2015; Ian Delaney <idella4@gentoo.org> +x11vnc-0.9.13_p20150111.ebuild:
  bump wrt bug #515268, runtests fine
Comment 12 Alex Xu (Hello71) 2015-04-24 23:26:08 UTC
(In reply to Ian Delaney from comment #9)
> (hit return unintentionally)
> 
>  & dev-libs/openssl.
> 3. KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh
> ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~arm-linux ~x86-linux
> ~sparc-solaris ~x64-solaris ~x86-solaris"
> could also re reduced after adding arm64 however this would be an option at
> your discretion.  Some of these are defunct or excess to arches that likely
> really need them.

actually, the keywords don't even make sense because libvncserver is a mandatory dep now. you can drop ~arm64, ~x86-interix, *-solaris.

dlan, if you want it on arm64, then test libvncserver with x11vnc and keyword both together.

I don't know when the interix/solaris keywords were added, so I can't tell whoever did it.
Comment 13 Alex Xu (Hello71) 2015-04-28 22:03:59 UTC
x11-misc/x11vnc-0.9.13_p20150111:

target keywords: alpha amd64 arm hppa ia64 ppc ppc64 s390 sh sparc x86

note: arm64 not required but dlan you can add if you want.

libvncserver stabilization continues in bug 523590.
Comment 14 Jeroen Roovers (RETIRED) gentoo-dev 2015-04-29 04:34:29 UTC
Stable for PPC64.
Comment 15 Jeroen Roovers (RETIRED) gentoo-dev 2015-04-29 04:58:32 UTC
Stable for HPPA.
Comment 16 Agostino Sarubbo gentoo-dev 2015-04-30 10:56:39 UTC
amd64 stable
Comment 17 Pacho Ramos gentoo-dev 2015-05-15 11:54:59 UTC
ppc stable
Comment 18 Agostino Sarubbo gentoo-dev 2015-05-19 07:26:25 UTC
x86 stable
Comment 19 Markus Meier gentoo-dev 2015-05-21 16:20:20 UTC
arm stable
Comment 20 Alex Xu (Hello71) 2015-05-21 16:44:48 UTC
glsa in bug 523590
Comment 21 Alex Xu (Hello71) 2015-05-31 20:15:19 UTC
bleh, mixed this up with the other one.
Comment 22 Agostino Sarubbo gentoo-dev 2015-06-17 08:58:46 UTC
sparc stable
Comment 23 Agostino Sarubbo gentoo-dev 2015-07-03 08:56:49 UTC
alpha stable
Comment 24 Agostino Sarubbo gentoo-dev 2015-09-24 08:02:56 UTC
ia64 stable.

Maintainer(s), please cleanup.
Security, please vote.
Comment 25 Ian Delaney (RETIRED) gentoo-dev 2015-09-26 15:22:16 UTC
Author: Ian Delaney <idella4@gentoo.org>
Date:   Sat Sep 26 23:21:06 2015 +0800

    x11-misc/x11vnc: rm old, clean up for sec bug #515268
Comment 26 Yury German Gentoo Infrastructure gentoo-dev 2015-09-26 21:06:01 UTC
Thank you for cleaning up x11-misc/x11vnc.
Can we please clean up 
=net-libs/libvncserver-0.9.10

GLSA Vote: No
Comment 27 Alex Xu (Hello71) 2015-09-26 21:37:24 UTC
(In reply to Yury German from comment #26)
> Thank you for cleaning up x11-misc/x11vnc.
> Can we please clean up 
> =net-libs/libvncserver-0.9.10
> 
> GLSA Vote: No

yes, anyone should feel free to remove <=net-libs/libvncserver-0.9.10-r1. (not -r3 or -r4).
Comment 28 Ian Delaney (RETIRED) gentoo-dev 2015-09-27 02:47:58 UTC
commit 1716aea7db079ad590ddccc831bbaa2d3f0c9f15
Author: Ian Delaney <idella4@gentoo.org>
Date:   Sun Sep 27 10:46:58 2015 +0800

    net-libs/libvncserver: rm old, clean up for sec bug #515268
Comment 29 Yury German Gentoo Infrastructure gentoo-dev 2015-09-27 02:51:47 UTC
Maintainer(s), Thank you for you for cleanup.
Comment 30 Kristian Fiskerstrand (RETIRED) gentoo-dev 2015-10-07 07:59:59 UTC
(In reply to Yury German from comment #26)
> Thank you for cleaning up x11-misc/x11vnc.
> Can we please clean up 
> =net-libs/libvncserver-0.9.10
> 
> GLSA Vote: No

GLSA Vote: No