Intel

AIKIDO-2026-123108

workerd is vulnerable to Use-After-Free

Use-After-Free Pre-CVE
Found by Aikido Intel before public disclosure or CVE publication.
Published 3 days ago

50

Medium Risk

This Affects:

JSworkerd
0.0.1 - 1.20260804.1
Fixed in 1.20260807.2
Are you affected? Scan for Free

TL;DR

Native jsg::Function objects in the workerd runtime can free themselves while they are still being invoked. jsg::Function::operator() called native functions through a bare reference into the owning Ref, so a native callback that runs JavaScript can drop that reference mid-call and leave a dangling pointer on the stack. The reachable case is TextEncoderStream, whose transform algorithm is a native lambda: a user-supplied toString() that cancels the readable side can clear the algorithms and free the function while it is still executing. Before the fix this use-after-free can crash the host process or corrupt runtime memory. The fix holds a reference for the duration of the call so the function is not accessed after it has been freed.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range.

Background info

workerd is vulnerable to Use-After-Free in versions 0.0.1 - 1.20260804.1.

How to fix this

Upgrade the workerd library to the patch version.

Are You Affected?

Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.

Free. No credit card required.

Aikido Platform