0
0
PowerShellscripting~5 mins

Code signing in PowerShell - Cheat Sheet & Quick Revision

Choose your learning style9 modes available
Recall & Review
beginner
What is code signing in PowerShell?
Code signing is the process of digitally signing scripts or executables to verify their origin and ensure they have not been altered. It helps users trust the code they run.
Click to reveal answer
beginner
Which PowerShell cmdlet is used to sign a script?
The <code>Set-AuthenticodeSignature</code> cmdlet is used to digitally sign a PowerShell script with a certificate.
Click to reveal answer
beginner
What is a code signing certificate?
A code signing certificate is a digital certificate issued by a trusted authority. It contains a public key and identifies the signer, allowing verification of the script's authenticity.
Click to reveal answer
beginner
How can you check if a PowerShell script is signed and valid?
Use Get-AuthenticodeSignature <script.ps1>. It shows the signature status like Valid, UnknownError, or NotSigned.
Click to reveal answer
beginner
Why is code signing important for script security?
Code signing ensures scripts come from a trusted source and have not been changed. It protects users from running harmful or tampered code.
Click to reveal answer
Which cmdlet signs a PowerShell script?
ASign-Script
BGet-AuthenticodeSignature
CNew-Signature
DSet-AuthenticodeSignature
What does a code signing certificate provide?
AEncryption of script content
BVerification of script origin and integrity
CExecution permission for scripts
DAutomatic script updates
How do you verify a script's signature in PowerShell?
AGet-AuthenticodeSignature
BSet-AuthenticodeSignature
CCheck-Signature
DVerify-Script
What does a 'Valid' status mean when checking a script's signature?
AThe script is unsigned
BThe certificate is expired
CThe signature is trusted and intact
DThe script has errors
Why should you run only signed scripts?
AThey come from trusted sources and are not altered
BThey are guaranteed error-free
CThey run faster
DThey use less memory
Explain what code signing is and why it matters in PowerShell scripting.
Think about how you can prove a script is safe to run.
You got /5 concepts.
    Describe the steps to sign a PowerShell script and verify its signature.
    Consider the cmdlets used for signing and checking.
    You got /4 concepts.