Intel

AIKIDO-2026-561892

greenlet is vulnerable to Use After Free

Pre-CVE
Found by Aikido Intel before public disclosure or CVE publication.
Published Jul 24, 2026
July 24, 2026

20

CVE Score

Low

Use After Free

Are you affected? Scan for Free

TL;DR

On free-threaded (no-GIL) builds of CPython, greenlet's saved C-stack state could become inconsistent if the garbage collector ran while a greenlet was suspended, leading to a use-after-free and interpreter crash. A related issue could deadlock the interpreter if a greenlet switch happened while a critical section lock was held.

How do I fix this?

Upgrade the greenlet library to the patch version.

Who does this affect?

You are affected only if you run a free-threaded (no-GIL) build of CPython 3.14 or newer and use greenlet-based libraries (such as gevent or Playwright's sync API) under garbage-collector pressure; this can cause unpredictable crashes or, less commonly, a deadlock. Standard GIL-enabled CPython builds are not affected.

Package

Versions

3.3.0 - 3.5.3

Fixed in 3.5.4

Background info

greenlet is vulnerable to Use After Free in versions 3.3.0 - 3.5.3.

Get secure today,
quickly and for free.

Secure your code, cloud, and runtime in one central system. Connect a repo to discover what the reasoning agents find in your codebase.

No credit card required | Scan results in 32 seconds.

Trusted by 150k+ orgs
  • Revolut
  • n8n
  • Lovable
  • Deel
  • Prove
  • Omnea