Skip to content

Instantly share code, notes, and snippets.

View rjmii's full-sized avatar

Robert McCleary rjmii

View GitHub Profile
@rjmii
rjmii / chmod-400.ps1
Last active May 17, 2020 16:38 — forked from jaskiratr/chmod-400.cmd
Set permission of file equivalent to chmod 400 on Windows.
$path = ".\.vagrant\machines\default\hyperv\private_key"
icacls.exe $path /reset
icacls.exe $path /GRANT:R "$($env:USERNAME):(R)"
icacls.exe $path /inheritance:r