Skip to content

Instantly share code, notes, and snippets.

View Divine-Shadow's full-sized avatar

Bill Molchan Divine-Shadow

  • Perplexity Games
View GitHub Profile
@Divine-Shadow
Divine-Shadow / enable-windows-ssh.ps1
Last active May 17, 2026 03:32
Enable Windows OpenSSH for Tailscale operator handoff
$PublicKey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKh8QnHldxC7TdgHbEmScNQOXcCbljbSLyqpLDuU9j8y 11306048+Divine-Shadow@users.noreply.github.com"
$TailscaleCidr = "100.64.0.0/10"
$CapabilityName = "OpenSSH.Server~~~~0.0.1.0"
$SshdPath = Join-Path $env:WINDIR "System32\OpenSSH\sshd.exe"
function Require-Admin {
$identity = [Security.Principal.WindowsIdentity]::GetCurrent()
$principal = [Security.Principal.WindowsPrincipal]::new($identity)
if (-not $principal.IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator)) {
throw "run PowerShell as Administrator"