Skip to content

Instantly share code, notes, and snippets.

View SAPIENTechnologies's full-sized avatar

SAPIEN Technologies, Inc. SAPIENTechnologies

View GitHub Profile
@SAPIENTechnologies
SAPIENTechnologies / Test-PSFileHash.ps1
Created December 20, 2016 18:09 — forked from juneb/Test-PSFileHash.ps1
Verifies that the file hash of a PowerShell open-source installer matches expected value.
<#
.SYNOPSIS
Verifies that the file hash of a PowerShell open-source installer matches expected value.
.DESCRIPTION
Compares the file hash of a PowerShell open-source installation file to the expected file hash value. Supports
all installation file types, including msi, zip, rpm, deb, pkg, and tar.gz, beginning with installers for PowerShell
release 6.0.0.9.
To get a list of installer file names, but not test the file hash, use the ListOnly parameter.