Your message dated Tue, 25 Feb 2025 12:51:02 +0000
with message-id <[email protected]>
and subject line Bug#1098694: fixed in util-linux 2.41~rc1-2
has caused the Debian Bug report #1098694,
regarding Crash in agetty due to invalid strncmp call in Trixie
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
1098694: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1098694
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: util-linux
Version: 2.40.4-3
Severity: important

Dear Maintainer,

this is the first bug report I'm sending, so I hope all the formatting is correct.

I am running Debian Trixie in a Proxmox VM. I noticed that on the login screen there are errors of agetty crashing with a segfault. There's nothing special about the VM, it's a blank VM running the daily cloud images of Debian Trixie.

The VM is running Linux 6.12.12-1 with util-linux 2.40.4-3 and libc6 2.40-7.

I debugged this with ltrace and believe I found the error, or at least some invalid behaviour.

In agetty.c in the debian sources for util-linux, right at the end of the function parse_args, there's code that tries to figure out the terminal name using a call to get_terminal_name. For some reason, this function call seems to fail on my machine and it prints the error "could not get terminal name".

This causes it to set &op->tty to NULL, and unfortunately, a couple lines later, that variable is used in a strncmp call, causing it to crash.

Here's the corresponding lines from the ltrace log:

strtok(nil, ",")                                 = nil
free(0x557c64154be0)                             = <void>
strcmp("-", "-")                                 = 0
isatty(0)                                        = 0
isatty(1)                                        = 0
isatty(2)                                        = 0
dcgettext(nil, "could not get terminal name: %d", 5) = "could not get terminal name: %d"
openlog("agetty", 1, 80)                         = <void>
__vsyslog_chk(4, 1, 0x557c2a49d4d8, 0x7ffda1325e40) = 0
closelog()                                       = <void>
strncmp(nil, "tty", 3 <no return ...>
--- SIGSEGV (Segmentation fault) ---
+++ killed by SIGSEGV +++


I can provide the full ltrace log and/or a crash dump file if necessary - what's the best way to provide these? Upload at a filehoster and send the link in response to this bug report?

Unfortunately, I was not yet able to figure out why on my machine the code seems to run into this code path with the "could not get terminal name" warning. But nevertheless, it's a valid code path, and it's just a warning not an error, so the code that comes after it should be able to handle this without crashing.

Best regards,
Florian

--- End Message ---
--- Begin Message ---
Source: util-linux
Source-Version: 2.41~rc1-2
Done: Chris Hofstaedtler <[email protected]>

We believe that the bug you reported is fixed in the latest version of
util-linux, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Chris Hofstaedtler <[email protected]> (supplier of updated util-linux package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Format: 1.8
Date: Tue, 25 Feb 2025 13:19:39 +0100
Source: util-linux
Architecture: source
Version: 2.41~rc1-2
Distribution: experimental
Urgency: medium
Maintainer: util-linux packagers <[email protected]>
Changed-By: Chris Hofstaedtler <[email protected]>
Closes: 1098694
Changes:
 util-linux (2.41~rc1-2) experimental; urgency=medium
 .
   [ Samuel Thibault ]
   * Fix mq_open lib missing on hurd
 .
   [ Chris Hofstaedtler ]
   * Force UTF-8 locale during build
   * Apply upstream patch to avoid agetty crash (Closes: #1098694)
Checksums-Sha1:
 d0b8619b46bb78acf513a6fdbec12eed332ffb50 5037 util-linux_2.41~rc1-2.dsc
 ea03e76b5be6063de479076bfedebe843b73d562 104904 
util-linux_2.41~rc1-2.debian.tar.xz
 48fda7942135e618c571d08d40e6b008fbc7602d 22637 
util-linux_2.41~rc1-2_arm64.buildinfo
Checksums-Sha256:
 75834259861381cc75600a7513c9cb0d5de2b87bd0d74b123e00835025b3cf4a 5037 
util-linux_2.41~rc1-2.dsc
 4585b3cf96a861607e40676965f7cbc1108aba10c5126798b7985499d21fdaaf 104904 
util-linux_2.41~rc1-2.debian.tar.xz
 8608e1f06c8def16358e480e715ac724abf885ee13feb87857ecdb875e8722b5 22637 
util-linux_2.41~rc1-2_arm64.buildinfo
Files:
 ac210693303d8b90aaa3feb4dcc60b6c 5037 utils required util-linux_2.41~rc1-2.dsc
 9890823135774901b53f8f9875a19b2c 104904 utils required 
util-linux_2.41~rc1-2.debian.tar.xz
 5160e9b61aca170fb5be8f268fccf617 22637 utils required 
util-linux_2.41~rc1-2_arm64.buildinfo

-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEEfRrP+tnggGycTNOSXBPW25MFLgMFAme9t+4ACgkQXBPW25MF
LgMggQ/8Cs7qDhYhXrKfhK23YzBG1gHzx9pZVlZAVMbbv6RxyBw3WuryEjxObodh
qBMl6dM4gRdAnkyuCW746mAyucDDkZNUI/xfSR4Tll6xSyNTT5e7rgRCGj26iAsn
TWyq8X9gTAm/fPPTM0cGMjl9qONJRBMs5eHDm9jqvcM9VJ8badKnXt2Qcyf3DWbG
4rAXZavjnBhH+f8/1aHJGu2qArPSMIAVOW7QGsvcBefgc3fIcaXFWNrhlrbkvxcg
26f9BTJySrqzoZJ1Fsl3q4jHB3jMFK1GCizyjUMyBs3ylc9ZQi4t0bSrH3SN8POd
8mNxpE+Hh+KrkX0ZbWWdt9sZanmh4y+biKY5tEGc4U8AmqmboyJJbthAUhKrPC54
OFFJGF6n3f90fXBB5JO5d9gHGqZ+j9rbfl1bxr4DG8fVtLR0NnZdpnZoqR1I+fLM
J6ByUfzJ1UkrKzE7oRd5rVkeWTL4n6vZcQXWocV29rrI9dh5WSnL3WGA+MX2AkWz
DYHx1AlkyUo0Y0Z1qwETgcGdB4iLoPCKaKASFIW1YcZpIMpl+KuRcs47aeweFOQh
BjaBVh9lizLLxnTfcs91WdrA6xxNCrYxX0MZCvdzrFbRgWy4EPmsKSaWtqi6Df1E
oOaXuI0oev/jVxlKf4Le3tdAG590GuwgkR+/ECbylent4IUqcL4=
=kj+a
-----END PGP SIGNATURE-----

Attachment: pgpAkI2ll4IcJ.pgp
Description: PGP signature


--- End Message ---

Reply via email to