Bug 2494878

Summary: CVE-2026-58013 glib: buffer over-read in glib/giochannel.c via "g_io_channel_read_line_backend" [fedora-all]
Product: [Fedora] Fedora Reporter: Guilherme de Almeida Suckevicz <gsuckevi>
Component: glibAssignee: Paul Howarth <paul>
Status: CLOSED NOTABUG QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: medium    
Version: rawhideCC: paul, suraj.ghimire7
Target Milestone: ---Keywords: Security, SecurityTracking
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: {"flaws": ["77ff4afa-6e87-4b0b-8af9-c4c2742be9c6"]}
Fixed In Version: Doc Type: ---
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2026-06-30 14:31:12 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 2492248    

Description Guilherme de Almeida Suckevicz 2026-06-30 12:58:40 UTC
Disclaimer: Community trackers are created by Red Hat Product Security team on a best effort basis. Package maintainers are required to ascertain if the flaw indeed affects their package, before starting the update process.

A heap-buffer-overflow READ occurs in g_io_channel_read_line_backend() at giochannel.c:1831 when a custom line terminator of length > 1 is set via g_io_channel_set_line_term(). The memcmp call reads line_term_len bytes from nextchar, but the loop condition nextchar < lastchar only guarantees 1 byte is available. When nextchar is within line_term_len - 1 bytes of lastchar, memcmp reads past the GString buffer into ASan redzone / unallocated memory.

Comment 1 Paul Howarth 2026-06-30 14:31:12 UTC
This is a glib2 issue, not a glib issue. There is no g_io_channel_read_line_backend function in glib version 1.