cbcvebase.
CVE-2023-6246
published 2024-01-31

CVE-2023-6246: A heap-based buffer overflow was found in the __vsyslog_internal function of the glibc library. This function is called by the syslog and vsyslog functions…

PriorityP354high7.8CVSS 3.1
AVLACLPRLUINSUCHIHAH
EXPLOIT
EPSS
4.79%
90.9th percentile
A heap-based buffer overflow was found in the __vsyslog_internal function of the glibc library. This function is called by the syslog and vsyslog functions. This issue occurs when the openlog function was not called, or called with the ident argument set to NULL, and the program name (the basename of argv[0]) is bigger than 1024 bytes, resulting in an application crash or local privilege escalation. This issue affects glibc 2.36 and newer.

Affected

11 ranges
VendorProductVersion rangeFixed in
debianglibc< glibc 2.36-9+deb12u4 (bookworm)glibc 2.36-9+deb12u4 (bookworm)
fedoraprojectfedora
fedoraprojectfedora
gnuglibc>= 0 < 2.36-9+deb12u42.36-9+deb12u4
gnuglibc>= 0 < 2.37-152.37-15
gnuglibc>= 0 < 2.37-152.37-15
gnuglibc>= 2.36 < 2.392.39
msrcazl3_glibc_2.38-10_on_azure_linux_3.0
msrcazl3_glibc_2.38-6_on_azure_linux_3.0
msrcazure_linux_3.0_arm
msrcazure_linux_3.0_x64

Detection & IOCsextracted from sources · hover to see the quote

command(exec -a "`printf '%0128000x' 1`" /usr/bin/su < /dev/null)
  • Exploit triggers a segmentation fault (exit code 127) by passing an argv[0] of >1024 bytes to a suid binary that calls syslog/vsyslog without a prior openlog() call; monitor for processes launched with abnormally long process-name arguments (argv[0] > 1024 bytes)
  • PoC uses exec -a with a 128000-character hex string as argv[0] against /usr/bin/su; a segfault exit code of 127 indicates successful overflow trigger
  • Vulnerability was inadvertently introduced in glibc 2.37 (August 2022) and backported to glibc 2.36; flag systems running glibc 2.36 or 2.37 through 2.38 as vulnerable
  • Confirmed vulnerable distributions: Debian 12 and 13, Ubuntu 23.04 and 23.10, Fedora 37 to 39; prioritize patching on these platforms
  • ·Exploitation requires specific preconditions: openlog() must not have been called (or called with ident=NULL), and argv[0] must be larger than 1024 bytes; not all syslog-using applications are reachable
  • ·This is a local privilege escalation only; remote exploitation is not possible (CVSS AV:L)
  • ·Debian bookworm fix is in 2.36-9+deb12u4; forky/sid/trixie fix is in 2.37-15; verify installed glibc package version to confirm patch status

CVSS provenance

nvdv3.17.8HIGHCVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
osv7.8HIGH
vendor_debian8.4HIGH
vendor_redhat8.4HIGH
vendor_msrc7.8HIGH
vendor_oracle7.8HIGH
CVEs like this are exactly what “Exploited This Week” covers.

Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.