Description
GNU Emacs for Android is vulnerable to an integer overflow in sfnt_read_name_table() in src/sfnt.c. The function computes an allocation size using a 32-bit length value from a TrueType font file without overflow checking. On 32-bit targets, a crafted font causes the calculation to wrap, resulting in an undersized heap allocation. A subsequent read() call writes beyond the buffer, causing a heap buffer overflow. An attacker can deliver a malicious font file via email, EWW (Emacs Web Wowser), or documents with custom faces, causing Emacs to load it. This can lead to heap memory corruption and potential code execution.
This issue was fixed in commit d51a4722316efe0960994d371e1859099894d1ca
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| GNU | Emacs | ≤ 30.2 | — |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 26.10 | emacs +2 | No fix yet | — |
| Ubuntu 26.04 LTS | xemacs21 +1 | No fix yet | — |
| Ubuntu 24.04 LTS | xemacs21 +1 | No fix yet | — |
| Ubuntu 22.04 LTS | xemacs21 +1 | No fix yet | — |
| Ubuntu 20.04 LTS | xemacs21 +1 | No fix yet | — |
Show 8 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 18.04 LTS | xemacs21 +1 | No fix yet | — |
| Ubuntu 16.04 LTS | xemacs21 +1 | No fix yet | — |
| Ubuntu Pro 26.04 LTS | emacs | No fix yet | — |
| Ubuntu Pro 24.04 LTS | emacs | No fix yet | — |
| Ubuntu Pro 22.04 LTS | emacs | No fix yet | — |
| Ubuntu Pro 20.04 LTS | emacs | No fix yet | — |
| Ubuntu Pro 18.04 LTS | emacs25 | No fix yet | — |
| Ubuntu Pro 16.04 LTS | emacs24 | No fix yet | — |
Advisories 1
- WID-SEC-2026-2721 GNU Emacs: Mehrere Schwachstellen BSI CERT-Bund (WID) · Aug 10, 2026