Skip to content

Instantly share code, notes, and snippets.

@Nevor
Nevor / crash.ps1
Last active April 11, 2024 19:11
BSOD without elevation from Powershell on Windows 10 Creator Update (Update: Problem is BACK on Windows 11 after KB5034848)
# From https://stackoverflow.com/questions/43583651/windows-10-creators-updates-breaks-winforms-apps-bsod
# (This can be copy pasted into Powershell)
[System.Reflection.Assembly]::LoadWithPartialName("System.Windows.Forms")
$form = new-object System.Windows.Forms.Form
$lastPanel = $form
for($i = 0; $i -lt 45; $i++) {
$newPanel = new-object System.Windows.Forms.Panel
$newPanel.Dock = [System.Windows.Forms.DockStyle]::Fill
$lastPanel.Controls.Add($newPanel)
$lastPanel = $newPanel