Security Experts:

Connect with us

Hi, what are you looking for?

SecurityWeekSecurityWeek

Vulnerabilities

Technical Details Released for Recently Patched Zyxel Firewall Vulnerabilities

Security researchers with HN Security have published technical details on two vulnerabilities affecting many Zyxel products.

Tracked as CVE-2022-26531 and CVE-2022-26532, the two security holes were addressed in late May 2022 with patches for multiple firewalls, access points (APs), and AP controllers.

Security researchers with HN Security have published technical details on two vulnerabilities affecting many Zyxel products.

Tracked as CVE-2022-26531 and CVE-2022-26532, the two security holes were addressed in late May 2022 with patches for multiple firewalls, access points (APs), and AP controllers.

The vulnerabilities impact the Zyxel zysh binary, a restricted shell that implements the command-line interface (CLI) on a variety of Zyxel products. The CLI can be accessed via SSH and Telnet (which is not enabled by default), or via a web console, reachable via a browser.

HN Security’s researchers identified multiple issues in the binary, including several stack-based buffer overflows in code that handles diagnostic tests, two stack-based buffer overflows in the “debug” and “ssh” commands, several format string bugs, and a command injection bug.

“We demonstrated the possibility, as an authenticated admin or limited-admin user, to exploit the format string bugs and the OS command injection vulnerability to escape the restricted shell environment and achieve arbitrary command execution on the underlying embedded Linux OS, respectively as regular user and as root,” the researchers say.

The identified buffer overflows, the researchers say, existed because of unsafe API function calls. In fact, the researchers note that the zysh binary does not pack modern countermeasures against exploitation of memory corruption bugs.

Despite that, however, the buffer overflows could not be exploited to achieve code execution.

“Some zysh commands implement a special ‘extension’ argument that allows to specify arbitrary command-line arguments to be passed to the invoked OS command that underlies each functionality. Any additional arguments we specify after the ‘extension’ keyword are appended to the OS command line. We identified format string bugs in multiple zysh commands that implement this feature,” HN Security says.

The researchers were able to exploit these format string bugs to achieve arbitrary code execution and to escape the restricted shell environment and have published proof-of-concept exploit code to prove that. They also note that automating and weaponizing the exploit might not be too hard.

Zyxel collectively assigned the identifier CVE-2022-26531 for the memory corruption bugs, but addressed the OS command injection issue – which is tracked as CVE-2022-26532 – separately.

This vulnerability, HN Security explains, was found in the code that handles the “packet-trace” command. The researchers discovered that they could abuse the “extension-filter” argument to “specify additional arbitrary command-line arguments to be passed to tcpdump,” which allowed them to execute arbitrary code as root.

On May 24, Zyxel published a security advisory to announce patches for CVE-2022-26531, CVE-2022-26532, and two other vulnerabilities impacting the same product range (tracked as CVE-2022-0734 and CVE-2022-0910).

Impacted products include USG/ZyWALL, USG FLEX, ATP, VPN, and NSG firewalls, NXC2500 and NXC5500 AP controllers, and nearly 30 access point products.

Related: Zyxel Firewall Vulnerability Exploitation Attempts Seen One Day After Disclosure

Related: Critical Vulnerability Allows Remote Hacking of Zyxel Firewalls

Related: Zyxel Warns Customers of Attacks on Security Appliances

Written By

Ionut Arghire is an international correspondent for SecurityWeek.

Click to comment

Daily Briefing Newsletter

Subscribe to the SecurityWeek Email Briefing to stay informed on the latest threats, trends, and technology, along with insightful columns from industry experts.

Expert Insights

Related Content

Cloud Security

VMware vRealize Log Insight vulnerability allows an unauthenticated attacker to take full control of a target system.

IoT Security

Lexmark warns of a remote code execution (RCE) vulnerability impacting over 120 printer models, for which PoC code has been published.

Mobile & Wireless

Apple rolled out iOS 16.3 and macOS Ventura 13.2 to cover serious security vulnerabilities.

Email Security

Microsoft is urging customers to install the latest Exchange Server updates and harden their environments to prevent malicious attacks.

Application Security

Drupal released updates that resolve four vulnerabilities in Drupal core and three plugins.

Mobile & Wireless

Technical details published for an Arm Mali GPU flaw leading to arbitrary kernel code execution and root on Pixel 6.

Vulnerabilities

Less than a week after announcing that it would suspended service indefinitely due to a conflict with an (at the time) unnamed security researcher...

Vulnerabilities

Security researchers have observed an uptick in attacks targeting CVE-2021-35394, an RCE vulnerability in Realtek Jungle SDK.