Scripting Blog [archived]

Formerly known as the "Hey, Scripting Guy!" blog

PowerTip: Add network adapter to packet capture session

Summary: Learn to use Windows PowerShell to add a network adapter to a capture session. (image)  How can I use Windows PowerShell to add a network adapter to a packet capture session? (image) Use the Add-NetEventNetworkAdapter cmdlet and specify the name of the adapter. In the following example, I create a network capture session, add a ...

Migrate Windows CA from CSP to KSP and from SHA-1 to SHA-256: Part 5

Summary: Thomas Rayner, Microsoft Cloud & Datacenter Management MVP, shows how to modify the registry for SHA-256 as a part of migrating a Windows certification authority from CSP to KSP and from SHA-1 to SHA-256. Hello! I’m Thomas Rayner, a proud Cloud & Datacenter Management Microsoft MVP, filling in for The Scripting Guy this ...

PowerTip: Count backwards in array

Summary: Cloud & Datacenter Management MVP, Thomas Rayner, shows how to count backwards in a Windows PowerShell array. (image)  I know I can access the first, second, and third items in an array by using $Array[0], $Array[1], and $Array[2], but how can I count backwards? (image)  Use negative numbers, for example: $Array = @('first','...

Migrate Windows CA from CSP to KSP and from SHA-1 to SHA-256: Part 4

Summary: Thomas Rayner, Microsoft Cloud & Datacenter Management MVP, shows how to import a certificate into a KSP and bring it into the certificate store. Hello! I’m Thomas Rayner, a proud Cloud & Datacenter Management Microsoft MVP, filling in for The Scripting Guy this week. You can find me on Twitter (@MrThomasRayner) or on my ...