>_ CVE-2026-2SHELL

PowerShell2Shell

A critical vulnerability that lets an attacker with a shell obtain a shell. Yes, it has a logo.

Windows PowerShell

  

Advisory

CVSS score
10.0 Critical0.0 once you think about it
Attack vector
LocalYou have to already be there
Privileges required
The ones you haveAnd no more, sadly
Affected versions
1.0 to latestEvery release since 2006
Exploited in the wild
DailyMostly by sysadmins
Vendor status
Works as intendedTicket closed in 4 minutes

What’s going on

PowerShell, a shell, contains an undocumented feature by which typing powershell spawns another shell. An attacker who has achieved code execution inside PowerShell can therefore escalate from “has a shell” to “has a shell”.

Researchers believe the flaw can be chained indefinitely. In lab conditions, one analyst reached a nesting depth of 412 shells before forgetting why they started.

Proof of concept

The full exploit is reproduced below. We debated responsible disclosure for some time and decided it was fine.

PS C:\> powershell

For a weaponised version with persistence, press the up arrow and Enter again.

Mitigation

There is no patch. Recommended workarounds, in order of effectiveness:

  1. Type exit. This reduces your shell count by one.
  2. Repeat step 1 until the window closes.
  3. Switch to cmd.exe, which our follow-up paper, Cmd2Shell, will cover next quarter.
  4. Unplug the computer and take up woodworking.

Disclosure timeline

  1. Researcher opens PowerShell, types powershell.
  2. Researcher notices a second shell. Gasps audibly.
  3. Domain name registered.
  4. Logo commissioned. Four rounds of feedback on the spiral.
  5. Vendor notified. Vendor replies “that is what PowerShell does”.
  6. Conference talk accepted.
  7. Merch store live.

The extended 2Shell universe

PowerShell2Shell joins a proud lineage. Somewhere along the way, a vulnerability stopped counting unless its name ended in “Shell”.

NameYearWhat it actually was
Shellshock2014Bash, the grandparent of the naming scheme
Log4Shell2021Logging a string could run code. Ruined everyone’s December
Spring4Shell2022Spring Framework, and a lot of “is it as bad as Log4Shell?” threads
Text4Shell2022Apache Commons Text, briefly feared, mostly fine
React2Shell2025React Server Components, and another ruined December
PowerShell2Shell2026A shell. Into a shell. You’re welcome.
Coming soon to a CVE near you
Toaster4Shell

Lets a crumb execute arbitrary bread.

Days since the last 2Shell: 0

Questions

Am I affected?

If you have ever opened PowerShell, yes. If you have not, you are pre-affected.

Is there a CVE?

We requested one. The response was a single reaction emoji, which we have chosen to interpret as approval.

Why “2” and not “4”?

Our branding consultant said “4” is so 2021. “2” suggests movement, journey, ambition. Next year it will be “Shell2Shell2Shell”.

Does pwsh 7 fix it?

No. It makes it cross-platform. You can now get a shell from a shell on Linux, which had a shell.

Can I get a shirt?

The merch store sold out of shirts and now only sells shells.