Secure encryption of credentials as SecureString.
Secure encryption of credentials as SecureString, which can be saved as an xml-file or variable.
If user "A" encrypt the credentials on computer "A", user "B" cannot decrypt the credentials on computer "A" and also user "A" cannot decrypt the credentials on Computer "B".
To enter the credentials, the following window appears:
New-ManagedCredential [[-OutFile] <String>] [[-Credentials] <PSCredential>] [<CommonParameters>]
.\New-ManagedCredential.ps1 [[-OutFile] <String>] [[-Credentials] <PSCredential>] [<CommonParameters>]
PS> $EncryptedCredential = New-ManagedCredential
PS> $EncryptedCredential
UsernameAsSecureString : c04fc297eb01000000edade3a984d5ca...
PasswordAsSecureString : 984d5ca4aa6c39de63b9627730000c22...
PS> .\New-ManagedCredential.ps1 -OutFile E:\Temp\EncryptedCredentials.xml