Little Known Ways Of How To Sign A PowerShell Script

Asked By 30 points N/A Posted on -
qa-featured

How to sign a PowerShell script? What is the command to sign the scripts in a PowerShell? What is the easiest and quickest method to sign PowerShell script?

SHARE
Answered By 0 points N/A #186654

Little Known Ways Of How To Sign A PowerShell Script

qa-featured

You can also use an already installed code signing certificate from the user certificate store to sign a PowerShell Script. Get a reference to the code signing certificate by the CmdLet

Get-ChildItem –CodeSigningCert

Certificate can be signed by the CmdLet

Set-AuthenticodeSignature (it will add a signature block at the end.)

e.g.:

[CmdletBinding()]

Param()

Write-Host “Hello”

# SIG # Begin Signature block

#

#

#

# SIG # End Signature block

Login/Register to Answer

Related Questions