Skip to content

Instantly share code, notes, and snippets.

@gilangvperdana
Created May 15, 2022 07:29
Show Gist options
  • Save gilangvperdana/2cf38c24f4f7ae42b25746ade9f33b63 to your computer and use it in GitHub Desktop.
Save gilangvperdana/2cf38c24f4f7ae42b25746ade9f33b63 to your computer and use it in GitHub Desktop.
Fix SSH Key are too open on Windows 11

Fix SSH Key are too open on Windows 11

If you want to login with your key, but you see an error permission windows 11 "SSH key are too open" do this :

  • Make sure you was regenerate your key from puttygen to OpenSSH Key format
  • Open your Windows PowerShell then :
$path = ".\path\to\your\key.pem"
icacls.exe $path /reset
icacls.exe $path /GRANT:R "$($env:USERNAME):(R)"
icacls.exe $path /inheritance:r
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment