Public/ConvertFrom-EncryptedData.ps1
<#
# ConvertFrom-EncryptedData Ohne Beschreibung - **Hashtags** UserCmdlet - **Version** 2019.10.19 #> using namespace System using namespace System.Runtime.InteropServices $ErrorActionPreference = [System.Management.Automation.ActionPreference]::Stop Set-StrictMode -Version Latest Function ConvertFrom-EncryptedData { <# .SYNOPSIS Verschlüsselte Daten entschlüsseln. .DESCRIPTION Long description .PARAMETER Key dfgkjdfhgkdfjghkfjh .PARAMETER TextInput .EXAMPLE .INPUTS .OUTPUTS .NOTES VERSION 2019-10-10 TAG Crypt String SecureString AUTOR a.krick@outlook.com COMMENT Zum entschlüsseln von Musterlösungen #> [CmdletBinding()] Param ( [Byte[]]$Key, [String]$TextInput ) return $TextInput | ConvertTo-SecureString -Key $Key | ForEach-Object -Process { [Marshal]::PtrToStringAuto([Marshal]::SecureStringToBSTR($_)) }; } |