Diagram: a resource pack containing a font, a glyph that is shifted beyond the boundary of its memory buffer, and the Windows Calculator

minecraft2shell: a Minecraft client vulnerability delivered through server resource packs

minecraftsecurityhardening

minecraft2shell: a Minecraft client vulnerability delivered through server resource packs

On 22 November 2026, the GitHub repository bikini/minecraft2shell was published. It demonstrates a proof of concept (PoC) for code execution in the official, Mojang-signed Minecraft Java Edition 26.3 client on Windows. This post has two parts: For players, who play Minecraft on their own computer, and For server operators, who run servers.

As of 25 November 2026: Mojang replaced the font library in 26.3 on 24 November, but there has been no public statement yet. Older versions are unchanged according to Mojang's version metadata. We know of no attacks in the wild.

What happened

A server can offer players a resource pack. Such a pack contains, among other things, fonts. The PoC uses specially built TrueType fonts for this. After the pack is loaded, the server sends ordinary text, for example to the action bar. When this text is rendered, the bundled font library FreeType (version 2.14.3 in 26.3) processes hinting instructions from the font files. In doing so, FreeType writes outside its own memory area. That is a memory-safety bug, and the PoC turns it into code execution.

The PoC itself only opens the Windows Calculator and closes the game. The same route could, however, start any program with the rights of the logged-in user. Files, saved logins and sessions would then be within reach.

The PoC does not bypass the resource-pack prompt. On a server you have not trusted, you must accept the pack first. If the server entry is set to load packs without asking, there is no prompt.

Explained simply

Imagine a shelf with ten numbered compartments that belongs to you. Next to it are other people's shelves. Someone hands you a note: "Move the contents of every compartment up to number 14 a little further." You do not count how many compartments your shelf has, and you believe the note. For compartments 11 to 14 you therefore reach into the shelf next door and mess everything up there.

That is exactly what happens here. The shelf is the memory for one character, and the note is inside the font file. The shelf next door holds data the program uses to decide what it does next. Whoever controls what ends up there controls what the program does.

Which versions are affected

Mojang's version metadata names the font library used by each version. This table summarises it:

VersionFont library per Mojang metadataStatus
26.3lwjgl-freetype 3.4.3-mojang-2.15.0 (FreeType 2.15.0)Replaced on 24 November 2026, previously FreeType 2.14.3. FreeType 2.15.0 contains the fix.
26.1 and 26.2lwjgl-freetype 3.4.1 (FreeType 2.14.1)Unchanged, without the fix. Treat as affected.
1.20.5 to 1.21.11lwjgl-freetype 3.3.3 (FreeType 2.13.2)Unchanged, without the fix. Treat as affected.
1.20.4 and olderno FreeType libraryThis attack route does not exist there.

We compared the libraries from Mojang's download server with each other. The new file for 26.3 reports FreeType 2.15.0, was built on 24 November 2026 and carries a signature from Mojang. The old one reports FreeType 2.14.3. The FreeType project already corrected the faulty bounds check on 22 and 23 April 2026. That fix is part of 2.15.0, but of none of the versions 2.13.2, 2.14.1 and 2.14.3.

We did not run the PoC, neither against the old nor against the new library. So it is not proven that the older Minecraft versions can be exploited in practice, and Mojang has not confirmed it. They lack the same fix, though, and an article on minecraft.pl lists them as affected. Treat them as affected.

Mojang ships the same library for Linux and macOS, as the metadata shows. The PoC only works on Windows. No source confirms or rules out a flaw on the other platforms. So update there too, and do not rely on "I use Linux".

We know of no CVE number for this flaw. We also know of no reports of attacks in the wild (as of 25 November 2026). The PoC is public, so that can change. The PoC concerns the Java Edition.

For players

Update Minecraft 26.3

Close the game and the official launcher completely, then start both again. On start, the launcher downloads the changed version data.

As a check, the game folder should contain a folder 3.4.3-mojang-2.15.0 under libraries/org/lwjgl/lwjgl-freetype/. On Windows, the game folder is %APPDATA%\.minecraft.

Other launchers and modpacks

Third-party launchers keep their own version data. Prism Launcher and the Modrinth App are examples. We have found no statements from these projects about the flaw. Update the launcher and check which lwjgl-freetype version your instance uses. Modpacks on older versions stay on the old library.

Resource packs only from servers you trust

You find the setting under "Multiplayer". Select the server entry, click "Edit" and set "Server Resource Packs" to one of these values:

  • "Prompt": the game asks before loading.
  • "Enabled": the pack loads without asking.
  • "Disabled": packs from this server are not loaded.

Set servers you do not fully trust to "Prompt" or "Disabled". Decline packs from servers you do not know. If a server requires the pack and you do not trust it, do not join.

This lowers the risk, but it does not fix the flaw. Only the update does that.

Mods against the flaw

Community mods exist that switch off font hinting, for example minecraft2shell-fix. We have not reviewed them. Prefer the official update. A mod from an unknown source is itself code you have to trust.

For server operators

Your server is not the target. The target is your players' PCs. At the same time, your resource pack is exactly the channel that is abused. That is why your players must be able to trust it.

Secure your resource pack

Host the pack so that only you can change it. Also set an SHA-1 hash in server.properties. The client then rejects a swapped file. Replace the placeholders with your values:

resource-pack=https://example.org/pack.zip
resource-pack-sha1=0000000000000000000000000000000000000000
require-resource-pack=false

Also restrict access to the console, RCON, server.properties, and to plugins that can send packs or text to players. Check plugins that send their own resource packs.

Inform your players

Ask your community to update to 26.3. If your server runs an older version (1.20.5 to 26.2) and your players use the matching older client, they do not get the new library. So think about whether you really need to require a resource pack.

Your own PC

Admins are players too. An admin PC holds SSH keys, panel logins and tokens. So update your own client first, and do not test unknown servers from the machine you administer from.

Technical analysis

Note: This part explains the principle for everyone who wants to know more. We deliberately leave out addresses, offsets and everything you would need to rebuild it. The steps further up apply whether or not you read this part.

Why a font file contains a program

TrueType fonts contain small programs next to the outlines of the characters. This is called hinting. These programs nudge the points of a character so that it looks sharp at small sizes too. FreeType ships its own interpreter for this, which runs the font's instructions step by step. For FreeType, a font file is therefore input that contains commands. Here it comes from a server you do not control.

Why this happens in the client

The server needs nothing special for this. It offers a resource pack through the normal setting in server.properties and then sends ordinary text to the action bar. Everything else happens on your computer: the client loads the font from the pack and has FreeType compute the characters.

Minecraft is written in Java, and Java normally prevents memory errors like this. FreeType, however, is a library written in C that Minecraft uses through LWJGL. Java's protection does not apply in that part. The code runs in the same process as the game and with the same rights as you.

The bug: a limit from the wrong source

The instruction SHZ ("shift zone") moves all points of a zone by the same amount. To do that, FreeType has to know how many points there are. In FreeType 2.14.3 this place read:

else if ( exc->GS.gep2 == 1 && exc->zp2.n_contours > 0 )
  limit = exc->zp2.contours[exc->zp2.n_contours - 1] + 1;

The upper limit comes from the contour data here, that is, from information that belongs to the font. The code does not check whether the reserved memory is large enough for that many points. The PoC uses a composite character whose component claims more points than fit into the rest of the buffer. SHZ then also moves values that lie behind the buffer.

From memory error to code execution

A write in the wrong place does not start a program yet. The PoC needs four steps for that:

  1. Prepare the memory. The pack contains many variants of the same font. That raises the chance that the interpreter's working data sits directly behind the point buffer.
  2. Redirect the interpreter. The shift changes fields of the interpreter there, among them the reference to the point data. After that, the font's instructions read and write in the interpreter's memory and no longer in the points.
  3. Find the addresses. Windows loads libraries at a different address on every start (ASLR). The font program therefore reads a pointer that is currently in memory and calculates from there.
  4. Reassemble existing code. The PoC does not inject machine code of its own. It chains short pieces that already exist in the library and uses them to call Windows functions. In the PoC they start the Calculator and close the game.

All of this happens inside the font file. The server does not need to know anything about your computer and does not read anything back.

The numbers in the PoC only fit exactly one FreeType file. For another version an attacker would have to work them out again. The bug itself, however, is in every version without the fix.

How the bug was fixed

FreeType 2.15.0 no longer takes the upper limit from the contour data:

case 1:
  cur   = exc->pts.cur;
  limit = exc->pts.n_points > 4U ? exc->pts.n_points - 4U : 0;
  break;

The limit now follows from the number of points the zone actually has, minus the four helper points at the end. If the zone has too few points, the limit is zero and nothing is moved. The font can no longer dictate the value.

For 26.3, Mojang replaced the library with a build that contains FreeType 2.15.0. The version number of the game stayed the same. That is why you only recognise the update by the library, as described in the part for players.

Who you trust when something is "fixed"

Hardly any of you can check for yourselves whether the flaw is closed. You would have to be able to read the source code of the font library and examine the file that is shipped. So you rely on others having done this correctly. Computer science calls this trust, and it means something very concrete: whoever you trust, you hand control to.

An everyday comparison: you take your car to the garage because of the brakes. Afterwards the invoice says "brakes replaced". You cannot look for yourself. You drive off anyway, because you trust the garage. The invoice shows who did the work. It does not prove that the work is free of faults.

With this flaw you hand over control in several places:

  • To Mojang: you trust that the new library fixes the bug. The signature on the file is like the garage's invoice. It shows that the file comes from Mojang and says nothing about whether it is free of faults.
  • To your launcher: it decides which files it downloads and starts.
  • To every server whose resource pack you accept: with "Enabled" you hand over the decision for good. With "Prompt" you keep it.
  • To the authors of mods: their code runs with your rights. That also applies to mods that are meant to help against exactly this flaw.
  • To us: we compared files and source code but did not run the PoC. You can check our statements; the sources are listed below. If you do not, you trust us too.

Without trust nobody could use a computer. What matters is that you make the decision deliberately: who do I hand control to, how much, and what is the worst that happens if I am wrong? You have to trust Mojang if you want to play Minecraft. You do not have to trust a server you have known for five minutes.

Short summary

  • The flaw concerns the Java Edition. The PoC shows it for 26.3 on Windows.
  • Mojang replaced the font library in 26.3 on 24 November. There is no public statement.
  • Update Minecraft 26.3 and check whether the folder 3.4.3-mojang-2.15.0 exists.
  • Treat versions 1.20.5 to 26.2 as affected until proven otherwise.
  • Use resource packs only from servers you trust. Set others to "Prompt" or "Disabled".
  • Trusting someone means handing over control. Decide deliberately who gets it.
  • As an operator: set an SHA-1 hash for your pack and make sure only you can change it.

Sources and further reading

Share this article