Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 900763

Summary: x11-libs/motif: multiple vulnerabilities?
Product: Gentoo Security Reporter: John Helmert III <ajak>
Component: VulnerabilitiesAssignee: Gentoo Security <security>
Status: IN_PROGRESS ---    
Severity: normal CC: ulm
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
URL: https://www.openwall.com/lists/oss-security/2023/01/17/2
See Also: https://bugs.gentoo.org/show_bug.cgi?id=891209
Whiteboard: B3 [glsa?]
Package list:
Runtime testing required: ---
Bug Depends on: 902789    
Bug Blocks:    

Description John Helmert III archtester Gentoo Infrastructure gentoo-dev Security 2023-03-11 04:45:58 UTC
"1) CVE-2022-46285: Infinite loop on unclosed comments
2) CVE-2022-44617: Runaway loop on width of 0 and enormous height
3) CVE-2022-4883: compression commands depend on $PATH"

As discussed on oss-security, https://www.openwall.com/lists/oss-security/2023/02/01/5

"Distros & others packaging the OpenMotif library (or the older commercial
Motif library) may wish to compare our changes to the files under the
src directory in libXpm with the corresponding files with an "Xpm" prefix
on the file name in the OpenMotif lib/Xm directory.  For example:
https://gitlab.freedesktop.org/xorg/lib/libxpm/-/blob/master/src/parse.c
vs.
https://sourceforge.net/p/motif/code/ci/master/tree/lib/Xm/Xpmparse.c"
Comment 1 Ulrich Müller gentoo-dev 2023-03-11 07:43:20 UTC
(In reply to John Helmert III from comment #0)
> "Distros & others packaging the OpenMotif library (or the older commercial
> Motif library) may wish to compare our changes to the files under the
> src directory in libXpm with the corresponding files with an "Xpm" prefix
> on the file name in the OpenMotif lib/Xm directory.

That's not very helpful. Do they provide a patch?
Comment 2 Larry the Git Cow gentoo-dev 2023-03-11 09:12:46 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/dev/ulm.git/commit/?id=8bc5d9b1b39f71ec331e3d409b9a0be1eea1dbf0

commit 8bc5d9b1b39f71ec331e3d409b9a0be1eea1dbf0
Author:     Ulrich Müller <ulm@gentoo.org>
AuthorDate: 2023-03-11 08:58:59 +0000
Commit:     Ulrich Müller <ulm@gentoo.org>
CommitDate: 2023-03-11 08:58:59 +0000

    motif: Fix vulnerabilities in lib/Xm
    
    Bug: https://bugs.gentoo.org/900763
    Signed-off-by: Ulrich Müller <ulm@gentoo.org>

 patchsets/motif/2.3.8/13_all_xpm-comments.patch |  22 ++++
 patchsets/motif/2.3.8/14_all_xpm-width-0.patch  | 155 ++++++++++++++++++++++++
 2 files changed, 177 insertions(+)
Comment 3 Larry the Git Cow gentoo-dev 2023-03-11 09:13:00 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2391b86a36c37ec64eb677b4822fb3063e76bde2

commit 2391b86a36c37ec64eb677b4822fb3063e76bde2
Author:     Ulrich Müller <ulm@gentoo.org>
AuthorDate: 2023-03-11 09:12:00 +0000
Commit:     Ulrich Müller <ulm@gentoo.org>
CommitDate: 2023-03-11 09:12:00 +0000

    x11-libs/motif: Fix vulnerabilities in lib/Xm
    
    Bug: https://bugs.gentoo.org/900763
    Signed-off-by: Ulrich Müller <ulm@gentoo.org>

 x11-libs/motif/Manifest              |   1 +
 x11-libs/motif/motif-2.3.8-r5.ebuild | 112 +++++++++++++++++++++++++++++++++++
 2 files changed, 113 insertions(+)
Comment 4 Ulrich Müller gentoo-dev 2023-03-11 09:16:17 UTC
(In reply to John Helmert III from comment #0)
> 1) CVE-2022-46285: Infinite loop on unclosed comments
> 2) CVE-2022-44617: Runaway loop on width of 0 and enormous height

I have ported the patches for these two.

> 3) CVE-2022-4883: compression commands depend on $PATH"

This one is not done, as the patches are very intrusive. Also I don't understand why usage of PATH would introduce any vulnerabilities.
Comment 5 Larry the Git Cow gentoo-dev 2023-03-24 16:06:50 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=eebf1f31a05bd167a072a042b09b40cc0bb4afd5

commit eebf1f31a05bd167a072a042b09b40cc0bb4afd5
Author:     Ulrich Müller <ulm@gentoo.org>
AuthorDate: 2023-03-24 16:05:58 +0000
Commit:     Ulrich Müller <ulm@gentoo.org>
CommitDate: 2023-03-24 16:05:58 +0000

    x11-libs/motif: drop 2.3.8-r3, 2.3.8-r4
    
    Bug: https://bugs.gentoo.org/900763
    Signed-off-by: Ulrich Müller <ulm@gentoo.org>

 x11-libs/motif/Manifest              |   2 -
 x11-libs/motif/motif-2.3.8-r3.ebuild | 109 ----------------------------------
 x11-libs/motif/motif-2.3.8-r4.ebuild | 112 -----------------------------------
 3 files changed, 223 deletions(-)
Comment 6 Ulrich Müller gentoo-dev 2025-02-15 17:10:17 UTC
Any news here? Can this bug be closed?
Comment 7 Hans de Graaff gentoo-dev Security 2025-02-16 06:51:50 UTC
(In reply to Ulrich Müller from comment #4)

> This one is not done, as the patches are very intrusive. Also I don't
> understand why usage of PATH would introduce any vulnerabilities.

I agree. If an attacker can manipulate PATH at this point then you have a wider range of security issues independent of Motif. I've left that bug out of the list of aliases.

I've set the whiteboard to glsa?