Skip to content

Instantly share code, notes, and snippets.

@WitherOrNot
WitherOrNot / a.md
Last active February 1, 2026 18:00
Disable S Mode without disabling secure boot or using MS account

S Mode Escape

Requirements

  • Access to Administrator-level account
  • Does not require MS account
  • Does not require disabling secure boot

How to Use

@WitherOrNot
WitherOrNot / tspkgen.py
Last active February 1, 2026 03:02
Terminal Services License Server ID + License Key Pack generator
from Crypto.Cipher import ARC4
from hashlib import sha1, md5
from random import randint
from ecutils.core import Point, EllipticCurve
from sys import argv
KCHARS = "BCDFGHJKMPQRTVWXY2346789"
SPK_ECKEY = {
"a": 1,
@WitherOrNot
WitherOrNot / pidgenx.ipynb
Last active February 16, 2025 03:27
PIDGENX validation implementation in SageMath (works on SageMath 9.0)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

Uninstall Microsoft Edge

Important

Working on the latest supported Windows versions. Run Windows Update before following this guide.

1. Open Powershell > RUN AS ADMIN

2. Paste in irm https://gist.github.com/ave9858/c3451d9f452389ac7607c99d45edecc6/raw/UninstallEdge.ps1 | iex and press enter

3. Microsoft Edge will be completely uninstalled.

function UninstallLicenses($DllPath) {
$TB = [AppDomain]::CurrentDomain.DefineDynamicAssembly(4, 1).DefineDynamicModule(2).DefineType(0)
[void]$TB.DefinePInvokeMethod('SLOpen', $DllPath, 22, 1, [int], @([IntPtr].MakeByRefType()), 1, 3)
[void]$TB.DefinePInvokeMethod('SLGetSLIDList', $DllPath, 22, 1, [int],
@([IntPtr], [int], [Guid].MakeByRefType(), [int], [int].MakeByRefType(), [IntPtr].MakeByRefType()), 1, 3).SetImplementationFlags(128)
[void]$TB.DefinePInvokeMethod('SLUninstallLicense', $DllPath, 22, 1, [int], @([IntPtr], [IntPtr]), 1, 3)
$SPPC = $TB.CreateType()
$Handle = 0
@MyITGuy
MyITGuy / PackedGuid.psm1
Last active November 19, 2025 19:22
PowerShell: Convert GUID to/from Packed
function ConvertFrom-PackedGuid {
<#
.SYNOPSIS
Converts a packed globally unique identifier (GUID) string into a GUID string.
.DESCRIPTION
Takes a packed GUID string and breaks it into 6 parts. It then loops through the first five parts and reversing the order. It loops through the sixth part and reversing the order of every 2 characters. It then joins the parts back together and returns a GUID.
.EXAMPLE
ConvertFrom-PackedGuid -PackedGuid '2820F6C7DCD308A459CABB92E828C144'
The output of this example would be: {7C6F0282-3DCD-4A80-95AC-BB298E821C44}