NebuSec claims two ways around Telegram’s new Android widget protections

NebuSec claims two ways around Telegram’s new Android widget protections

Security company NebuSec says it found two ways to execute code beyond Telegram’s new Android security filter. Its demonstration used Telegram for Android 13.2.2 (7303), which includes the recently added defenses.

The researchers say their video shows a bot widget bypassing the filter and opening the phone’s calculator. They used a Telegram test server because the live service currently allows only approved bots to send widgets.

The demonstration leaves important limits unresolved. NebuSec did not establish whether the code could access Telegram messages or other parts of the phone. It also did not say whether users needed to start the bot or tap its widget.

Widgets are interactive elements delivered by bots within chats. They run JavaScript on the recipient’s device through an engine called QuickJS.

In its technical analysis, NebuSec describes two routes past the filter. One exploits a widget flaw outside the filter’s coverage. The other combines a widget flaw covered by the filter with a kernel vulnerability.

The company is withholding the exploit details. Its report provides no CVE identifier, names no fixed release, and does not say whether Telegram’s developers received the findings.

How Telegram’s protections work

Telegram introduced bot widgets last week. Two days later, an account named V12 posted a video claiming any Telegram message could trigger remote code execution.

Telegram subsequently separated QuickJS into its own Android process and introduced a seccomp filter. That filter controls system calls, the requests a process makes to the operating system. Both changes appear in the published code for Android 13.2.2 (7303).

Telegram’s documentation describes a widget sandbox that prohibits activities such as network access. NebuSec says those restrictions depend on code within QuickJS itself.

According to the researchers, a use-after-free or out-of-bounds write vulnerability could give a script control over the process’s memory. That access would undermine the engine’s internal restrictions.

NebuSec also says all widgets run within one process. A compromised widget would therefore share memory with widgets belonging to other bots.

The seccomp code lists a few dozen calls, including ptrace, bpf, and mount. Calls absent from that list pass through, and ioctl is not filtered. Android’s own restrictions still apply to the engine process.

The Hacker News found another qualification in the published Android code: the filter is configured for audit mode.

In that mode, attempts to launch programs or create processes remain blocked. Other listed calls are logged but permitted.

A code comment explains the setting: “Audit until the logs from the devices say the engine never makes them.” The published code does not establish whether distributed builds use that configuration.

Earlier assurances and a separate malware warning

Before NebuSec’s demonstration, Telegram chief executive Pavel Durov rejected claims that receiving a message alone could compromise users.

“No one could be hacked just by receiving a message,” he wrote in a channel post late last week.

His statement addressed widget-related code execution reports involving Android and Windows. Durov said users first needed to start a third-party service. He also said that issue had been fully patched on Telegram’s servers.

Telegram had previously said the issue shown in V12’s first demonstration was fixed for all users.

Widget access remains restricted. A telegram-bot-api contributor said late last week that general bots could not use widgets, even in private chats. No subsequent reply in the GitHub thread identifies eligible bots or announces that the restriction has ended.

Separately, Kaspersky reported suspected exploitation of a Telegram widget vulnerability when users visited certain channels.

The vendor said a PowerShell script ran unnoticed, then downloaded and launched WebRAT, also called Salat Stealer. The malware enables remote control and steals data from cryptocurrency wallets and Telegram accounts.

Kaspersky’s warning does not connect that activity to either demonstration. It identifies neither the vulnerability nor the Telegram version and gives no victim count.

The vendor advises against running widgets until a fix becomes available. As of this week, Telegram’s published Android code remained at 13.2.2 (7303).

Got Something To Say?

Your email address will not be published.