Thursday, February 27, 2025
HomeCyber Security NewsMemory Corruption Flaw in ncurses API Library Exposes Linux and macOS Systems

Memory Corruption Flaw in ncurses API Library Exposes Linux and macOS Systems

Published on

SIEM as a Service

Follow Us on Google News

Multiple memory corruption vulnerabilities have been discovered in the ncurses library, which various programs use on multiple operating systems like Portable Operating System Interface (POSIX) OS, Linux OS, macOS, and FreeBSD. 

Threat actors can chain these vulnerabilities with environment variable poisoning attacks to gain escalated privileges and run codes under the name of the target program or perform other malicious actions.

Memory corruption is one of the common vulnerabilities found in modern programs that could allow threat actors to gain unauthorized access by modifying a program’s memory. The impact of this vulnerability ranges from leaking sensitive information to executing arbitrary code with escalated privileges.

However, Microsoft has disclosed these vulnerabilities with the ncurses maintainers, which have now been successfully patched.

Document
Get a Demo

Start protecting your SaaS data in just a few minutes!

With DoControl, you can keep your SaaS applications and data safe and secure by creating workflows tailored to your needs. It’s an easy and efficient way to identify and manage risks. You can mitigate the risk and exposure of your organization’s SaaS applications in just a few simple steps.

CVE-2023-29491: Memory Corruption via malformed data

This vulnerability exists in the ncurses library before 6.4 20230408, which could allow threat actors with local privileges to trigger security-based memory corruption. This can be done with the help of malformed data in the terminfo database file, which is found in $HOME/.terminfo, or with environment variables like TERMINFO or TERM.

This particular vulnerability is associated with several internal things, such as Heap out-of-bounds during terminfo database file parsing, parameterized string type confusion, stack information leak, and denial of service with canceled strings.

Terminfo database file consists of optional extended entries like Boolean, numeric, and strings. These entries are user-defined entries and are parsed by the _nc_read_termtype function, which was found to be capable of writing beyond the boundaries of a heap-allocated chunk.

The ncurses source code looks for CANCELLED_STRING and converts them to ABSENT_STRING, which is done only for ordinary strings, whereas extended strings do not get converted. Additionally, strings beginning with “k” are treated as keypad functionality, which can allow a threat actor to specify an extended string, resulting in ncurses dereference eventually causing a denial of service.

Microsoft has published a complete report about these vulnerabilities, providing detailed information about variable poisoning, exploitation, and other information.

Users are recommended to upgrade to the latest version of the ncurses library in order to prevent this vulnerability from getting exploited.

Keep informed about the latest Cyber Security News by following us on Google NewsLinkedinTwitter, and Facebook.

Gurubaran
Gurubaran
Gurubaran is a co-founder of Cyber Security News and GBHackers On Security. He has 10+ years of experience as a Security Consultant, Editor, and Analyst in cybersecurity, technology, and communications.

Latest articles

GitLab Vulnerabilities Allow Attackers to Bypass Security and Run Arbitrary Scripts

GitLab has urgently released security updates to address multiple high-severity vulnerabilities in its platform...

LibreOffice Flaws Allow Attackers to Run Malicious Files on Windows

A high-severity security vulnerability (CVE-2025-0514) in LibreOffice, the widely used open-source office suite, has...

Cisco Nexus Switch Vulnerability Allows Attackers to Cause DoS

Cisco Systems has disclosed a high-severity vulnerability (CVE-2025-20111) in its Nexus 3000 and 9000...

Silver Fox APT Hackers Target Healthcare Services to Steal Sensitive Data

A sophisticated cyber campaign orchestrated by the Chinese Advanced Persistent Threat (APT) group, Silver...

Supply Chain Attack Prevention

Free Webinar - Supply Chain Attack Prevention

Recent attacks like Polyfill[.]io show how compromised third-party components become backdoors for hackers. PCI DSS 4.0’s Requirement 6.4.3 mandates stricter browser script controls, while Requirement 12.8 focuses on securing third-party providers.

Join Vivekanand Gopalan (VP of Products – Indusface) and Phani Deepak Akella (VP of Marketing – Indusface) as they break down these compliance requirements and share strategies to protect your applications from supply chain attacks.

Discussion points

Meeting PCI DSS 4.0 mandates.
Blocking malicious components and unauthorized JavaScript execution.
PIdentifying attack surfaces from third-party dependencies.
Preventing man-in-the-browser attacks with proactive monitoring.

More like this

GitLab Vulnerabilities Allow Attackers to Bypass Security and Run Arbitrary Scripts

GitLab has urgently released security updates to address multiple high-severity vulnerabilities in its platform...

LibreOffice Flaws Allow Attackers to Run Malicious Files on Windows

A high-severity security vulnerability (CVE-2025-0514) in LibreOffice, the widely used open-source office suite, has...

Cisco Nexus Switch Vulnerability Allows Attackers to Cause DoS

Cisco Systems has disclosed a high-severity vulnerability (CVE-2025-20111) in its Nexus 3000 and 9000...