TechPastWeek logo
Gaming Hardware9 min read

Switch 2 Gets a Software-Only Jailbreak, Built With Help From OpenAI Codex

Researcher pepsipu released ns2jb on 22 October 2026, a tethered software-only jailbreak for the Switch 2 on firmware 23.0.1, with help from OpenAI Codex.

A black Nintendo Switch 2 handheld console lying face up on a white surface, its screen switched off, with both Joy-Con 2 controllers attached and the coloured rings around their analog sticks visible
On this page

Key takeaways

  • Security researcher Sammy Hajhamid, who publishes as pepsipu, released ns2jb on 22 October 2026, a software-only tethered jailbreak for the Nintendo Switch 2 that he says runs on firmware 23.0.1.
  • pepsipu describes it as the first software-only exploit for the Switch 2; the claim comes from the researcher and early reporting rather than an official record.
  • The chain runs through SmileBASIC 4, a Switch 1 game, where a 32-bit integer overflow in the interpreter's REMOVE command produced out-of-bounds read and write.
  • ns2jb is tethered and is not custom firmware: it has to be relaunched from the game after every reboot and grants code execution with ordinary sysmodule permissions.
  • OpenAI's Codex found bugs and built tooling, but pepsipu says the jailbreak took 'substantial effort for ~2 weeks' and that a human chose the exploit path.

The Nintendo Switch 2 has a software-only jailbreak. On 22 October 2026, security researcher Sammy Hajhamid, who publishes as pepsipu, released ns2jb, a tethered exploit chain that he says runs on the console's current firmware, 23.0.1. He describes it as the first such exploit for the Switch 2 to his knowledge, and early coverage from TechPowerUp, Digital Trends and HotHardware repeats the "first software-only jailbreak" framing. The claim belongs to the researcher and those outlets; no official record settles it.

Related reading: Sony Brings Back See-Through Plastic With the Prism PS5 Collection · PS5 Sales Rose 22% in September as the Rest of the US Market Fell.

"Tethered" carries most of the practical weight. ns2jb has to be launched again from a game after every reboot, so it is a session rather than a permanent state, and it is not custom firmware. What it provides is arbitrary code execution with the permissions of an ordinary system module: enough to run homebrew, back up save files, reverse-engineer and mod Switch 2 games, and reach most peripherals through memory-mapped I/O.

A chain, not a single bug

Console security is layered, and pepsipu's write-up, dated 18 October 2026, reads as a tour of the layers. The public release and the press coverage landed four days later, on 22 October. The system under test was not one console but two: a Switch 1 and a Switch 2 on a bench, with JetKVMs feeding controller inputs and capturing HDMI output, plus a Bluetooth switch wired to press the power button whenever a run crashed the machine. Every failed attempt cost a reboot, and the rig turned each failure into another data point instead of a manual reset.

The first route went through the browser. Codex, OpenAI's coding agent, found a WebKit n-day that could be loaded through a custom Wi-Fi captive portal and reported a native control-flow hijack. The approach did not generalise. Execute-only memory, pointer authentication and control-flow integrity each cut against it, and the attempt did not succeed. The dead end is instructive. On this hardware a memory-safety bug, on its own, does not get close to a working exploit.

The way in was a BASIC interpreter

SmileBASIC 4 is a Switch 1 title that lets users write and play their own programs. Running on the Switch 2 through backwards compatibility, it gave the exploit a large, permissive interpreter that accepts user code by design. Codex found a 32-bit integer overflow in the array REMOVE command. The bounds check compared position + count, and the sum could wrap negative, so a bad index passed validation. The memmove that followed pulled the eight bytes immediately before the array into it. Those bytes hold a pointer to the array itself, and treating the backing store as a string turned that pointer leak into out-of-bounds read and write.

The second bug sat in fs, one of the console's built-in system modules. Path normalisation mishandled paths containing a parent-directory component written with a backslash, such as /..\, and a 0x301-byte temporary heap buffer overflowed. Codex identified a BufferedStorage cache object that could be hijacked for arbitrary read and write. pepsipu then set the saved PID to 1 in SmileBASIC's connection object, which gave his process FullPermission inside fs and let him dump internal storage along with the code of every ordinary sysmodule.

From read and write to code execution

The final stage turned a memory primitive into a general capability. Holding read and write inside fs, he replaced the ExeFS object behind the loader's IPC handle with a temporary filesystem of his own. It served a valid main.npdm next to an arbitrary main, which produced code execution as any ordinary sysmodule. A permission attached to the ro NPDM then allowed him to map process memory and patch fs's own code, ending with native execution at fs's privilege level.

The ns2jb chain in four stages

A WebKit n-day loaded through a captive portal produced a reported control-flow hijack, but it did not survive execute-only memory, pointer authentication and control-flow integrity. A 32-bit integer overflow in SmileBASIC 4's REMOVE command leaked an array pointer and gave out-of-bounds read and write. A path-normalisation overflow in the fs sysmodule, triggered by a /..\ path and paired with a hijacked BufferedStorage cache object, produced arbitrary read and write. Replacing the ExeFS object behind the loader's IPC handle, then patching fs through the ro NPDM's permissions, produced native code execution.

That sequence explains why the result is described as powerful but not complete. pepsipu calls arbitrary code execution with ordinary sysmodule permissions "really powerful", and says he hopes it helps the homebrew community move toward custom firmware. The ceiling is lower than custom firmware, and he does not claim otherwise.

The proof was a modded Mario Kart World

To show the chain working, pepsipu modded Mario Kart World with custom characters: Cinnamoroll, Peter Griffin, Hatsune Miku, Steve from Minecraft and the red Angry Bird. He said the mod was "entirely vibecoded in a day, and was just for fun." The demo is the part most people will see. It shows the exploit doing something a stock console cannot do, which is a clearer advertisement than the bug write-up.

Another modder, gezine_dev, has claimed that SmileBASIC 4 is "not strictly needed" for the chain. Treat that as an unverified counterclaim: no alternative path has been published, and the released exploit depends on the game.

Backwards compatibility widened the door

The most transferable lesson is about the back catalogue. A console that runs last-generation software inherits last-generation bugs. The Switch 2 plays Switch 1 titles, and that library includes an interpreter that runs whatever a user types into it. Any flaw in that interpreter sits inside the newer console's trust boundary, with the same access to system services as any other running title.

Every layer in the chain was a real component with a real job: a browser, a game interpreter, a filesystem module, a loader. The exploit did not break the strongest of them. It walked from the least trusted component to the most privileged one, using each stage to reach the next. Console makers spend heavily on mitigations for that reason, and on shrinking the number of components that accept untrusted input. The Switch 2 runs modern mitigations, and it still runs software written for the previous generation.

Codex found bugs. A human chose the path.

The AI angle is why this story travelled beyond the homebrew forums. Codex found the SmileBASIC overflow and the BufferedStorage cache object that made the second bug exploitable. It also wrote tooling and helped automate the test bench. The tempting headline is that an AI jailbroke a console. pepsipu pre-empts it in the write-up, and the correction is specific: he says the work took "substantial effort for ~2 weeks", and that an early attempt to have Codex reach userland code execution on its own did not succeed. A human set the objective, judged which bugs were worth chasing and decided when a path was dead.

What the case does show is a shift in the cost of vulnerability research. Manual audit and fuzzing have always been slow, and an agent that can read a decompiled interpreter, propose a hypothesis and write the harness around it compresses the gap between idea and test. The Switch 2 is closed hardware with no public symbols, which is the setting where that kind of help saves the most time, at least in this case.

The limits are just as visible. Codex reported a control-flow hijack on the WebKit path that led nowhere usable, and the winning route came from a much older and simpler component. Finding bugs is not the same as building a chain under pointer authentication and control-flow integrity, and the write-up does not credit the model with that part.

What ns2jb cannot do

Three limits define the release. It is tethered, so it ends at the next reboot. It needs SmileBASIC 4, which means a specific purchase and a specific game card or download. And it is not custom firmware: pepsipu presents it as something that could help the homebrew scene get there, not as the thing itself.

The write-up lists homebrew, game modding, save backups and peripheral access. pepsipu also tested the chain on the Switch 1 but has not packaged it. The write-up does not present the exploit as a route to running copied games, and the reported capabilities stop at ordinary sysmodule privileges rather than the persistent control that custom firmware would need.

For most players, nothing changes this week. The process needs a purchased game, a guided sequence and a reboot after every power cycle, and The Verge reported that it remains hard to use.

"This jailbreak still seems extremely complex for most people, and its full impact isn't clear yet." — The Verge, 22 October 2026

Nintendo has not said anything

Nintendo had not commented publicly when the coverage ran. Its record suggests the next firmware update will close the fs bug and possibly the interpreter route, moving the version past 23.0.1. That is the pattern for every console exploit: disclosure starts a clock, and the patch ends the window for anyone who updates.

The patch will not end the interest. Users on the Switch 2 hacks subreddit spent the week arguing about how much the jailbreak matters, and The Verge frames it as a possible start of a run of exploits, particularly if modders use AI assistance to find more. What is different is that one researcher, working for about two weeks, could publish the whole route.

What to watch

Three signals will show whether ns2jb is a one-off or a marker. The first is packaging: a tethered exploit that lives in a write-up and a repository is a demonstration, and a tool with a guided launcher and a supported game list is something else. The second is Nintendo's next firmware, which will show how urgently the company treats a software-only chain that enters through a legacy title.

The third is the homebrew scene's response. pepsipu published the route and the reasoning, and the value of that to other researchers may prove larger than the demo. If the community builds on it, the question stops being whether the Switch 2 can be jailbroken and becomes how long each new firmware holds.

For now the console has a working software-only exploit on its current firmware, and Nintendo has said nothing about it.

Cover image: A Nintendo Switch 2 in handheld mode. Photo by Crisco 1492, Wikimedia Commons, CC BY-SA 4.0.

Tags

Frequently asked questions

What is the Switch 2 ns2jb jailbreak?
ns2jb is a software-only, tethered jailbreak for the Nintendo Switch 2, released by security researcher Sammy Hajhamid, known as pepsipu, on 22 October 2026. It uses the Switch 1 game SmileBASIC 4 to gain arbitrary code execution with the permissions of an ordinary system module, which is enough to run homebrew, back up saves and mod games.
Does ns2jb work on the latest Switch 2 firmware?
pepsipu says ns2jb runs on firmware 23.0.1, which was the current version when he released it on 22 October 2026. The exploit has to be launched again from SmileBASIC 4 after every reboot, so a later system update that closes the bugs would end it until someone finds another route.
Is the Switch 2 jailbreak permanent?
No. ns2jb is tethered, which means it must be run again from a game after each restart, and it is not custom firmware. It provides code execution for the current session with ordinary sysmodule privileges, not control that survives a reboot.
Did OpenAI Codex create the Switch 2 jailbreak on its own?
No. Codex found the memory-safety bugs and helped build the test harness, but pepsipu says the work took substantial effort over about two weeks and that an attempt to have the agent reach userland code execution on its own did not succeed. A human set the goal and chose which path to follow.
Share

Found this useful? Share it with your team.

TPW Editorial

TPW Editorial

Editorial Team

TechPastWeek's editorial team reports and edits every story we publish. We research each piece against primary and credible secondary sources, and a human editor reviews and signs off before it goes live.

Featured & most read

Keep reading