Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 836969 (CVE-2022-1122) - <media-libs/openjpeg-2.4.0-r2: Use-after-free
Summary: <media-libs/openjpeg-2.4.0-r2: Use-after-free
Alias: CVE-2022-1122
Product: Gentoo Security
Classification: Unclassified
Component: Vulnerabilities (show other bugs)
Hardware: All Linux
: Normal minor (vote)
Assignee: Gentoo Security
Whiteboard: B3 [glsa+]
Depends on:
Reported: 2022-04-07 02:27 UTC by Sam James
Modified: 2022-09-07 03:18 UTC (History)
2 users (show)

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


Note You need to log in before you can comment on or make changes to this bug.
Description Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-04-07 02:27:26 UTC
(In reply to John Helmert III from comment #1)
> CVE-2022-1122 (
> A flaw was found in the opj2_decompress program in openjpeg2 2.4.0 in the
> way it handles an input directory with a large number of files. When it
> fails to allocate a buffer to store the filenames of the input directory, it
> calls free() on an uninitialized pointer, leading to a segmentation fault
> and a denial of service.
Comment 1 Geoff Madden 2022-04-07 05:24:52 UTC
The segfault patch fails with a nosuch file error,I'm not able to find the relevant section for the patch ????!!!!!
Comment 2 Thomas Bracht Laumann Jespersen 2022-04-07 10:53:05 UTC
(In reply to Geoff Madden from comment #1)
> The segfault patch fails with a nosuch file error,I'm not able to find the
> relevant section for the patch ????!!!!!

Could you provide the build.log? I suspect it's the same problem as
Comment 3 Larry the Git Cow gentoo-dev 2022-09-07 03:01:19 UTC
The bug has been referenced in the following commit(s):

commit 3ffb060a535687205849990e329954275cbcd1f4
Author:     GLSAMaker <>
AuthorDate: 2022-09-07 02:52:41 +0000
Commit:     John Helmert III <>
CommitDate: 2022-09-07 02:58:07 +0000

    [ GLSA 202209-04 ] OpenJPEG: Multiple Vulnerabilities
    Signed-off-by: GLSAMaker <>
    Signed-off-by: John Helmert III <>

 glsa-202209-04.xml | 45 +++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 45 insertions(+)
Comment 4 John Helmert III archtester Gentoo Infrastructure gentoo-dev Security 2022-09-07 03:18:28 UTC
GLSA released, all done!