Skip to content

Instantly share code, notes, and snippets.

@jmolinasoler
Created April 23, 2020 19:31
Show Gist options
  • Save jmolinasoler/60372d5184087012aa6b6401a9e764cf to your computer and use it in GitHub Desktop.
Save jmolinasoler/60372d5184087012aa6b6401a9e764cf to your computer and use it in GitHub Desktop.
Steps to sign the scripts in windows
# New-SelfSignedCertificate -CertStoreLocation Cert:\CurrentUser\My -Type CodeSigningCert -Subject "jmolinaso Code Signing"
# Get-ChildItem -Path Cert:\CurrentUser\My | ? Subject -EQ "CN=jmolinaso Code Signing"
# Move-Item -Path (dir Cert:\CurrentUser\My).PSPath -Destination "Cert:\CurrentUser\Root"
# Set-AuthenticodeSignature -FilePath .\scriptToSign.ps1 -Certificate (dir Cert:\CurrentUser\Root -CodeSigningCert) -TimestampServer http://timestamp.globalsign.com/scripts/timstamp.dll
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment