Skip to content

Instantly share code, notes, and snippets.

@rufflabs
Created May 23, 2015 13:52
Show Gist options
  • Save rufflabs/7747faa01ee4a253f4f3 to your computer and use it in GitHub Desktop.
Save rufflabs/7747faa01ee4a253f4f3 to your computer and use it in GitHub Desktop.
Converts a Secure String into plain text.
#$Secure = <your secure string>
$Plain = [Runtime.InteropServices.Marshal]::PtrToStringAuto([Runtime.InteropServices.Marshal]::SecureStringToBSTR($Secure))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment