Bug 33102 - less new security issue CVE-2024-32487
Summary: less new security issue CVE-2024-32487
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,MGA9-32-OK
Keywords: advisory, validated_update
Depends on:
Blocks:
 
Reported: 2024-04-15 14:16 CEST by Nicolas Salguero
Modified: 2024-04-19 03:17 CEST (History)
5 users (show)

See Also:
Source RPM: less-632-1.1.mga9.src.rpm
CVE: CVE-2024-32487
Status comment:


Attachments

Comment 1 Nicolas Salguero 2024-04-15 14:27:36 CEST
Suggested advisory:
========================

The updated package fixes a security vulnerability:

less through 653 allows OS command execution via a newline character in the name of a file, because quoting is mishandled in filename.c. Exploitation typically requires use with attacker-controlled file names, such as the files extracted from an untrusted archive. Exploitation also requires the LESSOPEN environment variable, but this is set by default in many common cases. (CVE-2024-32487)

References:
https://www.openwall.com/lists/oss-security/2024/04/12/5
https://www.openwall.com/lists/oss-security/2024/04/12/6
https://www.openwall.com/lists/oss-security/2024/04/13/2
https://www.openwall.com/lists/oss-security/2024/04/15/1
========================

Updated package in core/updates_testing:
========================
less-632-1.2.mga9

from SRPM:
less-632-1.2.mga9.src.rpm

Assignee: bugsquad => qa-bugs
Status: NEW => ASSIGNED
Version: Cauldron => 9
CVE: (none) => CVE-2024-32487
Source RPM: (none) => less-632-1.1.mga9.src.rpm

PC LX 2024-04-15 18:14:03 CEST

CC: (none) => mageia

katnatek 2024-04-16 01:10:35 CEST

Keywords: (none) => advisory

Comment 2 katnatek 2024-04-16 01:37:34 CEST
RH mageia 9 x86_64

I can't reproduce the issue following https://www.openwall.com/lists/oss-security/2024/04/12/5 example

LC_ALL=C urpmi --auto --auto-update 
medium "QA Testing (32-bit)" is up-to-date
medium "QA Testing (64-bit)" is up-to-date
medium "Core Release (distrib1)" is up-to-date
medium "Core Updates (distrib3)" is up-to-date
medium "Nonfree Release (distrib11)" is up-to-date
medium "Nonfree Updates (distrib13)" is up-to-date
medium "Tainted Release (distrib21)" is up-to-date
medium "Tainted Updates (distrib23)" is up-to-date
medium "Core 32bit Release (distrib31)" is up-to-date
medium "Core 32bit Updates (distrib32)" is up-to-date
medium "Nonfree 32bit Release (distrib36)" is up-to-date
medium "Tainted 32bit Release (distrib41)" is up-to-date
medium "Tainted 32bit Updates (distrib42)" is up-to-date


installing less-632-1.2.mga9.x86_64.rpm from //home/katnatek/qa-testing/x86_64
Preparing...                     ##################################################################################################
      1/1: less                  ##################################################################################################
      1/1: removing less-632-1.1.mga9.x86_64
                                 ##################################################################################################
----------------------------------------------------------------------
More information on package less-632-1.2.mga9.x86_64
This version of less includes lesspipe.sh from Wolfgang Friebel
( https://www-zeuthen.desy.de/~friebel//unix/less/ ).

This enables you to view gz, bz2, lzma, zip, rpm and html files
among others with less. It works by setting the LESSOPEN 
environment variable, see the man pages for details.

If you want to disable this behavior, either use 'unset LESSOPEN' or
use an alias ( alias less='less -l' ).

less will open html files with lynx, then html2text, then cat if
none of the previous were found.

----------------------------------------------------------------------

Still can't reproduce the fail what is good, I think :)

Tested with some files, looks good for me
Comment 3 Len Lawrence 2024-04-18 13:25:23 CEST
Go ahead with the OK katnatek.

CC: (none) => tarazed25

Comment 4 Morgan Leijström 2024-04-18 17:43:44 CEST
mga9-64 OK simple usage test.

CC: (none) => fri

katnatek 2024-04-18 19:36:12 CEST

CC: (none) => andrewsfarm

Comment 5 katnatek 2024-04-18 19:37:46 CEST
(In reply to Len Lawrence from comment #3)
> Go ahead with the OK katnatek.

I just did want more eyes on this

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

Comment 6 katnatek 2024-04-18 22:29:37 CEST
RH mageia 9 i586

LC_ALL=C urpmi --auto --auto-update 
medium "QA Testing (32-bit)" is up-to-date
medium "BDK-Free-i586" is up-to-date
medium "BDK-Free-noarch" is up-to-date
medium "BDK-NonFree-i586" is up-to-date
medium "Core Release (distrib1)" is up-to-date
medium "Core Updates (distrib3)" is up-to-date
medium "Nonfree Release (distrib11)" is up-to-date
medium "Nonfree Updates (distrib13)" is up-to-date
medium "Tainted Release (distrib21)" is up-to-date
medium "Tainted Updates (distrib23)" is up-to-date


installing less-632-1.2.mga9.i586.rpm from //home/katnatek/qa-testing/i586
Preparing...                     #######################################################
      1/1: less                  #######################################################
      1/1: removing less-632-1.1.mga9.i586
                                 #######################################################
----------------------------------------------------------------------
More information on package less-632-1.2.mga9.i586
This version of less includes lesspipe.sh from Wolfgang Friebel
( https://www-zeuthen.desy.de/~friebel//unix/less/ ).

This enables you to view gz, bz2, lzma, zip, rpm and html files
among others with less. It works by setting the LESSOPEN 
environment variable, see the man pages for details.

If you want to disable this behavior, either use 'unset LESSOPEN' or
use an alias ( alias less='less -l' ).

less will open html files with lynx, then html2text, then cat if
none of the previous were found.

----------------------------------------------------------------------

Issue in https://www.openwall.com/lists/oss-security/2024/04/12/5 is not reproducible before or after install the testing packages

Test open some files with less not issues detected
katnatek 2024-04-18 22:31:34 CEST

Whiteboard: MGA9-64-OK => MGA9-64-OK,MGA9-32-OK

Morgan Leijström 2024-04-18 22:34:45 CEST

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

Comment 7 Mageia Robot 2024-04-19 03:17:35 CEST
An update for this issue has been pushed to the Mageia Updates repository.

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

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


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