Examples/Safe_OutdatedCrypto_1.ps1
|
function Get-Sha256Hash { param($text) $enc = [System.Text.Encoding]::UTF8 $buffer = $enc.GetBytes($text) $sha256 = New-Object System.Security.Cryptography.SHA256CryptoServiceProvider return $sha256.ComputeHash($buffer) } |