< Back

Convert-CSecureStringToString

Sun Jan 12, 2020 9:02 pm

NAME Convert-CSecureStringToString



SYNOPSIS

Converts a secure string into a plain text string.





SYNTAX

Convert-CSecureStringToString [-SecureString] <SecureString> [<CommonParameters>]





DESCRIPTION

Sometimes you just need to convert a secure string into a plain text string. This function does it for you. Yay!

Once you do, however, the cat is out of the bag and your password will be *all over memory* and, perhaps, the

file system.





PARAMETERS

-SecureString <SecureString>

The secure string to convert.



Required? true

Position? 1

Default value

Accept pipeline input? false

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS



OUTPUTS

System.String.





-------------------------- EXAMPLE 1 --------------------------



PS C:\\>Convert-CSecureStringToString -SecureString $mySuperSecretPasswordIAmAboutToExposeToEveryone



Returns the plain text/decrypted value of the secure string.











RELATED LINKS