JLSEC-2026-2267: Calling the ungetwc function on a FILE stream with wide characters encoded in a character set...

Published Dec 2, 2026
·
Updated

Calling the ungetwc function on a FILE stream with wide characters encoded in a character set that has overlaps between its single byte and multi-byte character encodings, in the GNU C Library version 2.43 or earlier, may result in an attempt to read bytes before an allocated buffer, potentially resulting in unintentional disclosure of neighboring data in the heap, or a program crash.

A bug in the wide character pushback implementation (IOwdefaultpbackfail in libio/wgenops.c) causes ungetwc() to operate on the regular character buffer (fp->IOreadptr) instead of the actual wide-stream read pointer (fp->widedata->IOreadptr). The program crash may happen in cases where fp->IOreadptr is not initialized and hence points to NULL. The buffer under-read requires a special situation where the input character encoding is such that there are overlaps between single byte representations and multibyte representations in that encoding, resulting in spurious matches. The spurious match case is not possible in the standard Unicode character sets.

Affected Software

1 affected component
julia/gccbootstrap_jll*

Event History

Dec 2, 2026
Advisory Published
via OSV·09:30 PM
Data Sourced
via OSV·09:30 PM
DescriptionSeverityAffected Software

Child vulnerabilities

Contains the following vulnerabilities.

Frequently Asked Questions

1

Which deployments are realistically exposed to the buffer under-read and potential heap disclosure?

The under-read requires use of ungetwc() on a wide-character FILE stream with a character encoding that overlaps single-byte and multibyte representations. This spurious-match condition is not possible with standard Unicode character sets.

2

Can the issue cause a denial of service even when the special encoding condition is not met?

Yes. A program crash can occur when the regular stream read pointer, fp->_IO_read_ptr, is uninitialized and points to NULL.

3

What must an attacker be able to do to exploit this issue?

The affected program must call ungetwc() on a wide-character stream using a character set with overlapping single-byte and multibyte encodings for the disclosure scenario. The supplied data does not identify any required authentication or user interaction.

4

Which GNU C Library versions are affected?

GNU C Library version 2.43 and earlier are identified as affected.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203