Bug 32959 - libtiff new security issue CVE-2023-52356
Summary: libtiff new security issue CVE-2023-52356
Status: RESOLVED FIXED
Alias: None
Product: Mageia
Classification: Unclassified
Component: Security (show other bugs)
Version: 9
Hardware: All Linux
Priority: Normal normal
Target Milestone: ---
Assignee: QA Team
QA Contact: Sec team
URL:
Whiteboard: MGA9-64-OK
Keywords: advisory, validated_update
Depends on:
Blocks:
 
Reported: 2024-03-11 16:35 CET by Nicolas Salguero
Modified: 2024-03-20 02:11 CET (History)
4 users (show)

See Also:
Source RPM: libtiff-4.5.1-1.mga9.src.rpm
CVE: CVE-2023-52356
Status comment:


Attachments
nomacs test with strace (324 bytes, text/plain)
2024-03-12 01:24 CET, Len Lawrence
Details

Description Nicolas Salguero 2024-03-11 16:35:34 CET
Debian has issued an advisory today (March 11):
https://lwn.net/Articles/965011/

Mageia 9 is also affected.
Nicolas Salguero 2024-03-11 16:36:38 CET

Assignee: bugsquad => nicolas.salguero
Whiteboard: (none) => MGA9TOO
Source RPM: (none) => libtiff-4.6.0-1.mga10.src.rpm
CVE: (none) => CVE-2023-52356

Comment 1 Nicolas Salguero 2024-03-11 16:47:17 CET
Suggested advisory:
========================

The updated packages fix a security vulnerability:

A segment fault (SEGV) flaw was found in libtiff that could be triggered by passing a crafted tiff file to the TIFFReadRGBATileExt() API. This flaw allows a remote attacker to cause a heap-buffer overflow, leading to a denial of service. (CVE-2023-52356)

References:
https://lwn.net/Articles/965011/
========================

Updated packages in core/updates_testing:
========================
lib(64)tiff6-4.5.1-1.1.mga9
lib(64)tiff-devel-4.5.1-1.1.mga9
lib(64)tiff-static-devel-4.5.1-1.1.mga9
libtiff-progs-4.5.1-1.1.mga9

from SRPM:
libtiff-4.5.1-1.1.mga9.src.rpm

Assignee: nicolas.salguero => qa-bugs
Source RPM: libtiff-4.6.0-1.mga10.src.rpm => libtiff-4.5.1-1.mga9.src.rpm
Whiteboard: MGA9TOO => (none)
Status: NEW => ASSIGNED
Version: Cauldron => 9

Comment 2 Len Lawrence 2024-03-11 19:44:49 CET
mga9, x64
No path to a PoC from the link under references.

Updated all the packages.
Nothing to do but exercise the utilities as in previous bugs.

$ tiffgt Shiel.tif
to display an image.

No layered tiff image available but plain image was processed properly.
$ tiffsplit x.tiff p
$ ll pa*.tif
-rw-r--r-- 1 lcl lcl 128244 Mar 11 18:04 paaa.tif

$ tifftopnm einstein.tif > albert.pnm
tifftopnm: writing PGM file
$ display albert.pnm
Exact copy.

$ tiffcrop -E top -U px -m 120,120,120,120 SantaMaria.tif cropped.tif
_TIFFVGetField: cropped.tif: Invalid tag "BadFaxLines" (not supported by codec).
_TIFFVGetField: cropped.tif: Invalid tag "BadFaxLines" (not supported by codec).
Nevertheless the resulting image was displayed with a 120-pixel border missing.
$ file SantaMaria.tif 
SantaMaria.tif: TIFF image data, little-endian, direntries=21, height=1410, bps=5210, compression=LZW, PhotometricInterpretation=RGB, description=IDL TIFF file, orientation=upper-left, width=1638
$ file cropped.tif
cropped.tif: TIFF image data, little-endian, direntries=21, height=1170, bps=22414, compression=LZW, PhotometricInterpretation=RGB, description=IDL TIFF file, orientation=upper-left, width=1398

$ tiff2bw JessicaAlba.tif monochrome.tif
$ eom monochrome.tif
Greyscale rendering of colour image was displayed.

$ tiff2pdf SantaMaria.tif > crater.pdf
$ okular crater.pdf
That displayed the imagein a one-page PDF.

$ tiff2ps SantaMaria.tif > crater.ps
$ gs crater.ps
Ghostscript image of the original, displayed at a reduced size in the bottom left-hand corner of the page.

$ tiffdump SantaMaria.tif > dumpfile
$ less dumpfile
SantaMaria.tif:
Magic: 0x4949 <little-endian> Version: 0x2a <ClassicTIFF>
Directory 0: offset 1971016 (0x1e1348) next 0 (0)
ImageWidth (256) SHORT (3) 1<1638>
ImageLength (257) SHORT (3) 1<1410>
BitsPerSample (258) SHORT (3) 3<8 8 8>
Compression (259) SHORT (3) 1<5>
Photometric (262) SHORT (3) 1<2>
FillOrder (266) SHORT (3) 1<1>
[...]
PrimaryChromaticities (319) RATIONAL (5) 6<0.64 0.33 0.3 0.6 0.15 0.06>
BadFaxLines (326) LONG (4) 1<2707030018>

No regressions noted.  Advisory to follow.

CC: (none) => tarazed25
Whiteboard: (none) => MGA9-64-OK

katnatek 2024-03-11 20:05:33 CET

Keywords: (none) => advisory

Comment 3 katnatek 2024-03-11 20:06:41 CET
(In reply to Len Lawrence from comment #2)
> No regressions noted.  Advisory to follow.
Sorry Len, I not see you already on t, is uploaded
Comment 4 Len Lawrence 2024-03-11 20:15:17 CET
Thanks katnatek, my fault; I should have checked.
Comment 5 Thomas Andrews 2024-03-12 00:37:56 CET
Validating.

Keywords: (none) => validated_update
CC: (none) => andrewsfarm, sysadmin-bugs

Comment 6 Len Lawrence 2024-03-12 01:24:19 CET
Created attachment 14450 [details]
nomacs test with strace
Comment 7 Mageia Robot 2024-03-12 01:31:34 CET
An update for this issue has been pushed to the Mageia Updates repository.

https://advisories.mageia.org/MGASA-2024-0055.html

Status: ASSIGNED => RESOLVED
Resolution: (none) => FIXED

katnatek 2024-03-19 19:23:00 CET

CC: (none) => dan

Comment 8 katnatek 2024-03-19 19:24:47 CET
Dan Fandrich
Today the adv file for this bug was marked as deleted from svn , is a mistake?
Comment 9 Dan Fandrich 2024-03-19 20:36:47 CET
This change is the culprit:
------------------------------------------------------------------------
r15903 | tarazed | 2024-03-19 10:01:01 -0700 (Tue, 19 Mar 2024) | 1 line
Changed paths:
   A /32944.adv
   D /32959.adv
Comment 10 katnatek 2024-03-19 21:03:07 CET
(In reply to Dan Fandrich from comment #9)
> This change is the culprit:
> ------------------------------------------------------------------------
> r15903 | tarazed | 2024-03-19 10:01:01 -0700 (Tue, 19 Mar 2024) | 1 line
> Changed paths:
>    A /32944.adv
>    D /32959.adv

Must I add again, or you can do it?
Comment 11 Dan Fandrich 2024-03-19 21:39:22 CET
I'm pretty sure you can do it.
Comment 13 Len Lawrence 2024-03-20 01:55:53 CET
Sorry katnatek.  I was adding an advisory for another bug and was told that that older advisory (remember we clashed) had to be removed.  I assumed (!) that meant the copy in my advisories directory, so I agreed to 'r'.  I am still confused about what to do in such cases.  I don't know what the correct response would have been.  The one at my end that I thought had been replaced by your version is actually the skeleton from the documentation and I do not know how that appeared because I use mga-advisor.
Comment 14 katnatek 2024-03-20 02:11:01 CET
(In reply to Len Lawrence from comment #13)
> Sorry katnatek.  I was adding an advisory for another bug and was told that
> that older advisory (remember we clashed) had to be removed.  I assumed (!)
> that meant the copy in my advisories directory, so I agreed to 'r'.  I am
> still confused about what to do in such cases.  I don't know what the
> correct response would have been.  The one at my end that I thought had been
> replaced by your version is actually the skeleton from the documentation and
> I do not know how that appeared because I use mga-advisor.

When I did have this I prefer lost some of my work, from ~/mageia-advisories

I rm -rf advisories

svn co svn+ssh://svn.mageia.org/svn/advisories

cd advisories

And not is necessary but for be extra sure

svn up

Then redo my advisory and apply the steps to upload

I not make this kind of mistake recently but a few times when I start with this
I'm some rusted with svn, I remember is a way of undo this kind of situations, but I decide just re-upload , I have some fun in Mandriva times with this and once I did have to ask Romain D Alverny to come to rescue :/

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